Searching...
Friday, 21 September 2012

RESTAURANT APP IN WML

make  file named restapp.wml and punjabi.wml 

function in bill.wmls

execute restapp.wml

ENJOY!!!!!


                            restapp.wml


<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.2//EN"
"http://www.wapforum.org/DTD/wml12.dtd">

<wml>
<card title="resturant app">
<p>AVAILABLE ITEMS<br/>
      <anchor >punjabi<go href = "punjabi.wml" /></anchor><br/>
      <anchor >gujarati<go href = "punjabi.wml#gujarati" /></anchor><br/>
      <anchor >south-indian<go href = "punjabi.wml#si" /></anchor>  <br/>
     <anchor >ORDER<go href = "punjabi.wml#order" /></anchor><br/>  
      

        
     
</p>
</card>

</wml>

punjabi.wml

<?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.2//EN"
"http://www.wapforum.org/DTD/wml12.dtd">

<wml>
<card  title="pun">
<p>punjabi items
      naan -                50  <br/>
      paneer bhurji -    150<br/>
      paneer masala - 130 <br/>
     
</p>
</card>

<card id="gujarati" title="gujarati">
<p>gujarati items
      roti        -  11<br/>
      mix veg - 100 <br/>
      dal        -  90<br/>
      rice       - 80<br/>
     
</p>
</card>

<card id="si" title="south indian">
<p>south- indian 
     idli      - 100<br/>
     dosa   - 150<br/>
     platter - 500<br/>
     
</p>
</card>

<card id ="order" title="order">
<p> ORDER<br/>
punjabi
       <select name="op1">
          <option value="50">naan</option>
          <option value="150">paneer bhurji</option>
          <option value="130">paneer masala</option> 
      </select><br/>
gujarati
<select name="op2">
          <option value="11">roti</option>
          <option value="100">mix vegatables</option>
          <option value="90">dal</option> 
         <option value="80">rice</option> 
      </select><br/>
south-indian
<select name="op3">
          <option value="100">idli</option>
          <option value="150">dosa</option>
          <option value="500">platter</option> 
      </select>



 <anchor >bill<go href = "bill.wmls#bill" /></anchor><br/>  

<p>TOTAL AMOUNT IS $e</p>
</p>
</card>

</wml>


bill.wmls


extern function bill()
{
 var a=Lang.parseFloat(WMLBrowser.getVar("op1"));
 var b=Lang.parseFloat(WMLBrowser.getVar("op2"));
 var c=Lang.parseFloat(WMLBrowser.getVar("op3"));
 var e;
WMLBrowser.setVar("e",a+b+c);
}


1 comments:

  1. Hi. I really enjoyed my brief visit on your site and I’ll be sure to be back for more.
    Can you please consider placing my website on your link list?

    Please email me back.

    Thanks!
    Kevin
    kevincollins1012 gmail.com

    ReplyDelete

 
Back to top!