为什么这么写Javascript没效果
<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=utf-8">
<title>innerHTML</title>
<script type="text/javascript">
var mychar=document.getElementById("con");
document.write("原标题:"+mychar.innerHTML+"<br>");
mychar.innerHTML="Hello world";
document.write("修改后的标题:"+mychar.innerHTML);
</script>
</head>
<body>
<h2 id="con">javascript</h2>
<p>哈撒艰苦大会是单卡寄售点卡接撒活动会计师大会开始觉得很</p>
</body>
</html>
心有猛虎_细嗅蔷薇
慕妹5461943
peterJS
路人丶丨
蜂之谷
相关分类