El código es muy simple, solo para darle una idea. No hablaré muchas tonterías aquí, solo presente el código fuente:
La copia del código es la siguiente:
<! Doctype html>
<html>
<Evista>
<title> WeChat JS API Demo </title>
<meta http-equiv = "content-type" content = "text/html; charset = utf-8">
<link rel = "dns-prefetch" href = "http://mmbiz.qpic.cn">
<link rel = "dns-prefetch" href = "http://res.wx.qq.com">
<Meta name = "Viewport" Content = "Width = Device-width, Height = Device-HEight, Inital-Scale = 1.0;">
<meta name = "Apple-Mobile-Web-App-Capable" Content = "Yes">
<meta name = "Apple-Mobile-Web-app-status-bar-style" content = "Black">
<meta name = "format-detection" content = "phone = no">
<style type = "text/css">
pag {
relleno: 5px 10px;
}
</style>
<script type = "text/javaScript" src = "weixinapi.js? V = 1"> </script>
</ablo>
<Body>
<script language = "javaScript">
<!-
función class1 () {
this.name = "class1";
this.aaa = "aaa";
this.shownam = function () {
alerta (this.name);
}
}
función class2 () {
this.name = "class2";
}
var c1 = new class1 ();
var c2 = new Class2 ();
//c1.shownam ();
c1.shownam.call (c2); // permutación del objeto, para el método
C1.AAA.call (C2); // Error, solo para la herencia del método, los atributos no son compatibles
->
</script>
</body>
</html>
Aquí solo estoy presentando las ideas para todos, para que puedas jugar con tus ideas específicas libremente.