How can I get the unique value of a dynamic variable using a function?
I have two boxes that when clicked each displays their own amount clicked. I'd like to be able to get what the count is for each using a function call like:
- $('#example_one').getCount();
So click the gray boxes a number of different times and I've setup links below each box that will call the function for each and display the count in an alert, but currently it'll only return the count for the second box for both links.
How can I return the count for each with this $.fn.getCount kind of function call?
Thanks for your time,
Nathan