<html> <head> <title>An Example</title> </head> <body> <div id="word"></div> <button onClick="sayHello"></botton> <script> var sayHello = function() { document.findElementById('word').html('Hello world'); } </script> </body> </html>
缺点:
By zation