Couldn't you make a "Preload" file that runs the JS code setting everything else up before you run the body of the code?
On Tue, Jul 15, 2008 at 11:40 AM, Stephens, Larry V <[EMAIL PROTECTED]> wrote: > I'm working on a church site and there's some concern about the size of the > screen versus the size of the monitor it's on. This includes random loading > of photos and text. I've also had this concern on my wife's site. > > I'm currently calling a javascript function in <body onload> which reads the > screensize and sets a cookie for width and a cookie for height. CF then reads > those cookies and adjusts table widths, cell widths and heights, picks which > images to load (same image, two sizes), etc. > > Seems to be working except once in awhile the program doesn't seem to pick up > a change in screen size until you do a reload. When I look at Google topics > on <body onload> they say to me that there's no guarantee <body onload> will > fire the javascript (and, in my case, set the cookies) before other parts of > the page load and - in my case - some of the CF code starts running. > > Comments on that? Any ideas on how to better do this? > > FWIW, some pages have content that I force to a small screen size. Some pages > have a lot of info and, for people with bigger monitors, it will be a benefit > to take advantage of that increased real estate. > > Larry Stephens > [EMAIL PROTECTED] > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;203748912;27390454;j Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309101 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4