• 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:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Display problem

 
Greenhorn
Posts: 23
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Hi folks,
I am doing a project in servlets where in i am coming across some problems.
I am trying to read the text from a database which has to be displayed on the screen using servlet. I don't know how to store all the details of paragraph, tabs, carriage feeds what the user types in a input form which will be stored in the d/b and from the d/b it is read and displayed.
This is exactly same as how i am typing here ( ie., posting question in javaranch). All the paragraphs and line breaks what i am typing here is reflected correctly on the final display of my question. But in my case it is just appending
For instance,
This is vinay
-Bye
This should be reflected as it is in the final display. The
tags should be included for every new line.
But in my case it is displayed as
This is vinay -Bye

could anyone help me
Bye
Vinay
 
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
put your paragraph in < pre > data from database < /pre > tags.
This will prevent browser from formatting data and showit as it is.
But this will not apply PAGE fonts to this data.
To use your fonts use style sheet classes.

[This message has been edited by rajesh dalvi (edited October 24, 2000).]
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic