By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,028 Members | 1,733 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,028 IT Pros & Developers. It's quick & easy.

Does window.open use GET or POST?

P: n/a
Hi all,

I am new in javascript. And I would like to find out whether
window.open use GET or POST.

I have tried to find the FAQ but no finding.

Please enlighten me or direct me to any FAQ.

Thanks in advance for any inputs or ideas,

Earth
Jul 23 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
On 26 May 2004 03:37:43 -0700, Earth wrote:
I am new in javascript. And I would like to find out whether
window.open use GET or POST.


Try opening it with address bar..

If the bit after '?' is there,
GET, else POST..

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 23 '05 #2

P: n/a
Andrew Thompson wrote:
On 26 May 2004 03:37:43 -0700, Earth wrote:
I am new in javascript. And I would like to find out whether
window.open use GET or POST.


Try opening it with address bar..

If the bit after '?' is there,
GET, else POST..


Not necessarily:

<form name="myForm" method="POST"
action="mypage.cgi?something=somethingelse">

However, I'm unsure why it matters if window.open() performs a GET
or POST (for the record, it does a GET). You can put stuff on the
URL which would be accessible to client-side Javascript even with
a POST. So to move information from one window to another, it's:

window.open('thenewpage.html?theKey=' + theValue, 'window_name',
'<attributes>');

regardless of whether window.open() performed a GET or POST.

--
| Grant Wagner <gw*****@agricoreunited.com>

* Client-side Javascript and Netscape 4 DOM Reference available
at:
*
http://devedge.netscape.com/library/...ce/frames.html

* Internet Explorer DOM Reference available at:
*
http://msdn.microsoft.com/workshop/a...ence_entry.asp

* Netscape 6/7 DOM Reference available at:
* http://www.mozilla.org/docs/dom/domref/
* Tips for upgrading JavaScript for Netscape 7 / Mozilla
* http://www.mozilla.org/docs/web-deve...upgrade_2.html
Jul 23 '05 #3

P: n/a
On Wed, 26 May 2004 14:18:29 GMT, Grant Wagner wrote:
If the bit after '?' is there,
GET, else POST..


Not necessarily:

<form name="myForm" method="POST"
action="mypage.cgi?something=somethingelse">


...took me a few moments to get what
you meant there.

The arguments are being 'post'ed
on from the mypage.cgi?

--
Andrew Thompson
http://www.PhySci.org/ Open-source software suite
http://www.PhySci.org/codes/ Web & IT Help
http://www.1point1C.org/ Science & Technology
Jul 23 '05 #4

P: n/a
Lee
Andrew Thompson said:

On Wed, 26 May 2004 14:18:29 GMT, Grant Wagner wrote:
If the bit after '?' is there,
GET, else POST..


Not necessarily:

<form name="myForm" method="POST"
action="mypage.cgi?something=somethingelse">


..took me a few moments to get what
you meant there.

The arguments are being 'post'ed
on from the mypage.cgi?


There is no GET request in that case.
Values of form elements are posted to mypage.cgi.
The script can *also* see the value of QUERY_STRING.

Jul 23 '05 #5

P: n/a
JRS: In article <69*************************@posting.google.com> , seen
in news:comp.lang.javascript, Earth <ec******@yahoo.com> posted at Wed,
26 May 2004 03:37:43 :

I have tried to find the FAQ but no finding.

Please enlighten me or direct me to any FAQ.

Since the newsgroup FAQ is posted here three times a week, frequently
cited in the group in signatures and otherwise, and IIRC well-known to
search engines, ISTM that you should, as a matter of urgent expediency,
endeavour to improve your search techniques.

--
John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4
<URL:http://jibbering.com/faq/> Jim Ley's FAQ for news:comp.lang.javascript
<URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
<URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
Jul 23 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.