473,804 Members | 2,280 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Querystring with accented characters

I have encountered a problem when certain European characters are included in
the Querystring of an URL.

If I have a URL like: ?param=AAÃ*

On the receiving page a simple Request() call returns "AA" and not "AAÃ*".

It drops all accented characters!

If I change to use a Form instead, it works OK.

If I copy the Request.QuerySt ring to a String variable and split it I manage
to get the proper value.

I have tried this on Windows 2000 and Windows 2003 with the same result.

Is this a known bug with Request.QuerySt ring? And if so is there a
fix/workaround??

Thanks

John Byrne
Australia
Jul 22 '05 #1
10 4536
No issues on my end. Have you tried a different browser? Does it appear
right in a view-source? Have you tried URLEncoding it?

Ray at home
"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:1F******** *************** ***********@mic rosoft.com...
I have encountered a problem when certain European characters are included
in
the Querystring of an URL.

If I have a URL like: ?param=AAÃ

On the receiving page a simple Request() call returns "AA" and not "AAÃ ".

It drops all accented characters!

If I change to use a Form instead, it works OK.

If I copy the Request.QuerySt ring to a String variable and split it I
manage
to get the proper value.

I have tried this on Windows 2000 and Windows 2003 with the same result.

Is this a known bug with Request.QuerySt ring? And if so is there a
fix/workaround??

Thanks

John Byrne
Australia

Jul 22 '05 #2
This is an ASP Request object problem. Different browser makes no difference.

Getting parameters on the server side behaves differently depending on how
the ASP page was requested.

It works as expected when a form is submitted, but if the page is requested
via URL then Request("<parm> ") doesn't return accented characters.

Thanks

"Ray Costanzo [MVP]" wrote:
No issues on my end. Have you tried a different browser? Does it appear
right in a view-source? Have you tried URLEncoding it?

Ray at home
"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:1F******** *************** ***********@mic rosoft.com...
I have encountered a problem when certain European characters are included
in
the Querystring of an URL.

If I have a URL like: ?param=AAÃ

On the receiving page a simple Request() call returns "AA" and not "AAÃ ".

It drops all accented characters!

If I change to use a Form instead, it works OK.

If I copy the Request.QuerySt ring to a String variable and split it I
manage
to get the proper value.

I have tried this on Windows 2000 and Windows 2003 with the same result.

Is this a known bug with Request.QuerySt ring? And if so is there a
fix/workaround??

Thanks

John Byrne
Australia


Jul 22 '05 #3


"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:D2******** *************** ***********@mic rosoft.com...
This is an ASP Request object problem. Different browser makes no

difference.

Not necessarily.

Did you miss the part where I asked if the à appears in a view-source? If
so, it's a browser problem. I'm not saying that this is the problem, but
it'd help to rule it out...

Ray at work
Jul 22 '05 #4
This is certainly a server-side issue. If the URL for a page is ?parm=AAÃ*

and the ASP page did:

Response.Write( Request.QuerySt ring);

you get:

parm=AAÃ*

but if you did:

Response.Write( Request("parm") );

you get:

AA

but works fine if page invoke via a form (either post or get)

JB

"Ray Costanzo [MVP]" wrote:


"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:D2******** *************** ***********@mic rosoft.com...
This is an ASP Request object problem. Different browser makes no

difference.

Not necessarily.

Did you miss the part where I asked if the à appears in a view-source? If
so, it's a browser problem. I'm not saying that this is the problem, but
it'd help to rule it out...

Ray at work

Jul 22 '05 #5
If you don't want answers, don't ask questions.

Ray at home

"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:14******** *************** ***********@mic rosoft.com...
This is certainly a server-side issue. If the URL for a page is ?parm=AAÃ

and the ASP page did:

Response.Write( Request.QuerySt ring);

you get:

parm=AAÃ

but if you did:

Response.Write( Request("parm") );

you get:

AA

but works fine if page invoke via a form (either post or get)

JB

"Ray Costanzo [MVP]" wrote:


