• Post Reply Bookmark Topic Watch Topic
  • New Topic

JSP 2.0 document  RSS feed

 
Ryan Tyer
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can anyone post an example jsp document using jsp 2.0 or correct my problem? I can't seem to get everything working quite right.

I've tried the following chunk, and it works but with a real annoyance. In Tomcat 5, as well as in Jetty 4, this puppy outputs with no newlines (/n variety in the view source, not <br /> ) . A view source will show all the code after the doctype on a single line. Call me silly, but I want source to be more neatly formatted (Read: keep its newlines).


I've attempted to convert this to the following style in the hopes that it would improve the situation, but I'm getting /index.jspx(7,29) Attribute "xmlns:jsp" must be declared for element type "html".




Anyways, any help would be greatly appreciated.

R

[ October 25, 2004: Message edited by: Ryan Tyer ]

[ October 25, 2004: Message edited by: Ryan Tyer ]
[ October 25, 2004: Message edited by: Ryan Tyer ]
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65833
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is there a reason you are using the 'JSP document' syntax? That's rare unless the page is machine-generated (or is that the case here?). That syntax isn't really well suited for hand-coded JSP pages.

Just curious.
 
Ryan Tyer
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Because some pages will output something other than html (svg, xml) and I'd like to keep the format for them the same.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!