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.

            
              <link rel="stylesheet" href="https://code.ionicframework.com/ionicons/2.0.1/css/ionicons.min.css">
        <link rel="stylesheet" href="css/styles.css">
        <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.2/jquery.min.js"></script>
        <script src="js/scripts.js"></script>
    </head>
    <body>
        <div id="container">
            <h1>Knife Knowledge FAQ</h1>
            <div class="title"><h3>These are the questions our customers ask most frequently</h3></div>
            
            <ul class="faq">
                <li class="q"><i class="ion-chevron-right"></i>What does the term "Full-Tang" mean?</li>
                <li class="a">"Full-Tang" refers to knives where the blade goes all the way down through the handle to the end of the grip.</li>
                
                <li class="q"><i class="ion-chevron-right"></i>What is a bolster, and what benefits does it provide?</li>
                <li class="a">A knife bolster is the thick section between the handle and the blade, and it strengthens the knife, and gives better balance and control. However, there is much disagreement on whether or not it is necessary.</li>
                
                <li class="q"><i class="ion-chevron-right"></i>What are the differences between forged and laser-cut stamped knives?</li>
                <li class="a">Forged knives are stronger and retain their edge longer than stamped knives, which have more flexible blades. In the case of Wusthof, their forged knives go through 40 different steps in their factory, where the laser-cut knives go through 14 steps. Also, their forged knives include a bolster, which balances the knife and protects fingers, although bolsters can also be added to laser-cut knives. Laser-cut stamped knives can be of excellent quality too, however, and they are more economically priced.</li>
                
              <li class="q"><i class="ion-chevron-right"></i>How should I wash my knives?</li>
                <li class="a">Always wash them by hand with hot, soapy water. Never drop them in with a sinkful of dirty dishes, or run them through a dishwasher, which will not only bang them together, but damage the blade through excessive heating.</li>
                
                <li class="q"><i class="ion-chevron-right"></i>Do I need to spend a lot of money for knives?</li>
                <li class="a">The more you can spend, the better, but there are some less expensive options, such as Victorinox, which also make Swiss Army Knives. The blades are very sharp, and well-made for the price.</li>
                
            </ul>
        </div>
        
        <footer>
            <h3>Have a question? Ask us <a href="#">here</a>, and we will get back to you shortly.</h3>
        </footer>
    </body>
            
          
!
            
              /***** RESETS *****/

* {
    margin: 0;
    padding: 0;
}

/***** FONTS *****/

@font-face { font-family: "Ionicons"; src: url("https://code.ionicframework.com/ionicons/2.0.1/fonts/ionicons.eot?v=2.0.1"); src: url("https://code.ionicframework.com/ionicons/2.0.1/fonts/ionicons.eot?v=2.0.1#iefix") format("embedded-opentype"), url("https://code.ionicframework.com/ionicons/2.0.1/fonts/ionicons.ttf?v=2.0.1") format("truetype"), url("https://code.ionicframework.com/ionicons/2.0.1/fonts/ionicons.woff?v=2.0.1") format("woff"), url("https://code.ionicframework.com/ionicons/2.0.1/fonts/ionicons.svg?v=2.0.1#Ionicons") format("svg"); font-weight: normal; font-style: normal; }

body {
    font-family: 'Arial', sans-serif;
    color: #666;
    font-size: 1em;
    background: #f9f9f9;
    line-height: 1.6em;
}

ul, li {
    list-style: none;
}

#container {
    width: 60%;
    margin: 0 20%;
    overflow: auto;
}

h1 {
    text-align: center;
    margin: 1em 0;
}

.title {
    height: 2.5em;
    width: 75%;
    margin-left: 12.5%;
    background: #6bba70;
    color: #fff;
    text-align: center;
    padding-top: .5em;
    transform: rotate(-1deg);
    box-shadow: 3px 5px 2px #999;
}

i {
    margin-right: 1em;
}

.faq li {
    padding: 1.25em;
}

.faq li.q {
    font-weight: bold;
    font-size: 120%;
    border-bottom: 1px #ccc solid;
    cursor: pointer;
}

.faq li.q:nth-child(1),
.faq li.q:nth-child(5),
.faq li.q:nth-child(9) {
    background: #eee;
}

.faq li.a {
    font-weight: bold;
    color: #6bba70;
    background: #fff;
    display: none;
}

img {
    margin-right: .5em;
}

footer {
    height: 6em;
    padding: 2em;
    margin-top: 2em;
}

footer h3 {
    width: 50%;
    margin: 0 25%;
}

footer a {
    color: #6bba30;
    text-decoration: none;
}

/********* MEDIA QUERIES ************/
@media (max-width: 800px) {
    #container {
        width: 90%;
        margin: 0 5%;
    }
    
    .title {
        width: 90%;
        margin: 0 5%;
        height: 3.5em;
    }
    
    .faq li {
        text-align: center;
    }
    
    .faq li.a {
        width: 85%;
        margin-left: 5%;
    }
    
    footer h3 {
        width: 90%;
        margin: 0 5%;
        text-align: center;
    }
}
            
          
!
            
              // Accordian
var action="click";
var speed="500";

$(document).ready(function() {
    // Question handler
    $('li.q').on(action, function() {
        // Get next element
        $(this).next()
            .slideToggle(speed)
        // Select all other answers
                .siblings('li.a')
                    .slideUp();
    });
});
            
          
!
999px
Loading ..................

Console