Accented charcters in Asp.net

Joined
Jul 2, 2007
Messages
2
Reaction score
0
Please consider the following code...

<script language="javascript" type="text/javascript">

function QuickSearchBegin(){
window.location.href = 'default.aspx?SEARCH_KEY='+ escape('Some accented characters') + '&SELECTED_INDEX=' + 12;
return false;
}
</script></head>
<body><form id="form1" runat="server">
<div>
<asp:Button ID="Button1" runat="server" Text="Button" onclientclick="return QuickSearchBegin()" />
</div>


In Page Load I have this code...

Response.Write("The value is " + Request.QueryString["SEARCH_KEY"].ToString()) ... all accented characters are converted into some garbage value...

I used both server.urldecode , as well as HttpUtility.Urldecode in the above code...

HttpUtility.Urldecode (Request.QueryString["SEARCH_KEY"].ToString())

What is the correct way of getting the accented values.

Thanks,
Arvind
 
Last edited:

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,756
Messages
2,569,540
Members
45,024
Latest member
ARDU_PROgrammER

Latest Threads

Top