• Post Reply Bookmark Topic Watch Topic
  • New Topic

What does the http://java.sun.com/JSP/Page namespace refer to?

 
J Elfering
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I thought xmlns values just had to be unique. However, if I change a page that starts <html xmlns:jsp="http://java.sun.com/JSP/Page" > that contain <jsp:directive...> <jsp:useBean...> and <jsp:getProperty> etc., it works. However, if I change the xmlns to something else, such as:
<html xmlns:jsp="http://java.sun.com/JSP/PageXYZ" >
it does not work.

What is special about the http://java.sun.com/JSP/Page namespace? Is there something actually being used from that location? If it just needs to be unique, why doesn't a different URI work?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're dealing with a very special uri, which is defined in the JSP specification. This one is already defined, to be able to use JSP tags.
You could change the prefix "jsp" to something else, like "bob" :

xmlns:bob="http://java.sun.com/JSP/Page"
and then :
bob:useBean, bob:directive...

But you must not change this uri. This is THE uri to use all JSP stuff.
 
J Elfering
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Satou kurinosuke:
You're dealing with a very special uri, which is defined in the JSP specification. This one is already defined, to be able to use JSP tags.
You could change the prefix "jsp" to something else, like "bob" :

xmlns:bob="http://java.sun.com/JSP/Page"
and then :
bob:useBean, bob:directive...

But you must not change this uri. This is THE uri to use all JSP stuff.



Thank you.
So it is a reserved namespace of some sort then? App server JSP translators must recognize this namespace and then use some sort of internal mechanism to ensure tags conform to a certain schema?

Are there other common reserved namespaces? If so, how do I find out what schema is implied?
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So it is a reserved namespace of some sort then?

Yes. But I don't know if there's a public list of reserved namespaces.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65519
105
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A link to the JSP Specification is available in the JSP FAQ.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!