Created
August 25, 2012 19:35
-
-
Save droid242/3469927 to your computer and use it in GitHub Desktop.
DIV refresh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="hu"> | |
<head> | |
<title>DIV refresh page</title> | |
<meta charset="utf-8" /> | |
<script type="text/javascript" src="http://code.jquery.com/jquery-1.8.0.min.js"></script> | |
<script type="text/javascript"> | |
$("#changePanel").click(function() { | |
$('#panel').fadeOut('slow').fadeIn('slow'); | |
}); | |
</script> | |
<script type="text/javascript"> | |
var auto_refresh = setInterval( | |
function() { | |
$('#panel').fadeOut('slow').fadeIn('slow'); | |
}, 4000); | |
</script> | |
<style type="text/css"> | |
div { | |
padding: 1em; | |
background-color: #00c000; | |
} | |
input { | |
padding: .25em 1em; | |
} | |
</style> | |
</head> | |
<body> | |
<div id="panel" class="fixie"></div> | |
<input id="changePanel" value="Change Panel" type="button"><br /> | |
<!--a href="#" id="changePanel">click</a--> | |
<script type="text/javascript" src="https://raw.github.com/ryhan/fixie/master/fixie_min.js"></script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment