Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > Web Programming > JavaScript > BOOK: Professional JavaScript for Web Developers ISBN: 978-0-7645-7908-0
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
BOOK: Professional JavaScript for Web Developers ISBN: 978-0-7645-7908-0
This is the forum to discuss the Wrox book Professional JavaScript for Web Developers by Nicholas C. Zakas; ISBN: 9780764579080
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Professional JavaScript for Web Developers ISBN: 978-0-7645-7908-0 section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old November 23rd, 2005, 06:21 PM
Registered User
 
Join Date: Nov 2005
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default Adding onclick stuff to an INPUT via javascript

I have an INPUT box, for the sake of brevity it shall hitherto be known as turkey, that I want to edit. Unfortuinately for me, there html page that it is located in is read only. Luckly, in the HEAD of the page, it loads a javascript file that is not read only.

Now, is there a way through javascript that I can edit turkey to add something like "onclick="javascript:dofunction()""?

Reply With Quote
  #2 (permalink)  
Old November 29th, 2005, 01:08 PM
Registered User
 
Join Date: Oct 2005
Location: , , .
Posts: 7
Thanks: 0
Thanked 0 Times in 0 Posts
Default

yeah, so long as u can get a hold of it. Does turkey have an id? that way u can do a getElementById and once u have a referance to it you can use the addEventListener function to the dom, check out page 269 in the book.

-Paul Maneesilasan
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
onclick="javascript: return false" on vista gabrieldcr2 Javascript 2 June 4th, 2008 09:40 AM
Adding Input Boxes ann86 Beginning PHP 1 April 7th, 2008 04:06 AM
input form ( onclick) bubblegirl Javascript How-To 1 March 6th, 2006 01:48 AM
Adding an OnClick procedure to repeater johno Classic ASP Databases 1 September 15th, 2005 03:36 AM
javascript onclick question robs Javascript 1 January 19th, 2005 05:20 AM



All times are GMT -4. The time now is 01:49 AM.


Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.