Stephen Forlance
asked on
Simple jquery passing a parameter via a link
Hi all,
im new to jquery.
I have this window that opens a modal:
http://bit.ly/1nwlkVW
How can I I pass a variable to the page that is opened from the link, so for example it opens ajax.html?id=[variable]
in normal js I would have just included it in the function call, like openmodal(12), but not sure how to do it in jquery
Thanks,
im new to jquery.
I have this window that opens a modal:
http://bit.ly/1nwlkVW
How can I I pass a variable to the page that is opened from the link, so for example it opens ajax.html?id=[variable]
in normal js I would have just included it in the function call, like openmodal(12), but not sure how to do it in jquery
Thanks,
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Just change somevar to whatever it should be.
ASKER
I think I need to explain what Im trying to do.
On the HTML there would be multiple links, each with a different variable.
Normally in JS I would do something like
<a href=#" onclick="somefunction(12)" >a</a>
So the function somefunction would receive the variable 12, which I could then use to call the correct page.
How can I do this with jquery?
On the HTML there would be multiple links, each with a different variable.
Normally in JS I would do something like
<a href=#" onclick="somefunction(12)"
So the function somefunction would receive the variable 12, which I could then use to call the correct page.
How can I do this with jquery?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER