• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Tim Cooke
  • Campbell Ritchie
  • Ron McLeod
  • Junilu Lacar
  • Liutauras Vilda
Sheriffs:
  • Paul Clapham
  • Jeanne Boyarsky
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Tim Holloway
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
Bartenders:
  • Jesse Duncan
  • Frits Walraven
  • Mikalai Zaikin

More Reverse2Servlet

 
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have come up with another problem. If there are quotes in my input text, the text will not appear in the new page. I have written a seperate method that creates the HTML page. The quotes are still there before the text is submitted to that method. I have tried "replacing" the quotes but that did not seem to help. Thanks in advance for any suggestions.
Matthew Phillips
 
Chicken Farmer ()
Posts: 1932
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Are the quotes at the beginning of the string, or is this happening if they are just anywhere? What I kept getting was if there was a quote say in the middle of the string, everything up to the quote would show. Again, I had to use a replace method that inserted HTML's quote tag (don't think tag is the right word here, don't know what else to call it) (character-entity sequence) where the "'s were.

[This message has been edited by Marilyn deQueiroz (edited September 16, 2001).]
 
Ranch Hand
Posts: 424
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I use \" in place of ", which was suggested
 
whippersnapper
Posts: 1843
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

HTML's quote tag (don't think tag is the right word here, don't know what else to call it)


It's an entity.
 
Matthew Phillips
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If I do nothing, then all of my text disappears. If I replace '"' with """, "\"", "\\\"", or '\"' then only the text inside the quotes disappears.
 
jason adam
Chicken Farmer ()
Posts: 1932
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks guys and dolls for the entity jargon, I haven't done any studying on HTML or XML, been focusing purely on OO engineering and AD.
As far as the problem at hand, that's pretty odd. Haven't ever ran across that before, so I think I'm all out of suggestions. I assume you are testing for quotes in the string and replacing them with the entity, and as far as the value goes, in the combination of \'s and "'s that you provided, I didn't see the ones I used. I would print them here, but I don't want to overstep the bounds. Your string segments always end in a double-quote, so values would need to have double-quotes placed before that, and strings always begin with a double-quote, so you would need to insert a double-quote character afterwards. Vague enough?
Jason
[This message has been edited by jason adam (edited September 18, 2001).]
 
pie. tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
https://coderanch.com/wiki/718759/books/Building-World-Backyard-Paul-Wheaton
reply
    Bookmark Topic Watch Topic
  • New Topic