I am trying to populate a form in a new window using JQuery but I cant seem to get it to work, it currently opens the new window as desired. But any attempts to populate the form failts.
$( "body" ).delegate( ".propose", "click",function() {
var url = './prop_form.php';
var win = window.open(url, 'Marketing Docs', 'directories=no,menubar=no,scrollbars=yes,status=no,toolbar=no,location=no,resizable=yes,width=500,height=600');
$(win).find('input[name=vrm]').val('x');
if (win.focus) { win.focus(); }
});
The script should populate a text input called vrm.