Page is WAP page membership level purchase, tag toggle display. Mobile phone based on calling the corresponding level and price information
<div class= "menu" ><ul><li id= "one1" onclick= "tag (' One ', 1, ' A1 ', ' 188 ')" > Month card </li><li id= " One2 "onclick=" tag (' One ', 2, ' A2 ', ' 266 ') "> Seasonal </li><li id=" One3 "onclick=" tag (' One ', 3, ' A3 ', ' 388 ') "> Half year Card </li><li id= "one4" onclick= "tag (' One ', 4, ' A4 ', ' 520 ')" > Year card </li></ul></div>
var id=1,price=188,act=1;//Set global variable function tag (name, Cursel,aid,money) {for (Var i=1;i<5;i++) {if (i = = Cursel) {window.id=cursel;window.price=money;window.act=1;$ ("# One "+cursel"). AddClass ("Off"); $ ("#con_" +name+ ' _ ' +cursel). Show ();} else{$ ("#one" +i). Removeclass (' off '); $ ("#con_" +name+ ' _ ' +i). Hide ();}} Console.log (' {' id ': ' +aid+ ', ' price ': ' +money+ ', ' act ': ' 1 '} ')//sreturn ' {' id ': ' +aid+ ', ' price ': ' +money+ ', ' act ': ' 1 ‘}";} $ (function () {$ ("#one1"). AddClass ("Off"); $ ("#con_one_1"). Show ();//console.log ("{' id ': ' A1 ', ' Price ': ' 188 ', ' act ': ' 1 '} ");//return" {' id ': ' 1 ', ' price ': ' 188 ', ' act ': ' 1 '} ";}) function GetProductID ()//ios automatically calls {//console.log (' {' id ': ' +this.id+ ', ' price ': ' +this.price+ ', ' act ': 1} '); return ' {' id ": ' +window.id+ '," price ": ' +window.price+ '," act ": 1} '; }function Azgetproductid ()//Ann table automatic Call {var cs = ' {' id ': ' +window.id+ ', ' price ': ' +window.price+ ', ' act ': 1} '; Window.myObject.setProductId (CS);} </script>
iOS or Android calls Web page data