How to check id name if contains some pattern?
<p>I am using jquery and I am looping like:</p>

<pre><code>$("span").each(function (index) {
    var idname = $(this).attr('id');
    $("#" + idname).click(function () {
        window.location.href = "http://" + $(this).attr('id') + "lin.gw";
    });

}); //end for click attachment to button
</code></pre>

<p>I would like to loop over the elements where <code>id</code> contains <code>*raid*</code>.  What is the syntax for it?</p>
