jquery - Exclude a link from nivo lightbox -
i using nivo lightbox plugin. working good. when have added youtube channel link social icons, opening channel link in lightbox. how can rid of it?
here nivo lightbox code using
$(document).ready(function(){ $('a').nivolightbox(); });
based on comment there may alternative accepted answer:
there lot of links in site. hard add class in every link
it may easier exclude youtube link if there specific class associated socialclass in example below:
<a href="http://youtube.com/yourchannel" class="socialclass">my youtube channel link</a> you can use jquery .not() function exclude .socialclass links specifically:
$(document).ready(function(){ $('a').not('.socialclass').nivolightbox(); }); i still recommend go other answer continue decorate lightbox links appropriate class=nivolightbox should aware of .not() function , when/where use it.
Comments
Post a Comment