Skip to Content
Real World XML
book

Real World XML

by Steven Holzner
January 2003
Beginner to intermediate content levelBeginner to intermediate
1200 pages
23h 42m
English
Peachpit Press
Content preview from Real World XML

The <prev> Element

To add a <do> element that lets you move backward to card 2, I use the WML <prev> element like this:

Listing . ch20_12.wml
 
<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 2.0//EN"
    "http://www.wapforum.org/dtd/wml20.dtd" >
 <wml>
    <card id="Card1" title="Multiple Cards">
        <p align="center"><b>Multiple Cards</b></p>
        <do type="accept" label="Go to Card 2">
            <go href="#Card2"/>
        </do>
    </card>
    <card id="Card2" title="Card 2">
        <p>
            This is card 2.
        </p>
        <do type="prev" label="Back">
					<prev/>
					</do>
    </card>
</wml>

That's all it takes. Now a <do> element appears in card 2 that lets you move backward, as you can see in Figure 20-11. When the user clicks this <do> element, the browser navigates back to the previous card. It's ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Inside XML

Inside XML

Steven Holzner
XML Hacks

XML Hacks

Michael Fitzgerald

Publisher Resources

ISBN: 0735712867Purchase book