<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
<script type="text/javascript">
function hide(){
var add=document.getElementById("con");
add.style.display="none";
}
function show(){
var add=document.getElementById("con");
add.style.display="block";
}
</script>
</head>
<body>
<p id="con">js</p>
<form>
<input type="button" onclick="hide()" value="隐藏" />
<input type="button" onclic="show()" value="显示" />
</form>
</body>
</html>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
<script type="text/javascript">
function hide(){
var add=document.getElementById("con");
add.style.display="none";
}
function show(){
var add=document.getElementById("con");
add.style.display="block";
}
</script>
</head>
<body>
<p id="con">js</p>
<form>
<input type="button" onclick="hide()" value="隐藏" />
<input type="button" onclic="show()" value="显示" />
</form>
</body>
</html>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>无标题文档</title>
<script type="text/javascript">
function hide(){
var add=document.getElementById("con");
add.style.display="none";
}
function show(){
var add=document.getElementById("con");
add.style.display="block";
}
</script>
</head>
<body>
<p id="con">js</p>
<form>
<input type="button" onclick="hide()" value="隐藏" />
<input type="button" onclic="show()" value="显示" />
</form>
</body>
</html>
我的代码的,点击了隐藏的那个按钮以后,点击显示的那个按钮,可是显示的那个按钮没用,谁能帮我解决这个问题
我想说你粗心了,onclick,你少了个k