aspose file tools*
The moose likes Struts and the fly likes <> symbol in textbox it's been changed to & lt; and & gt Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "<> symbol in textbox it Watch "<> symbol in textbox it New topic
Author

<> symbol in textbox it's been changed to & lt; and & gt

josuva moorthy
Greenhorn

Joined: Apr 05, 2010
Posts: 11
This is the code

<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>

<html:text styleClass="text" name="CardForm"
property="lastName"
maxlength="20" styleId="lastName"/>

When I enter <> symbol in textbox it's been changed to & lt; and & gt
William P O'Sullivan
Ranch Hand

Joined: Mar 28, 2012
Posts: 860

It has been URL encoded during the POST process.

You may need to decode it if persisting to a database or something.

WP
josuva moorthy
Greenhorn

Joined: Apr 05, 2010
Posts: 11
William P O'Sullivan wrote:It has been URL encoded during the POST process.

You may need to decode it if persisting to a database or something.

WP



How to decode .It's only occurring for few symbols <>%()
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18113
    
    8

William P O'Sullivan wrote:It has been URL encoded during the POST process.


URL-encoding changes characters to something starting with a percent sign. For example a space character changes to "%20". So no, that's not URL-encoding.
William P O'Sullivan
Ranch Hand

Joined: Mar 28, 2012
Posts: 860

Sorry, HTML encoded.

WP
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: <> symbol in textbox it's been changed to & lt; and & gt
 
Similar Threads
XML Parsing help needed
Pre-processing DTD to remove ENTITY's
sax parser error
set focus using js file
Struts 1.2 - when I enter greater lesser symbol html:text texbox it's getting rendered as &lt;&gt;