"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:D2******** *************** ***********@mic rosoft.com...
> This is an ASP Request object problem. Different browser makes no

difference.

Not necessarily.

Did you miss the part where I asked if the à appears in a view-source?
If
so, it's a browser problem. I'm not saying that this is the problem, but
it'd help to rule it out...

Ray at work

Jul 22 '05 #6
Ray Costanzo [MVP] wrote on 20 dec 2004 in
microsoft.publi c.inetserver.as p.general:
If you don't want answers, don't ask questions.


I didn't ask, I still like to read the answers.

That is the joy of usenet.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 22 '05 #7
No, it's the people that are the joy of usenet. Also top-posting. ;]

Ray at home

"Evertjan." <ex************ **@interxnl.net > wrote in message
news:Xn******** ************@19 4.109.133.29...
Ray Costanzo [MVP] wrote on 20 dec 2004 in
microsoft.publi c.inetserver.as p.general:
If you don't want answers, don't ask questions.


I didn't ask, I still like to read the answers.

That is the joy of usenet.

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)

Jul 22 '05 #8
"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:14******** *************** ***********@mic rosoft.com...
"Ray Costanzo [MVP]" wrote:
"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:D2******** *************** ***********@mic rosoft.com...
This is an ASP Request object problem. Different browser makes no

difference.

Not necessarily.

Did you miss the part where I asked if the à appears in a view-source? If so, it's a browser problem. I'm not saying that this is the problem, but it'd help to rule it out...

Ray at work

This is certainly a server-side issue. If the URL for a page is ?parm=AAà

and the ASP page did:

Response.Write( Request.QuerySt ring);

you get:

parm=AAà

but if you did:

Response.Write( Request("parm") );

you get:

AA

but works fine if page invoke via a form (either post or get)

JB


Actually, it's probablly a combination of both client and server issues. I
believe the problem is associated with the character encoding. Here are some
things to check:

1. In your browser, what character encoding are you using?
2. On the server, what codepage/character encoding are being used. There are
quite a few places where codepage can be set. Here's an excerpt from the
Response.CodePa ge documentation that describes how the codepage setting
cascades:

If Response.CodePa ge is not explicitly set in a page, it is implicitly set
by Session.CodePag e, if sessions are enabled. If sessions are not enabled,
Response.CodePa ge is set by @CodePage, if @CodePage is present in the page.
If there is no @CodePage in the page, Response.CodePa ge is set by the
AspCodePage metabase property. If the AspCodePage metabase property is not
set, or set to 0, Response.CodePa ge is set by the system ANSI codepage.

Here's a link to the documentation:
http://www.msdn.microsoft.com/librar...om_resopcp.asp

Jul 22 '05 #9
Thanks for your informative reply.

Initially the ASP pages had a charset of windows-1252 and the
Session.CodePag e was 65001. I then went and changed all pages to use charset
UTF-8, but the problem still persisted.

I have also tried saving the ASP pages in UTF-8 format instead of the normal
ANSI encoding, but this also had no affect.

The work-around I had to come up with was create a function that would parse
the QueryString and return the requested parameter.

Thanks

"Chris Hohmann" wrote:
"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:14******** *************** ***********@mic rosoft.com...
"Ray Costanzo [MVP]" wrote:
"John Byrne" <Jo*******@disc ussions.microso ft.com> wrote in message
news:D2******** *************** ***********@mic rosoft.com...

> This is an ASP Request object problem. Different browser makes no
difference.

Not necessarily.

Did you miss the part where I asked if the à appears in a view-source? If so, it's a browser problem. I'm not saying that this is the problem, but it'd help to rule it out...

Ray at work

This is certainly a server-side issue. If the URL for a page is ?parm=AAÃ*

and the ASP page did:

Response.Write( Request.QuerySt ring);

you get:

parm=AAÃ*

but if you did:

Response.Write( Request("parm") );

you get:

AA

but works fine if page invoke via a form (either post or get)

JB


Actually, it's probablly a combination of both client and server issues. I
believe the problem is associated with the character encoding. Here are some
things to check:

