Results 1 to 4 of 4
  1. #1
    nanimtech is offline Member
    Join Date
    Apr 2008
    Posts
    5
    Rep Power
    0

    Default encoding special characers in jsp

    Hi folks
    In my jsp iam going to populate special characters ((*&), it is
    working fine, but if i substring that one to certain limit(for ex:10)
    for example if i give like --> & to populate in jsp it is
    taking as --> & and it is going to substring and it is
    taking upto--> &<&
    but the xml parser not able to parse and thrown NotWellFormed exception
    how can i overcome this one.
    Advance appreciation for any ideas..

    -Naresh

  2. #2
    rjuyal's Avatar
    rjuyal is offline Senior Member
    Join Date
    Mar 2008
    Location
    Delhi, India
    Posts
    194
    Rep Power
    7

    Default escape

    may be you want to use escapeHTML , escapeXML


    i am the future

  3. #3
    nanimtech is offline Member
    Join Date
    Apr 2008
    Posts
    5
    Rep Power
    0

    Default

    I have tried like that .. but it is showing same thing..
    can you please let me know what are all possibilities..

  4. #4
    rjuyal's Avatar
    rjuyal is offline Senior Member
    Join Date
    Mar 2008
    Location
    Delhi, India
    Posts
    194
    Rep Power
    7

    Default escapeXml

    if you are using JSTL

    <core:out value="${variableNameHodlingValue}" escapeXml="true"/>
    i am the future

Similar Threads

  1. Some help with encoding...
    By nm123 in forum Networking
    Replies: 0
    Last Post: 04-15-2008, 01:22 AM
  2. special characters
    By ravian in forum New To Java
    Replies: 2
    Last Post: 11-16-2007, 02:28 PM
  3. Replies: 1
    Last Post: 08-07-2007, 06:32 AM
  4. show special symbol using its Unicode character
    By christina in forum AWT / Swing
    Replies: 1
    Last Post: 07-25-2007, 10:21 AM
  5. Special characters in text fields
    By Felissa in forum Web Frameworks
    Replies: 0
    Last Post: 06-27-2007, 05:47 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •