Actually there *IS* a way to do this. It is pretty sneaky. Not my idea. I got it from Raymond Camden's Blog.
http://www.coldfusionjedi.com/index.cfm/2008/1/26/Ask-a-Jedi-CFIMPORT-Applicationcfc-and-custom-tags Create a folder under a mapped path COM called tagLib Create a file under it called body.cfm In the application.cfm or application.cfc (in the onRequest method), add <cfimport taglib="/com/tagLib"> Now, for the source of the body.cfm custom tag: <cfif thistag.executionMode eq 'Start'><body></cfif>; <cfif thistag.executionMode eq 'End'><script language="javascript1.1" src="/somedir" type="text/javascript"> xxCreatePageViewTag("Housewares","Cool Kitchen Gadgets","Page 1"); </script></cfif> This will effectively replace Body with the contents of your Custom tag. I have tried it before and it works. It is pretty damn ingenious. I am not sure what it will do with the body tag attributes you might have to add them to your custom tag. hth G On Tue, Mar 25, 2008 at 5:16 PM, Jerry Johnson <[EMAIL PROTECTED]> wrote: > Just wanted to put it out there (or _my_ coworkers would yell at _me_). > lol. > > OK, just winging it here, but i think if you include a standard javascript > function or include at the top that attaches a function to the onLoad for > the body, the function it attaches would be the coldfusion-custom > javascript > to call the view stasher. > > Not 100% sure if the objects all exist at the right time, but it could > maybe > get you there. > > > On Tue, Mar 25, 2008 at 5:01 PM, Gerald Weir <[EMAIL PROTECTED]> wrote: > > > Jerry, I appreciate your point and it is a good one. I'm just the > > programmer however, it's their call I'm afraid. > > > > Yes, your question is correct, this is the javascript report the page > view > > so in the end it must go on all. > > > > Thanks, Gerald > > > > -----Original Message----- > > From: Jerry Johnson [mailto:[EMAIL PROTECTED] > > Sent: Tuesday, March 25, 2008 4:53 PM > > To: CF-Talk > > Subject: Re: Need Include to be first thing after BODY tag > > > > > > Not to help you at all, and providing info you didn't ask for, but... > > > > Best practices when counting pages is to wait for the page to load, or > > most > > of the page to load, before counting that page. > > > > This is especially true when counting advertising page views, or > counting > > pages read for subscription purposes. > > > > (If the page didn't load, they couldn't have actually read it, and > > counting > > it as a view is a bit of a stretch.) > > > > But now on to your question. Are you trying to find a way to do it on > > every > > page, without having to actually write it into every page? > > > > Jerry > > > > > > On Tue, Mar 25, 2008 at 4:24 PM, Gerald Weir <[EMAIL PROTECTED]> > wrote: > > > > > Yes, they want it directly after the <body> tag. Their claim is that > > the > > > want to be sure to count the page in the event that a user clicks away > > to > > > another page before the current page is fully loaded. > > > > > > p.s. I hope this goes to the correct place - mailing list - as I > don't > > > see my own question on the CF-Talk web page. > > > > > > Thanks, Jerry > > > > > > -----Original Message----- > > > From: Claude Schneegans [mailto:[EMAIL PROTECTED] > > > Sent: Tuesday, March 25, 2008 4:16 PM > > > To: CF-Talk > > > Subject: Re: Need Include to be first thing after BODY tag > > > > > > > > > >>the javascripts must be included right after the opening <body> > tag. > > > > > > Are you sure they really specify "right after the opening <body> tag" > > > or do they just mean "inside the body tag"? > > > > > > I cannot think of any valuable technical reason the Javascript > couldn't > > > be right before the </BODY> tag. > > > > > > -- > > > _______________________________________ > > > REUSE CODE! Use custom tags; > > > See http://www.contentbox.com/claude/customtags/tagstore.cfm > > > (Please send any spam to this address: [EMAIL PROTECTED]) > > > Thanks. > > > > > > > > > > > > > > > > > > > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:302057 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

