10-04-2009, 08:05 PM
|
#4 (permalink)
|
|
how quixotic are you?
Join Date: Dec 2007
Location: Lapeer, MI
Posts: 445
Thanks: 37
|
Add myfunction() after you load the new image:
Code:
$(document).ready(function() {
function myfunction()
{
// This will hold our timer
var myTimer = {};
myTimer = $.timer(2000, function(){
// Load the new image.
$("#head").load("HeaderChanger.php");
myfunction();
});
}
while(true)
{
setTimeout(myfunction(), 2000);
}
});
Also, for this particular application you may want to consider using the more simple Delay Plugin.
Btw how do you do the javascript code coloring?
|
|
|
|