mirror of
https://github.com/rn10950/RetroZilla.git
synced 2024-11-09 09:20:15 +01:00
36 lines
921 B
HTML
36 lines
921 B
HTML
|
<html><head></head><body>
|
||
|
<html>
|
||
|
<head>
|
||
|
<script>
|
||
|
function show() {
|
||
|
document.getElementById("div1").setAttribute("value","visible");
|
||
|
}
|
||
|
|
||
|
function hide() {
|
||
|
document.getElementById("div1").setAttribute("value","hidden");
|
||
|
}
|
||
|
</script>
|
||
|
|
||
|
<style>
|
||
|
div[id="div1"][value="hidden"] {
|
||
|
background-color: blue;
|
||
|
visibility: hidden;
|
||
|
}
|
||
|
|
||
|
div[id="div1"][value="visible"] {
|
||
|
background-color: red;
|
||
|
}
|
||
|
</style>
|
||
|
</head>
|
||
|
|
||
|
<body>
|
||
|
<div id="div1" value="hidden">
|
||
|
this is text
|
||
|
<button> foo </button>
|
||
|
<iframe src="http://www.yahoo.com">
|
||
|
</div>
|
||
|
<button onclick="show(this)">show</button>
|
||
|
<button onclick="hide(this)">hide</button>
|
||
|
</body>
|
||
|
</html>
|