how to submit value to another page without using form tag [JAVASCRIPT] -


hii can me ? how submit value page without using form tag (method=post), using javascript.

function runscript(e) {    if(e.keycode==13){       var text=document.getelementbyid('edtsearch').value       // bla bla must filled function submit value    }    return false } 

with jquery library:

you can use jquery post request.

$.ajax({   type: "post",   url: url,   data: data,   success: success,   datatype: datatype }); 

without library, plain javascript.

window.location = "http://www.page.com"; //this page  form=document.getelementbyid('formname'); //this fills form         form.target='_blank';         form.action='whatever.html';         form.submit();         form.action='whatever.html';         form.target=''; 

Comments

Popular posts from this blog

c# - Unity IoC Lifetime per HttpRequest for UserStore -

Change the color of an oval at click in Java AWT -

I am trying to solve the error message 'incompatible ranks 0 and 1 in assignment' in a fortran 95 program. -