cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

Quick-add: + add another resource

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

Quick-add: + add another resource

Code Indentation


Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

              <div class="container">
        <div class="container" id="searchContainer">
            <h1><a target='_blank' href="https://en.wikipedia.org/wiki/Special:Random"><img id="wikiIcon" alt="search random article" src="https://res.cloudinary.com/serggcloud/image/upload/v1488079952/Icon-Wikipedia_tn6zt8.png" width="65" height="60"></a>iki Viewer</h1>  
<!--            <form>-->
            <div class="row"> 
              <div class="col-md-12 col-lg-12">
                <div class="input-group text-center">
                    <input class="form-control" id="input" type="text" name="search" placeholder="Search a wiki article...">
                    <span class="input-group-btn">
                        <button id="searchBtn" class="btn btn-success" type="button">
                            <span class="glyphicon glyphicon-search"></span>
            </div><!--end of form-->
        </div><!--end of searchContainer-->
        <div class="container">
            <div class = "row">
                <div class ="col-lg-12 col-md-12">
                    <ul id="output">    
        <div class="container" id="footer">
            <a target='_blank' href="https://codepen.io/serg_92">Made by: Sergio</a>
    background-color: #008B95; 
    color: white;
    text-align: center; 

    padding: 20px;
    font-size: 40px;

    margin-bottom: 12px;
    margin-top: 25%;  
    padding: 20px;  
    cursor: pointer;
input[type=text] {
    color: white; 
    box-sizing: border-box;
    border: 0 solid #F3953E;
    border-radius: 5px;
    font-size: 16px;
    background-color: #F3953E;
    background-image: url('');
    background-position: 10px 10px; 
    background-repeat: no-repeat;
    -webkit-transition: width 0.4s ease-in-out;
    transition: width 0.4s ease-in-out;
    color: #5d5d5d; 
/*Style output*/
ul li{
    padding-left: 15px;
    padding-right: 10px;
    padding-top: 1px;
    padding-bottom: 2px;
    background: #F3953E; 
    margin-left: -34px;
    margin-bottom: 15px;
    text-align: left; 

ul h3{
    font-size: 22px;

ul p{
    font-style: italic;

#output a{
    color: white;
    text-decoration: none;

#output a:hover{

    padding-top: 10px;
    padding-bottom: 30px;
#footer a{
    text-decoration: none;
#footer a:hover{
               function myAjaxCall(){
        var searchInput = $("#input").val();
        var url = "https://en.wikipedia.org/w/api.php?action=opensearch&search=" + searchInput + "&format=json&callback=?";
           type: "GET",
            url: url, 
            async: false,
            dataType: "json",
            success: function(data){
                // console.log(data[1][0]); 
                // console.log(data[2][0]); 
                // console.log(data[3][0]);

                //Clear search results
                for (var i=0; i<data[1].length; i++){
                $("#output").prepend("<li><h3><a target='_blank' href = "+ data[3][i] +">"+ data[1][i] + "</a></h3><p>"+ data[2][i] +"</p></li>");
            error: function(errorMessage){


        if(event.keyCode == 13){
Loading ..................