Why can\'t I get this to work??
$(\"a\").each(function() { if ($(this[href$=\"?\"]).length()) { alert(\"Contains questionmark\"); } }); >
$(\"a\").each(function() { if ($(this[href$=\"?\"]).length()) { alert(\"Contains questionmark\"); } });
use this
$("a").each(function () { var href=$(this).prop('href'); if (href.indexOf('?') > -1) { alert("Contains questionmark"); } });