简体   繁体   中英

Need alternative POST method for window.open, showmodeldialog and startDownload

In Javascript currently these functions are sending GET request window.open, showmodeldialog and startDownload.

What is the alternative method to send these request as POST.

You can try something like this

<form id="myForm" method="POST" action="..." target="myWindow">
   <!-- Whatever you need -->
</form>

And in your javascript:

<script>
  window.open("about:blank", "myWindow", /*additional params...*/);
  document.getElementById('myForm').submit();
</script>

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM