Okay I think this will work but I am stuck on one piece of the code.
function post_to_url(path, params, method) {
method = method || "post";
var form = document.createElement("form");
//move the submit function to another variable
//so that it doesn't get over written
form._submit_function_ = form.submit;
form.setAttribute("method", method);
form.setAttribute("action", path);
for(var key in params) {
var hiddenField = document.createElement("input");
hiddenField.setAttribute("type", "hidden");
hiddenField.setAttribute("name", ulogin);
hiddenField.setAttribute("value", params[key]);
form.appendChild(hiddenField);
}
document.body.appendChild(form);
form._submit_function_(); //call the renamed function
}
post_to_url("http://xxx./index.php?name=Your_Account/", { submit: "submit" } ); //works!
I am lost on what should replace parmams key. Should this be the dbEscapeString($_data['user_nickname']) or do I leave off the dbescape?
hiddenField.setAttribute("value", ($_data['user_nickname']));
Or
hiddenField.setAttribute("value", dbEscapeString($_data['user_nickname']));