• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Need a Text Editor

 
Rudolf Castelino
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
I need to create a JSP based text editor. The Text editor is used to insert text, with Formatting into a database.
I cannot use an applet.
Please help
Thanks
 
Jon Dornback
Ranch Hand
Posts: 137
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what exactly do you need help with? if you are just trying to insert text in to a database, then you will need an html text area on the web page, and have that page submit to a jsp. the jsp will transform any text formatting characters in to something that won't corrupt the database, and then use jdbc to connect to the database and insert the information. that's the overview of the process, if that's what you were looking for.
if you need help specifically with how to create a fully-featured text editor on the web page, that is a different story - please post with what you need to do.
 
Tim Holloway
Saloon Keeper
Pie
Posts: 17989
47
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
At the moment, you're out of luck. The only way to enter multiple lines of text in pure HTML is via the textarea input control and it doesn't support formatting, just raw characters.
We format our text on the JavaRanch using UBB, like so:
This is quoted text

but that requires manual markup - not friendly for casual users. If you want something more like Windows WordPad, you're limited to an ActiveX/.Net-style plugin (I don't recommend this, Unix/Linux and Macintosh users will get a display that's unusable), an Java applet with one of the Swing text editing controls, or a specialized plugin (once again, not all users may be able to work with this).
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64618
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Actually if you can deal with something that only works in IE, it has a little-known feature where you can put an iframe element into a special "design mode" where it acts like a small wysiwig editor.
Many web-based email sites use this mode when displayed in IE.
The details are gory so if an IE-only solution is acceptable please post such and I'll look up the details (which are fuzzy in my mind since it's been a while since I used it).
hth,
bear
 
dave nelson
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just to throw in another $.02, you could create a word pad out of javascript and then insert in db as text via hidden field. Heavy DHTML though.
[ December 03, 2002: Message edited by: dave nelson ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic