Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to use javascript to hide content and show through link

$(document).ready(function() {
    $('li').click(function () {
        $('.content:visible').hide(); // hides the visible content before 
        $('.content').eq($(this).index()).show(); // shows the corresponding content
    });
    });
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #hide #content #show #link
ADD COMMENT
Topic
Name
6+3 =