Hi,
I want to pass a string with a special character (ê).
The problem is that the starting string "enquête" arrives as "enqu".
Why is this and how to solve that?
Thanks
Bob
Dim enqna As String
enqna = "enquête"
Response.Redirect(String.Format("next.aspx?Item0={0}", enqna))
next.aspx:
---------
enqna = Request.QueryString("Item0")
=> this gives: enqu
Cowboy (Gregory A. Beamer) - 19 Mar 2008 21:00 GMT
You need to URL encode the string before adding to Response.Redirect.
HttpUtility.UrlEncode(enqna)
You will see ê as a UNIX char. Not sure what, but it will be in the format
&###; so the url will be:
http://mysite.com/next.aspx?Item0=enqu&###;te
with the ### being some number

Signature
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA
Subscribe to my blog
http://gregorybeamer.spaces.live.com/lists/feed.rss
*************************************************
| Think outside the box!
*************************************************
> Hi,
>
[quoted text clipped - 14 lines]
>
> => this gives: enqu
bruce barker - 19 Mar 2008 21:11 GMT
uri's (url) only support a subset of ascii, no international characters. you
will to urlencode the characters, and be sure to use the correct encoding on
the decode side. see HttpUtility.UrlEncode
also see:
ftp://ftp.isi.edu/in-notes/rfc2396.txt
-- bruce (sqlwork.com)
> Hi,
>
[quoted text clipped - 14 lines]
>
> => this gives: enqu
Bob - 19 Mar 2008 23:18 GMT
Thanks
> uri's (url) only support a subset of ascii, no international characters.
> you
[quoted text clipped - 26 lines]
>>
>> => this gives: enqu