Trouble with character translation

Posted on 2004-11-08
Last Modified: 2013-12-03
I have a form  in a jsp with these two fields

<input type="hidden" name="i_unitcurrency" value='&pound;'>&pound;
<input type="hidden" name="i_unitcurrency" value='&euro;'>&euro;

When I use        String unitCurrencyArray[] = request.getParameterValues("i_unitcurrency");  

to retrieve the values I get  UTF-8 character codes in  unitCurrencyArray[] as opposed to the &pound; &euro; that I want.

How do I prevent the character translation ?
Question by:mikehalfsheen
    LVL 35

    Accepted Solution

    <input type="hidden" name="i_unitcurrency" value='&amp;pound;'>&pound;
    <input type="hidden" name="i_unitcurrency" value='&amp;euro;'>&euro;

    Might do it...

    The browser should convert these to the correct values for you :-)

    Author Comment

    Obviously really I suppose :) Thanks, I don't know what I'd do without you ;)
    LVL 35

    Expert Comment

    It's only obvious when you know ;-)

    Glad I could help!

    Good luck with it!


    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    When we have a dead host and we lose all connections to the ESXi, and we need to find a way to move all VMs from that dead ESXi host.
    Read about the 3 stages of the buyer's journey: awareness, consideration, and decision.
    how to add IIS SMTP to handle application/Scanner relays into office 365.
    Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

    755 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now