为什么隐藏和显示没反应呢?
<input type="button" value="隐藏内容" onclick = "hidden()">
<input type="button" value="显示内容" onclick = "show()">
<input type="button" value="取消设置" onclick = "unSetting()">
</form>
<script type="text/javascript">
//定义"改变颜色"的函数
function changeColor(){
var mychar = document.getElementById("txt");
mychar.style.color = "red";
mychar.style.backgroundColor = "#ccc";
}
//定义"改变宽高"的函数
function changewihe(){
var mychar = document.getElementById("txt");
mychar.style.width = "500px";
mychar.style.height = "600px";
}
//定义"隐藏内容"的函数
function hidden(){
var mychar = document.getElementById("txt");
mychar.style.display = "none";
}
//定义"显示内容"的函数
function show(){
document.getElementById("txt").style.display = "block";
}