jQuery: how to pick unique IDs ?

Posted by Seerumi on Stack Overflow See other posts from Stack Overflow or by Seerumi
Published on 2010-06-07T08:37:34Z Indexed on 2010/06/07 8:42 UTC
Read the original article Hit count: 216

Filed under:
|
|
|

Hello. New to whole this jQuery (and javascript altogether, heh) and so far it's been excellent, but now I'm in a small pickle. Let's say I have list of forms generated from SQL database and every single one of them has to have unique id, so how I can select the specific item that is to be manipulated (changing values via php).

the $("#submit").click(function()) will trigger every submit buttons on the page, so how I can the #submit to be some random id that I clicked. There might be a smarter way, but I'm new to this so try to bear with me.

thought of passing the unique value with onClick="myfunction(unique_id)", but don't know how it goes with jQuery.

hope this made any sense

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about jQuery