[Help need] Auto refresh DIV after 1 sec ?
Moderator: General Moderators
- spamyboy
- Forum Contributor
- Posts: 266
- Joined: Sun Nov 06, 2005 11:29 am
- Location: Lithuania, vilnius
[Help need] Auto refresh DIV after 1 sec ?
Could some one help, I'm trying to make DIV, that would auto refresh after second, any tutorials/links or etc. pleas.
- Christopher
- Site Administrator
- Posts: 13596
- Joined: Wed Aug 25, 2004 7:54 pm
- Location: New York, NY, US
- feyd
- Neighborhood Spidermoddy
- Posts: 31559
- Joined: Mon Mar 29, 2004 3:24 pm
- Location: Bothell, Washington, USA
my posts on createElement may be of interest.
Code: Select all
<div id='content'>some content</div>
<script type='text/javascript'>
window.load = function() {
var counter = 0;
window.setInterval(function() {
document.getElementById('content').innerHTML = (counter++).toString();
}, 1000);
};
</script>
- spamyboy
- Forum Contributor
- Posts: 266
- Joined: Sun Nov 06, 2005 11:29 am
- Location: Lithuania, vilnius
feyd | Please use
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
bo, I still need some help:Code: Select all
<html>
<head>
<script type='text/javascript'>
window.load = function() {
window.onload = load;
var counter = 0;
window.setInterval(function() {
document.getElementById('content').innerHTML = (counter++).toString();
}, 1000);
};
</script>
</head>
<body>
<div id='content'><?php
echo rand() . "\n";
echo rand() . "\n";
echo rand(5, 15);
?></div>
</body>
</html>feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]- spamyboy
- Forum Contributor
- Posts: 266
- Joined: Sun Nov 06, 2005 11:29 am
- Location: Lithuania, vilnius
Ok here is what I got
http://85.206.235.15:12/md5/
you see those number ?
(need help with JS >>> 7848487)
I need to make them refresh svry second (only that div)
as you see those numbers shows curent number of md5 combinations
When I will upload it to server, and run one perl script witch randomly add's new md5 comb, those numbers will change evry second... wel I hope you got the point.
http://85.206.235.15:12/md5/
you see those number ?
(need help with JS >>> 7848487)
I need to make them refresh svry second (only that div)
as you see those numbers shows curent number of md5 combinations
When I will upload it to server, and run one perl script witch randomly add's new md5 comb, those numbers will change evry second... wel I hope you got the point.