Oracle Fusion Middleware JSP Tag Java API Reference for Oracle WebLogic Portal
10g Release 3 (10.3.2)
E14256-03

Portal Client-Specific Content


Standard Syntax:
     <%@ taglib prefix="cscm" uri="http://www.bea.com/servers/portal/tags/client/cscm" %>

XML Syntax:
     <anyxmlelement xmlns:cscm="http://www.bea.com/servers/portal/tags/client/cscm" />

This taglib provides tags to perform client-specific jsp content (inclusion or exclusion). In brief, the user agent of a request is mapped to a "classification" string via the file WEB-INF/client-classifications.xml. This classification string can then be used to render conditionally. See the section "Creating Portals for Multiple Device Types" in the Portal Development Guide, and the javadoc for com.bea.netuix.client.classifier.ClientClassifier for more information.

Tag Library Information
Display NamePortal Client-Specific Content
Version1.0
Short Namecscm
URIhttp://www.bea.com/servers/portal/tags/client/cscm
 

Tag Summary
default Includes the body content if the request client classification falls into the "default" category, i.e. the request user-agent is not matched by any items in WEB-INF/client-classifications.xml, or is matched by the classification named "default". <p/> For example, suppose your WEB-INF/client-classifications.xml file looks like <pre> &lt;classifications&gt; &lt;classification name="abc"&gt; &lt;useragent value="ua_abc" /&gt; &lt;/classification&gt; &lt;classification name="default"&gt; &lt;useragent value="ua_def" /&gt; &lt;/classification&gt; &lt;/classifications&gt; </pre> If your request has user-agent "ua_def" or anything other than "ua_abc", then this tag will render its body content. If not, this tag will not render anything.
not-default Includes the body content if the request client classification does not fall into the "default" category, i.e. the request user-agent is matched by some item in WEB-INF/client-classifications.xml and is not matched by the classification named "default". <p/> For example, suppose your WEB-INF/client-classifications.xml file looks like <pre> &lt;classifications&gt; &lt;classification name="abc"&gt; &lt;useragent value="ua_abc" /&gt; &lt;/classification&gt; &lt;classification name="default"&gt; &lt;useragent value="ua_def" /&gt; &lt;/classification&gt; &lt;/classifications&gt;. </pre> If your request user-agent is "ua_abc", then this tag will render its body content. If not, this tag will not render anything.
recognized Includes the body content if the request client has been explicitly mapped to a classification (albeit perhaps to the default). <p/> For example, suppose your WEB-INF/client-classifications.xml file looks like <pre> &lt;classifications&gt; &lt;classification name="abc"&gt; &lt;useragent value="ua_abc" /&gt; &lt;/classification&gt; &lt;classification name="default"&gt; &lt;useragent value="ua_def" /&gt; &lt;/classification&gt; &lt;/classifications&gt;. </pre> If your request has user-agent "ua_def" or "ua_abc", then this tag will render its body content. If not, this tag will not render anything.
not-recognized Includes the body content if the request client has not been explicitly mapped to a classification (to default or not). <p/> For example, suppose your WEB-INF/client-classifications.xml file looks like <pre> &lt;classifications&gt; &lt;classification name="abc"&gt; &lt;useragent value="ua_abc" /&gt; &lt;/classification&gt; &lt;classification name="default"&gt; &lt;useragent value="ua_def" /&gt; &lt;/classification&gt; &lt;/classifications&gt;. </pre> If your request has a user-agent other than "ua_def" or "ua_abc", then this tag will render its body content. If not, this tag will not render anything.
when Includes the body content if the request client classification matches the supplied client attribute. <p/> For example, <pre> &lt;when client=&quot;iphone&quot; &gt; hello, IPhone user &lt;/when&gt; </pre> renders the given content if the request user-agent has been mapped to &quot;iphone&quot; in WEB-INF/client-classifications.xml.
when-not Conditionally includes the body content if the request client classification does not match the supplied client attribute. <p/> For example, <pre> &lt;when-not client=&quot;iphone&quot; &gt; hello, non-IPhone user &lt;/when&gt; </pre> renders the given content if the request user-agent has not been mapped to &quot;iphone&quot; in WEB-INF/client-classifications.xml.
 


Oracle Fusion Middleware JSP Tag Java API Reference for Oracle WebLogic Portal
10g Release 3 (10.3.2)
E14256-03

Copyright © 2010, Oracle. All rights reserved.