Hello,
I have a textarea box that passes information to another form when a submit button is clicked. However when the new form opens all the information appears on 1 line.
How can i make the information appear as the user has entered it including returns (new lines). Also how can i separate the retrieved information into separate text fields postioned on different parts of the form?
header:-
function getParams() {
var idx = document.URL.indexOf(‘?’);
var params = new Array();
if (idx != -1) {
var pairs = document.URL.substring(idx+1, document.URL.length).split(‘&’);
for (var i=0; i<pairs.length; i++) {
nameVal = pairs[i].split(‘=’);
params[nameVal[0]] = nameVal[1];
}
}
return params;
}
params = getParams();
Body:-
kids = unescape(params[“kids”]);
document.write(“” + kids +”<br>”);
email = unescape(params[“email”]);
document.write(“” + email + “<br>”);