1. In your browser, what character encoding are you using?
2. On the server, what codepage/character encoding are being used. There are
quite a few places where codepage can be set. Here's an excerpt from the
Response.CodePa ge documentation that describes how the codepage setting
cascades:

If Response.CodePa ge is not explicitly set in a page, it is implicitly set
by Session.CodePag e, if sessions are enabled. If sessions are not enabled,
Response.CodePa ge is set by @CodePage, if @CodePage is present in the page.
If there is no @CodePage in the page, Response.CodePa ge is set by the
AspCodePage metabase property. If the AspCodePage metabase property is not
set, or set to 0, Response.CodePa ge is set by the system ANSI codepage.

Here's a link to the documentation:
http://www.msdn.microsoft.com/librar...om_resopcp.asp

Jul 22 '05 #10

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

Similar topics

1
2454
by: Fuzzyman | last post by:
I've written an anagram finder that produces anagrams from a dictionary of words. The user can load their own dictionary. ( http://www.voidspace.org.uk/atlantibots/nanagram.html ) In order to ensure it is able to find anagrams properly I wanted to strip characters like punctuation etc from words in the dictionary and words the user entered. I test(ed) against the 26 English letters ( string.ascii_lowercase ).
2
2662
by: Remco van den Berg | last post by:
I'm running a MySQL database with one of tables holding the members of a volleybal club in the Netherlands. One the the fields in that table is holding the name of the players. How do I search for all people with the name "Andre", with the important remark, that it should also match "André"!! So with the letter "e" with an accent "'" on it. In the Netherlands those names can be spelled with and without the accent and I do not always...
2
1707
by: nicolas_riesch | last post by:
I try to use python as the language in an asp page with Microsoft IIS 5.0. I have these two files, req_bad.asp and req_ok.asp ---------- req_bad.asp --------- <%@LANGUAGE=Python%> <%
4
2032
by: Satish | last post by:
Hi Gurus, Please help me in this, I have tried all options available to me. (Option 1) I am making a simple request from VB.NET client to WBI generated WSDL and passing request parameters. The response I am expecting should have some accented characters (Customer Name: Lokalcenter Åbygård), but this gets truncated and response is as follows (Customer Name: Lokalcenter bygrd). The WSDL has utf-8 character set defined.
0
2307
by: shintu | last post by:
Hallo, I am trying to write french accented characters é è ê in Excel worksheet using my perl script , But I am stuck here as I couldnt find a way of writing it !: My code: use strict; use warnings;
2
6433
by: gsuns82 | last post by:
Hi all, I have to replace accented characters from a input string with normal plain text.I have coded as follows. String input = "ÄÀÁÂÃ"; input= input.replaceAll("", "A"); like wise v can do for all. output was: ************ AAAAA
4
2899
by: gsuns82 | last post by:
Hi all, I am facing a strange issue. i.e: I have a jsp page with an input text field where the user can enter searching value even along with Accented Characters.After that i am getting the input value at the controller inorder to compose a query,before that i am replacing Accented Characters with plain text values so that i can append the proper input value in the DBquery. I tried to replace the input string for ...
1
1989
by: gsauns | last post by:
I have an ASP.NET app in which I import from a comma-delimited text file, put all that data in a GridView, and then insert the records into multiple related tables in my SQL Server database. I got one text file which contains accented characters. When I bring them into the GridView, the accented characters show up as boxes, the universal unrecognized character. And since I am inserting into the DB by iterating thru the rows of the...
3
7493
by: Jake | last post by:
I am writing a script that allows people to upload a CSV file for processing and I am having trouble with accented characters. If a UTF-8 encoded file is uploaded, everything works fine. The problem happens when someone uploads a non UTF8 file that happens to have an accented character inside, like é. In this case, the character is converted to a funky symbol, like �. I noticed this explanation in the PHP documentation for the...
0
9714
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10599
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
10346
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
10347
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
10090
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
5531
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
5673
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4308
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3832
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.