I have the following HTML code:
<div id="filter-bar">
<ul>
<li><a href="#image" class="current"><?php _e('Image','sofa'); ?></a></li>
<li><a href="#text"><?php _e('Text','sofa'); ?></a></li>
<li><a href="#video"><?php _e('Video','sofa'); ?></a></li>
</ul>
</div>
How can I get the href value of list which has class current? e.g. How can I make it return image ?
Thanks
You can use
attrorpropmethods:or
You can get “pure”
hrefwithout hash#sign with this:DEMO: http://jsfiddle.net/BJd7p/