How to share a jquery function
<p>I have the following code that edits text. Normally there is an id used instead of a class. I've changed it to a class because I'd like to share a single instance. Now that it's a class, I can't tell which element the user clicked on.</p>

<p>I want to use one instance of the following code and send in an additional argument that can be passed to my PHP that distinguishes the element and pass that to my PHP code.</p>

<pre><code>$(".edit").edit({
  url:'server.php'
});
</code></pre>

<p>So, maybe something like:</p>

<pre><code>function myFunc(arg){
  $(".edit").edit({
    url:'server.php?arg='+arg
  });
}
</code></pre>

<p>Of course, this doesn't work because I need the click function and I'm not sure how to do that. Can someone help?</p>
