Dynamic jQuery Based On HTML <li> Tags
<p>I have HTML code like this :</p>

<pre><code>&lt;li&gt;&lt;input type="hidden" value="001" class="block-hidden-input" /&gt;
    &lt;a href="#" id="manage-1" class="manage-content-link"&gt;
        &lt;img src="images/web-block/web-block1.jpg"/&gt;
        &lt;span class="orange-notice"&gt;Click to Edit Content&lt;/span&gt;    
    &lt;/a&gt;
&lt;/li&gt;

&lt;li&gt;&lt;input type="hidden" value="002" class="block-hidden-input" /&gt;
    &lt;a href="#" id="manage-2" class="manage-content-link"&gt;
        &lt;img src="images/web-block/web-block2.jpg"/&gt;
        &lt;span class="orange-notice"&gt;Click to Edit Content&lt;/span&gt; 
    &lt;/a&gt;
&lt;/li&gt;
</code></pre>

<p>each li tag has unique id and it has following format : id="manage-X". each user can have multiple li tag, so it's dynamic.</p>

<p>on the other hand, I need this jQuery to handle that li tags :</p>

<pre><code>$('#manage-1').click(function(e) { 
    $(this).next(".manage-content-wrap").find(".manage-content").load("file-001.php");
    e.preventDefault();
});
$('#manage-2').click(function(e) { 
    $(this).next(".manage-content-wrap").find(".manage-content").load("file-002.php");
    e.preventDefault();
});
</code></pre>

<p>this jQuery looks so awful. because it's static and if I have 5 li tags, means I have to copy-and-paste 5 times. I don't know how to make it dynamic on jQuery.</p>

<p>plus, "file-001.php" and "file-002.php" are based on li's value. so, it must be in this format file-XXX.php (replace XXX with li's value). I guess this must be related with RegEx. but I have no clue how to do it...</p>

<p>any idea how to make that jQuery dynamic based on li tags? thanks!</p>
