<!DOCTYPE HTML><HTMLLang= "en"><Head> <MetaCharSet= "UTF-8"> <title>Two-dimensional code</title></Head><style>#qrcode{position:relative;width:400px;Height:400px;margin:0 Auto; }. Logo{position:Absolute;width:100px;margin:Auto; Left:0;Top:0; Right:0;Bottom:0;Height:37px;Z-index:222; }. Logo img{width:100px; }</style><Body> <DivID= "QRCode"> <Divclass= "logo"> <imgsrc= "1.jpg"alt=""> </Div></Div></Body><Scripttype= ' Text/javascript 'src= ' Http://cdn.staticfile.org/jquery/2.1.1/jquery.min.js '></Script><Scripttype= "Text/javascript"src= "Http://cdn.staticfile.org/jquery.qrcode/1.0/jquery.qrcode.min.js"></Script><Script>$(function(){ //$ (' #qrcode '). QRCode ("http://pmi.yoopay.cn/"); //more detailed configuration $('#qrcode'). QRCode ({text:"http://pmi.yoopay.cn/", //the string to encodeWidth: -, //Define widthHeight: -, //Define Heightbackground:"#fff", //Background ColorForeground:"Black" //Front View
Qrcode.clear (); Clear two-dimensional code
}); })</Script></HTML>
jquery generates two-dimensional code