I was wondering if anyone knows if it is possible to place a randomly generated number inside of a hidden form field. I need to generate a unique “Order Number” on pageload and have the number written to a hidden field in the order form.
Thank you for your fast reply but I cant get it to work. it says it is undefined. Maybe if i post the code you could be more help. I should have done that in the first place.
<html>
<head>
<title>XYZ Host - checkout page</title>
<script>
function doform()
{
var info;
info = "Domain: " + document.forms[0].domain.value + "
";
info += "Username: " + document.forms[0].username.value + "
";
info += "Password: " + document.forms[0].pwd.value;
document.forms[0].info.value = info;
You are buying our yearly hosting plan.
<input type=“hidden” name=“product” value=“Yearly hosting plan, 200MB disk space, 25GB bandwidth per month and unlimited email accounts.”><br>