Accented charcters in Asp.net

Discussion in '.NET' started by charvind, Aug 13, 2008.

  1. charvind

    charvind

    Joined:
    Jul 2, 2007
    Messages:
    2
    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: Aug 13, 2008
    charvind, Aug 13, 2008
    #1
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Chris Kettenbach

    Remove unwanted charcters from a string

    Chris Kettenbach, Jul 20, 2005, in forum: ASP .Net
    Replies:
    1
    Views:
    487
    Chris Kettenbach
    Jul 20, 2005
  2. peelman
    Replies:
    1
    Views:
    14,307
    Karl Seguin
    Oct 18, 2005
  3. brandons of mass destruction

    charcters styles via html

    brandons of mass destruction, Jul 26, 2003, in forum: XML
    Replies:
    1
    Views:
    451
    Steven Dilley
    Jul 30, 2003
  4. ABHIJIT B

    ASP.NET 2.0 TextBOx WildCard charcters

    ABHIJIT B, Feb 20, 2008, in forum: ASP .Net
    Replies:
    0
    Views:
    409
    ABHIJIT B
    Feb 20, 2008
  5. Paul Jørstad

    Control charcters in form input field

    Paul Jørstad, Sep 17, 2003, in forum: Javascript
    Replies:
    4
    Views:
    260
    asdf asdf
    Sep 19, 2003
Loading...

Share This Page