This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes HTML, CSS and JavaScript and the fly likes Execute the Code Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Execute the Code" Watch "Execute the Code" New topic

Execute the Code

Arun C. Giridharan
Ranch Hand

Joined: Jul 11, 2010
Posts: 96

document.write(product(4,3)) i'm not able to execute the code...i don't know what is the problem???
Gregg Bolinger
GenRocket Founder
Ranch Hand

Joined: Jul 11, 2001
Posts: 15299

Did you leave the quotes off your on click handler on purpose?

GenRocket - Experts at Building Test Data
David Newton

Joined: Sep 29, 2008
Posts: 12617

And what would a document.write mean after the document has been rendered?
Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 60774

Arun Giridharan wrote:i'm not able to execute the code

Please read TellTheDetails and ItDoesntWorkIsUseless.

And David is correct, document.write() is most certainly not what you want to be doing.

[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Consider Paul's rocket mass heater.
subject: Execute the Code
Similar Threads
Javascript function isn't returning a value
executing a javascript function from a servlet
Just trying using Object Oriented technique in Javascript but the output not displyed in brwser
Not able to hide a sentence using jquery
Why to use eval function inside Javascript