<!DOCTYPE html><html><head><meta charset="utf-8"><title>Title</title><script type="text/javascript">// <script src="外部js文件路径" type="text/javascript">function change_button_text(){// document.getElementById("button2").value = "Success";// document.getElementById("button_2").innerHTML = "Success";document.getElementById("button_2").innerText = "Success";document.getElementById("button_1").innerText = document.getElementsByTagName("a")[0].getAttribute("href");}</script><style type="text/css">button{border-radius: 6px;border:1px solid green;height: 40px;width:200px;background-color: lime;}button:hover{background-color: cyan;}</style></head><body><!-- <button> <a href="">点击我跳转到百度</a></button> --><a href="/" target="_blank"><button id="button_1">快点击我~</button></a><div><button onclick="change_button_text()" id="button_2">在点击我~</button></div></body></html>
300字范文,内容丰富有趣,生活中的好帮手!