<!DOCTYPE HTML><HTML><Head> <MetaCharSet= "Utf-8"> <Metaname= "Viewport"content= "Width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" /> <title></title> <Scriptsrc= "Js/mui.min.js"></Script> <Linkhref= "Css/mui.min.css"rel= "stylesheet"/> <Scripttype= "Text/javascript"CharSet= "Utf-8"> /*Pre-load other pages in advance so that the loaded pages are ready for good results.*/Mui.init (); </Script></Head><Body><Headerclass= "Mui-bar Mui-bar-nav"> <aclass= "Mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a> <H1class= "Mui-title">Hello</H1></Header><Divclass= "Mui-content"> <Buttontype= "button"ID= "BTN1">Get server-side data</Button></Div> </Body><Scripttype= "Text/javascript">mui.init (); Mui.plusready (function() {document.getElementById ('BTN1'). AddEventListener ('Tap',function() {mui.ajax ({URL:'http://demo.hcoder.net/index.php', type:'GET', Success:function(data) {mui.toast (data); }, Error:function(Xhr,type,errorthrown) {mui.toast (type); } }); });}); Mui.post ('http://server-name/login.php', {username:'username', Password:'Password' },function(data) {//the server returns the response and, based on the response results, analyzes whether the login was successful; ... },'JSON' ); Mui.get ('http://server-name/list.php', {category:'News'},function(data) {//Get Server Response ... },'JSON' ); Mui.getjson ('http://server-name/list.php', {category:'News'},function(data) {//Get Server Response ... } );</Script></HTML>
How the MUI app interacts with the server