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

onclick text call for javascript

P: 2
I have this line
<input type="image" src="linktoimage.gif" border="0" onClick="javascript:return EJEJC_frm(this.parentNode);">

I want to simply replace image with a line of text so that when the user clicks the text phrase such as Click Me To Add and it calls for the javascript above.

Any ideas?
Jan 24 '08 #1
Share this Question
Share on Google+
3 Replies

P: 130
u want a link ?
Expand|Select|Wrap|Line Numbers
  1. <a href="#" onclick="javascript:bla()">click here!</a>
Jan 25 '08 #2

P: 2
PERFECT! It work perfectly. Thank you so much.
Jan 25 '08 #3

Expert Mod 15k+
P: 16,027
u want a link ?
Expand|Select|Wrap|Line Numbers
  1. <a href="#" onclick="javascript:bla()">click here!</a>
There's no need for "javascript:" in an onclick. You may also want to put a return false to prevent the link being followed.
Jan 25 '08 #4

Post your reply

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