How to hide 1st five <li> tag

How to hide 1st five <li> tag and display next 5 <li> tag using css or JQuery

Comments (3)

Marcelo Arias's photo

Well, using CSS

li:nth-child(1) {
    list-style: none;

With nth-child you access to the first li element, then you hide with list-style. This is what you were looking for? ^^

Bhupendra Choudhary's photo

Business Head of FieldCircle

Using J query you can do this by implementing this code:

$('ul li:gt(1)').hide(); $('.show_button').click(function() { $('ul li:gt(3)').show(); });

patel shraddha's photo

li:nth-of-type(-n+5) {display: none;}