Code :
<button>Show hidden to see they don't change</button>
<div></div>
<div class="starthidden"></div>
<div></div>
<div></div>
<div style="display: none;"></div>
<style type="text/css">
div
{
width: 50px;
height: 40px;
margin: 5px;
border: 3px outset green;
float: left;
}
.starthidden
{
display: none;
}
</style>
<script type="text/javascript">
$(document).ready(function () {
$("div:visible").click(function () {
$(this).css("background", "yellow");
});
$("button").click(function () {
$("div:hidden").show("fast");
return false;
});
});
</script>
<button>Show hidden to see they don't change</button>
<div></div>
<div class="starthidden"></div>
<div></div>
<div></div>
<div style="display: none;"></div>
<style type="text/css">
div
{
width: 50px;
height: 40px;
margin: 5px;
border: 3px outset green;
float: left;
}
.starthidden
{
display: none;
}
</style>
<script type="text/javascript">
$(document).ready(function () {
$("div:visible").click(function () {
$(this).css("background", "yellow");
});
$("button").click(function () {
$("div:hidden").show("fast");
return false;
});
});
</script>
Comments
Post a Comment