473,698 Members | 2,153 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

What is the difference between REQUEST and REQUEST.QUERYST RING?

What is the difference between these two statements? They seem to do the
same thing...

response.write( request("variab le"))

response.write( request.queryst ring("variable" ))


Jul 19 '05 #1
6 11817
Try this:

<form method="post" action="somepag e.asp?x=6">
<input name="x" type="text" value="0">
<input type="submit">
</form>

On somepage.asp put:

response.write request("x")

What do you get? 6 or 9?
The request collection contains the querystring and form collections.
Always specify what you mean, either request.form or request.queryst ring.
Don't use just request by itself. It'll come back to bite you - especially
when you go to .net. :] Always qualify everything.

Ray at home
"michaaal" <re******@veriz on.net> wrote in message
news:OQ******** ******@TK2MSFTN GP10.phx.gbl...
What is the difference between these two statements? They seem to do the
same thing...

response.write( request("variab le"))

response.write( request.queryst ring("variable" ))

Jul 19 '05 #2
Perfect answer, Ray. Extremely informative and also very practical. Thank
you!

"Ray at <%=sLocation% >" <ra*@ajf8jalskd fna.sefrhja7yas df.com> wrote in
message news:OV******** ******@TK2MSFTN GP12.phx.gbl...
Try this:

<form method="post" action="somepag e.asp?x=6">
<input name="x" type="text" value="0">
<input type="submit">
</form>

On somepage.asp put:

response.write request("x")

What do you get? 6 or 9?
The request collection contains the querystring and form collections.
Always specify what you mean, either request.form or request.queryst ring.
Don't use just request by itself. It'll come back to bite you - especially when you go to .net. :] Always qualify everything.

Ray at home
"michaaal" <re******@veriz on.net> wrote in message
news:OQ******** ******@TK2MSFTN GP10.phx.gbl...
What is the difference between these two statements? They seem to do the same thing...

response.write( request("variab le"))

response.write( request.queryst ring("variable" ))


Jul 19 '05 #3
In addition to Ray's explanation: http://www.aspfaq.com/2111


"michaaal" <re******@veriz on.net> wrote in message
news:OQ******** ******@TK2MSFTN GP10.phx.gbl...
What is the difference between these two statements? They seem to do the
same thing...

response.write( request("variab le"))

response.write( request.queryst ring("variable" ))

Jul 19 '05 #4
Ray at <%=sLocation% > wrote on 15 jul 2003 in
microsoft.publi c.inetserver.as p.general:
<form method="post" action="somepag e.asp?x=6">
<input name="x" type="text" value="0">
<input type="submit">
</form>

On somepage.asp put:

response.write request("x")

What do you get? 6 or 9?


Real magic, I always seem to get 9 !

Where does this 9 come from? is it 6*1.5 ?

;--}

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 19 '05 #5
Ray at <%=sLocation% > wrote on 15 jul 2003 in
microsoft.publi c.inetserver.as p.general:
No, you see, if you don't specify, it takes the querystring value and
returns it inverted. So, if you had a querystring of L, you'd get 7 as a
result, and if your querystring is a W, you'd get an M, and so on.


That is why my regionalisation to Hieroglyphic LCID=96669 did invert
Horeb's eye "H" in the query stylus, while displaying the pictogram "N" for
water correctly.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 19 '05 #6
Aaron Bertrand - MVP wrote:
So be sure that names don't conflict.

Or, be sure to explicitly call the collection you are using. :-)


Yes, much better!8^)
Jul 19 '05 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
3664
by: diadia | last post by:
string s = "hello"; const char *p = s.begin(); cout << p << endl; // print hello s = ""; char *p2= s.begin(); cout << p2 << endl; // print hello why?????
11
3409
by: J Wang | last post by:
dear, I debug the program recently as follows. #include <sys/stat.h> int main(int argc, char *argv) { struct stat buf;
0
2114
by: programer | last post by:
Can I use Activex (as vb) to connect database when I use vc.net.
1
1875
by: FD | last post by:
For performance reason, the follwoing code (C#) to capture all the Request collection contexts is NOT recommended: string ID = Request.QueryString; But how to Capture the individual Request properties needed in the application? Thanks, FD
0
1122
by: Per Bolmstedt | last post by:
In my web.config, the default requestEncoding is set to X. However, I have a web form to which I know that Y encoded data will sometimes be POSTed. This data will be garbled when accessed through Request.Form because ASP.NET regards it as X encoded and not Y encoded. I thought manually setting Request.ContentEncoding to Y in, say, the Page_Load event would reinterpret the data as being Y encoded. Setting Request.ContentEncoding,...
1
9296
by: Raheemulla Khan | last post by:
can any body through a light on this question with an example
2
7248
by: rn5a | last post by:
Assume that an ASPX page is accessed using the following URL: http://myserver/Page1.aspx?fname=john The value of the querystring fname (which is john) can be retrieved using both Request.Params("fname") & Request.QueryString("fname"). So what's the difference between Request.Params("fname") & Request.QueryString("fname")?
0
2467
by: RupeshDeenadayalan | last post by:
Is there any difference between a boot loader and a boot strapper.It would be better if any one can tell what operations does a general bootloader,boot strapper,BSP,Driver does???
5
10431
by: bhushanbagul | last post by:
Hi All Please let me know exactly what difference i and g makes in oracle version i.e. when we say oracle 10g or oracle 11i Thanks Bhushan
0
8603
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9157
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9026
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8893
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8861
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7723
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4366
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4619
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2001
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.