Question : AJAX not working correctly with DOCTYPE included (on firefox)

I am using ajax for cascading select boxes.  I have a waiting logo that revolves in the center of the screen while the next drop down box is loading.

When I remove DOCTYPE...the loader displays in the center of the screen with a grayed-out background.

When the DOCTYPE is included...the loader displays on the right of the screen with no background color (overlay).

Please help!

Thanks
Nick

Answer : AJAX not working correctly with DOCTYPE included (on firefox)

A few observations I noticed at a glance:

   s.position = "absolute",  ==> s.position = "absolute";

I think you meant a semicolon instead of a comma, although it makes not noticeable difference.

Now, to fix your problem, you need only change

   s.width = w;

to

   s.width = w + 'px';

and the same wherever you want to set width and height. It is not required when you set both to 0 (as you did in s.top and s.left), but it is necessary in strict mode for any other setting.




Random Solutions  
 
programming4us programming4us