Converting jquery lightbox to user tagged gallery additions
<p>I have a question about how to rewrite a lightbox script that uses jquery. </p>

<p>Its using div ids to differentiate galleries. I'd like to have it use the <code>rel=""</code> attribute, with perhaps a trailing number. Can this be written to check for something such as <code>rel="gallery1"</code> but within a loop that increments the number? I'm unfamiliar with the js syntax for such things. Or perhaps a loop with checks the dom for objects with that rel. Thx.</p>

<p><strong>Javascript</strong></p>

<pre><code>$(function() {
    $('#gallery1 a').lightBox();
    $('#gallery2 a').lightBox();
});
</code></pre>
