Hi Everyone,

I am using Wordpress (version 3.8) and am running my app on my local PC (with xampp) in the Chrome browser. I have customized my app with a javascript font-resizer that appears in the interface and allows the user to change the font-size. The javascript is working fine. It is persistent and holds nicely the font-size value in a cookie for setting the font-size in the interface when a user revisits the site.

However I have a small problem which is a little irritating and am wondering if one of you might point me in the right direction to resolve this problem.

The problem: Whenever I refresh my window or change pages the interface first displays the font-size in the size stored in the css modules and then my font-size script runs and the desired font-size is displayed from the value stored in the cookie. This causes a blinking in the interface - first showing the font-size from css and then the font-size in the cookie.

I'm using <body onload="font-sizer();"> where the function font-sizer() changes the font-size in the interface to the user's desired font-size in the cookie. However, this function is running one step too late, i.e. right after the css font-size is displayed in the interface.

Would it be possible to inhibit the 1st display (css version) and display only the font-sizer() version? This would eliminate the blinking.

If this could be done in either javascript or jquery I would be interested in any information you might offer in order to fix this blinking problem.

Thank you in advance for your help.