• 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

JSP Specs, Chap 5, Qeustion?????

 
Ranch Hand
Posts: 776
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi - The 1st page of the chapter, the second paragraph after the bullets says:
" ...... but it is not valid to intermix 'standard
syntax' and XML syntax inside the same source
file."
But??? I do this all the time, for example:
<jsp:useBean id=....yada, yada ..../>
<!-- And later .... -->
<%= new java.util.Date() %>
The example is intermixed, isn't it??
What am I missing here??? I am thinking there is something simple I am failing to observe.
Regards, Guy
[ February 07, 2002: Message edited by: Guy Allard ]
 
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes, Guy, I think you are missing something here. The title of the article says it all:
"JSP.5.1 Uses for XML Syntax for JSP Pages"
...
"A JSP page in either syntax can include via a directive a JSP page in either syntax. It is not valid, however, to intermix standard JSP syntax and XML syntax inside the same source file."
It simply means that it is not valid to write both type of 'syntaxes' for a tag that has both the versions available, e.g.
<%= new java.util.Date()%> // std. JSP Syntax
<jsp:expression>new java.util.Date()</jsp:expression> // invalid if used with above.
This is in cases where standard JSP syntax and XML equivalent are both available and as such does not apply to your example where <jsp:useBean/> is the only available, or standard syntax!
Well this is what I gathered from the specs. I might be wrong though!
 
Guy Allard
Ranch Hand
Posts: 776
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Ah, for a given tag!!
I will experiment some with this ......
Thanks, Guy
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic