Convert a javascript value to HTML Input

S

Stewart

I'm trying to populate a HTML text or hidden input with a value from
javascript.

the Javascript values do display with this test:

<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
business = unescape(params["business"]);
amount = unescape(params["amount"]);
item_name = unescape(params["item_name"]);

document.write("business = " + business + "<br>");
document.write("amount = " + amount + "<br>");
document.write("item_name = " + item_name + "<br>");
// End -->
</script>

HTML input:

<input type="text" name="business" value=business />

I can't find any examples or direction for this.
Any suggestions?
 
N

Nonee

If I am understanding what you are looking for, you should be able to
access the form field, hidden or otherwise, directly aka:

document.whateveryourformiscalled.business.value = 10;
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,431
Messages
2,571,677
Members
48,796
Latest member
Greg L.

Latest Threads

Top