i'm sorry, my mistake. i had an input with the name "action" and it was confusing the browser. if you ever run into a problem like this, check your s names ;)
Hya!
I'm working on a feature for my website that needs me to change a form action with javascript. It's actually pretty easy to achieve this with Firefox, but not in IE. Since i'm not turning my back on IE, eventhough i hate the browser, i really wanted to get this thing to work cross-browser.. for the user's sake. ;)
Is it possible?
an example, working on firefox
function preview( id ) {
// get form element
var frm_obj = window.document.getElementById( id );
// open window
var w = window.open( "loading.html", "preview", "width=500,height=350,scrollbars=yes" );
// change form attributes
frm_obj.target = "preview";
frm_obj.action = "preview.php";
// hey ho, let's go!
frm_obj.submit();
// bring window up (could be open already)
w.focus();
}
oh, and i've tried using setAttribute as well. no results.