Page 111 - DCAP512_WAP_AND_WML
P. 111

Unit 8: Using Images




                                                                                                Notes
             Did u know?  How to create an image link?
             Creating an image link is simple. You just need to place an <img/> tag within an <anchor></
             anchor> tag pair or an <a></a> tag pair.
          Now here is the code of the program.
          <?xml version=”1.0"?>

          <!DOCTYPE wml PUBLIC “-//WAPFORUM//DTD WML 1.1//EN”
          “http://www.wapforum.org/DTD/wml_1.1.xml”>
          <wml>

          <card id=”C1" title=”Learning WML!”>
            <p mode=”nowrap”>
             Select:<br/>
             <a href=”#jokes”>Jokes</a><br/>
             <a href=”#star”>Star</a><br/>

             <a href=”#target”>Target</a><br/>
            </p>
          </card>

          <card id=”jokes” title=”Learning WML”>
          <do type=”accept”>
          <prev/>
          </do>
          <p>Jokes:

          <img localsrc=”hound” alt=”prev” src=”joke.gif”/>
          </p>
          </card>

          <card id=”star” title=”Learning WML”>
          <do type=”accept”>
          <prev/>
          </do>
          <p>Star:

          <img localsrc=”star2" alt=”prev” src=”star.gif”/>
          </p>
          </card>

          <card id=”target” title=”Learning WML”>
          <do type=”accept”>




                                           LOVELY PROFESSIONAL UNIVERSITY                                   105
   106   107   108   109   110   111   112   113   114   115   116