• Post Reply Bookmark Topic Watch Topic
  • New Topic

Text field with #  RSS feed

 
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have a jsp form with a textarea field that the user can enter comments and notes into and save to a database, this all works fine. Except when a user, somewhere in their text uses a #. The form does what it is supposed to until the user clicks on the edit or delete button the text field then displays only what is to the left of the # and everything else is blank. The URL displays the text exactly as is in the database and includes the pound sign. Am I missing something here? Is there something going on with # that I am not aware of?
Thanks!
 
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The pound sign in a url normally means to goto a link on the page.

You most likely need to encode the information.

Eric
 
m brymer
Ranch Hand
Posts: 64
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
so, even though the text field appears in its entirety in the url, I still need to encode it to read it into the text field on the edit form?
 
Ranch Hand
Posts: 256
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
# needs to be replaced by its ascii equivalent %23 while sending it over the url.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!