By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,473 Members | 3,504 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,473 IT Pros & Developers. It's quick & easy.

Calling a .js function from a menu

P: 2
Hello all,



Working with Hypercosm, which is a series of applets. following is the button that executes the orbit mode

[HTML]<img src="images/toolbars/getting_started/orbit_button.png" title="Orbit" name="orbitButton" width="24" height="24" id="orbitButton">[/HTML]
Rather than using the image i want to make the function work from a menu system. Basically a word as opposed to an image. Seems simple, but i have no hair left trying to figure it out.

Anybody got any suggestions. I am thinking the onclick function, but not sure of the syntax.

thank you.

mike
Jan 10 '08 #1
Share this Question
Share on Google+
1 Reply


gits
Expert Mod 5K+
P: 5,333
hi ...

you answered your question already ... :) use the onclick-handler:

[HTML]<img src="images/toolbars/getting_started/orbit_button.png" title="Orbit" name="orbitButton" width="24" height="24" id="orbitButton" onclick="function_name();">[/HTML]
that calls the function with name 'function_name' :)

kind regards
Jan 10 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.