> Hello again,
>
> i'm using the center plugin to center images inside a div. But i have to
> call it with a timeout like this:
>
> $(document).ready(function(){
> setTimeout("doCenter()",1000);
> });
>
> function doCenter(){
> $(".jqcenter").each(){
> $(this).center();
> }
> }
>
If you DO want to use jQuery, you could use something like this;
$(document).ready(function() {
// Makes sure the image is centered no matter how often you change the
image src.
$(".jqcenter").load( function() { $(this).center(); } );
});
However, i am not sure if the onload tag for images is 100% supported.
-- Gilles
_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/