This example combines the setTimeout Function in jquery + js to realize the advertisement that is always floating in the lower right corner of the page. If you need it, refer to it.
The Code is as follows:
SetTimeout ("document. getElementById ('qq _ dd'). style. display = 'block';", 5000 );
// JavaScript Document
$ (Function (){
If ($. browser. msie & $. browser. version = "6.0" & $ ("html") [0]. scrollHeight> $ ("html "). height ())
$ ("Html" ).css ("overflowY", "scroll ");
$ ("Html" ).css ("overflowX", "hidden ");
});
Function right_down (){
Document. writeln ("
")
}
Right_down ();
$ ("# Guanbi"). click (function (){
$ ("# My_img"). hide ();
});
$ ("# Guanbi0"). click (function (){
$ ("# My_img"). hide ();
});
Function rattleimage () {$ ("# my_img "). animate ({top: '+ = 3'}, 50); $ ("# my_img "). animate ({left: '+ = 3'}, 50); $ ("# my_img "). animate ({top: '-= 3'}, 50); $ ("# my_img "). animate ({left: '-= 3'}, 50); $ ("# my_img "). animate ({top: '+ = 3'}, 50); $ ("# my_img "). animate ({left: '+ = 3'}, 50); $ ("# my_img "). animate ({top: '-= 3'}, 50); $ ("# my_img "). animate ({left: '-= 3'}, 50); $ ("# my_img "). animate ({top: '+ = 3'}, 50); $ ("# my_img "). animate ({left: '+ = 3'}, 50); $ ("# my_img "). animate ({top: '-= 3'}, 50); $ ("# my_img "). animate ({left: '-= 3'}, 50); $ ("# my_img "). animate ({top: '+ = 3'}, 50); $ ("# my_img "). animate ({left: '+ = 3'}, 50); $ ("# my_img "). animate ({top: '-= 3'}, 50); $ ("# my_img "). animate ({left: '-= 3'}, 50); $ ("# my_img "). animate ({top: '+ = 3'}, 50); $ ("# my_img "). animate ({left: '+ = 3'}, 50); $ ("# my_img "). animate ({top: '-= 3'}, 50); $ ("# my_img "). animate ({left: '-= 3'}, 50); $ ("# my_img "). fadeOut ("slow"); $ ('# my_img '). fadeIn ('low'); setTimeout ("rattleimage ()", 10000 );}
Rattleimage ();