Thanks. I'm going to add it as an onNewSession event. I've got a sweet logging app written and this will be a nice addition. My time was taken between writing a stat package for the logging data, the new HoF/FA layout and a new user module. This will have to go on my 'to do now' list. Fun. :)
> > Does that script run on anything other than IE? If so, can you pass me a > > copy. I'll add it to the HoF logging. > > Thanks > > An older version of the script (and the back end support code) is here: > > http://www.depressedpress.com/depressedpress/Content/Development/ColdFusio > n/ > Articles/GetRes/Index.cfm > > The newer one just adds "BrowserHeight" variables (I've got to update that > article...). I've appended it below. You'll have to add that to the CF > page and decide what to do with the values (I store them during end of > session processing). > > I've not cross browser-tested as much as I could have, but it seems to > work > the major ones I've hit. > > Sorry for being so short, but I'm getting crushed by work at the moment. > But I don't figure you need much hand-holding. ;^) > > Jim Davis > > > <!--- Output the GetRes Code ---> > <script language="Javascript" type="text/javascript">var JSVersion = > 1.0</script> > <script language="Javascript1.1" type="text/javascript">JSVersion = > 1.1</script> > <script language="Javascript1.2" type="text/javascript">JSVersion = > 1.2</script> > <script language="Javascript1.3" type="text/javascript">JSVersion = > 1.3</script> > <script language="Javascript1.4" type="text/javascript">JSVersion = > 1.4</script> > <script language="Javascript1.5" type="text/javascript">JSVersion = > 1.5</script> > <script language="Javascript" type="text/javascript"><!-- > > // Default all Values to Zero > ColorDepth = 0; > ResHeight = 0; > ResWidth = 0; > ResAvailHeight = 0; > ResAvailWidth = 0; > ResBrowserHeight = 0; > ResBrowserWidth = 0; > // Get the basic values > if (JSVersion > 1.1) { > ColorDepth = screen.colorDepth; > ResHeight = screen.height; > ResWidth = screen.width; > ResAvailHeight = screen.availHeight; > ResAvailWidth = screen.availWidth; > }; > // Try to get the Browser Window info > // If the innerwidth property is set then try to use that - > supported by Netscape and several other browsers > if( typeof( window.innerWidth ) == 'number' ) { > ResBrowserWidth = window.innerWidth; > ResBrowserHeight = window.innerHeight; > // The following is only supported by IE 6 in some cases. > } else if( ( typeof( document.documentElement.clientWidth ) == > 'number' ) && ( document.documentElement.clientWidth > 0 ) ) { > ResBrowserWidth = document.documentElement.clientWidth; > ResBrowserHeight = document.documentElement.clientHeight; > // Finally test if we're IE and use the IE specific values > } else if( document.body && ( document.body.clientWidth || > document.body.clientHeight ) ) { > ResBrowserWidth = document.body.clientWidth; > ResBrowserHeight = document.body.clientHeight; > }; > // Create the call to the image > document.write("<img > src='<cfoutput>#TagRelFromWebRoot#</cfoutput>/FauxGIF.cfm?ScreenData=JS" + > JSVersion + "," + ColorDepth + "," + ResHeight + "," + ResWidth + "," + > ResAvailHeight + "," + ResAvailWidth + "," + ResBrowserHeight + "," + > ResBrowserWidth + "' width='1' height='1' alt='' border='0'>"); > > //--> > </script> > <noscript><img name="HeartBeat" > src="FauxGIF.cfm?ScreenData=NoJS,0,0,0,0,0,0,0" width="1" height="1" > alt="" > border="0"></noscript> > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Special thanks to the CF Community Suite Silver Sponsor - New Atlanta http://www.newatlanta.com Message: http://www.houseoffusion.com/lists.cfm/link=i:5:141279 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/5 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:5 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.5 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54
