Contents | Prev | Next


<jsp:root>

Defines standard JSP elements and namespace attributes of tag libraries.

JSP Syntax

None. However, see Taglib Directive.

XML Syntax

<jsp:root	
   xmlns:jsp="http://java.sun.com/JSP/Page"	
   [ xmlns:taglibPrefix="URI" ]+ ...	
   version="1.2 | 2.0">	
      JSP Page	
</jsp:root>

Example

<jsp:root 	
   xmlns:jsp="http://java.sun.com/JSP/Page"	
   xmlns:public="http://www.jspcentral.com/tags" 	
   version="2.0">	
   <public:loop>	
      ...	
   </public:loop>	
</jsp:root>

Description

A JSP page in XML syntax can have jsp:root as its root element, but it is not required. You can instead specify your own tag as a root element. Tag libraries used within the JSP page can be represented in the root element through xmlns attributes. (Again, you can use the xmlns attributes in other tags besides the jsp:root element. The xmlns:jsp and version attributes are mandatory.

Attributes

See Also



Contents | Prev | Next

Copyright © 2004, Sun Microsystems, Inc. All rights reserved.