Also another thing i saw in your fiddle.
You have data from each li <li
data-target="section01"
> and you are fetching it like
$(this).attr('data-target');
To get data use
data() | jQuery API Documentation
, data is a HTML 5 feature where we stores some data required by the
page and protect our page from memory leaking.
Here data is the attribute the 2nd part is the name/key and 3rs part is
the value.
You can get data like
$(this).data('target');
I updated your fiddle and its working as before but with data() not attr()
http://jsfiddle.net/g5f1fr82/2/