Create Conditional Content - BEA WebLogic User Manual

Mobility server
Hide thumbs Also See for WebLogic:
Table of Contents

Advertisement

Create Conditional Content

This section describes the creation of conditional content through the use of the following syntax:
The
<mm-include>
The
<mm-exclude>
The "
" attribute
where
Create Conditional Content
By default, everything defined within the body of a group is displayed when you reference the
group, but occasionally you will want finer control when specific devices are being targeted.
For example, you might want line breaks (
on a mobile phone, so that the address wraps neatly. Alternatively, you might decide to exclude
the address altogether and just provide the phone number.
Another example might be changing the amount of introductory text you provide on a page. You
could display ten paragraphs of text on a desktop browser but exclude the last five paragraphs
when it is displayed on a PDA.
Include or Exclude Content
WebLogic Mobility Server provides two tags to include or exclude content:
.
<mm-exclude>
Wrap the content you want included or excluded in these tags. Both tags require the
attribute. The
attribute allows conditional expressions to be built up to match specified
where
Device Repository attributes.
The following examples demonstrate the usage of these tags. The example Including Line Breaks
shows how to include line breaks within an address group when a specific device is targeted. The
example "Excluding an Address for a Class of Device" demonstrates excluding text.
Example: Including Line Breaks
<mm-group id="company_details">
<mm-head id="hd_company_details" useradded="no">Company Details</mm-head>
<mm-body id="bd_company_details" idref="hd_company_details">
<p>ABC Company Ltd.</p>
<p>North Business Park
<mm-include where="IsMenuDriven"><br /></mm-include>
Circular Road
Dublin
Ireland
</p>
<p>Phone: 888-000-111</p>
<p>Fax: 000-888-111</p>
</mm-body>
</mm-group>
element
element
<br/>
Part III Fundamentals of Mobile Content
) inserted into an address group when it displays
BEA WebLogic Mobility Server User Guide - 43
and
<mm-include>
where

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the WebLogic and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Weblogic mobility server

Table of Contents