View Full Version : User Imput to Variable

12-07-2008, 11:35 AM
I am trying to set a users imput to a variable that can be used to add to the link to another page. I know about Post and Get but these do not fit my problem. I am trying to get a form response to show up in this lightbox http://particletree.com/features/lightbox-gone-wild/

Can anyone help me set user imput to a variable?


12-07-2008, 12:13 PM
You can do 1 of two things:
1. Go tho AJAX route
2. try this:

document.getElementById('lightboxdiv').innerHTML = '<a href="' + document.yourform.inputname.value + '">Click here</a>';

Replace lightboxdiv with your div id which holds the lightbox element.
replace yourform with your form name
replace inputname with the name for the input field

Also... it's input not imput.