Link | lp_client_isPrefetch |
Author | Bil Corry |
Category | Bytes |
Version | 8.x |
License | Public Domain |
Posted | 24 Aug 2006 |
Updated | 24 Aug 2006 |
More by this author... |
Google Web Accelerator and Mozilla browsers can prefetch pages, basically load pages that appear as links on the current page. This tag looks to see if the header "x-moz: prefetch" is present, if so, the page is being prefetched by the client browser.
if: lp_client_isPrefetch; 'You are prefetching this content!'; /if;
Click the "Download" button below to retrieve a copy of this tag, including the complete documentation and sample usage shown on this page. Place the downloaded ".inc" file in your LassoStartup folder, restart Lasso, and you can begin using this tag immediately.
[ define_tag: 'lp_client_isPrefetch', -description='Returns true if client is doing a prefetch.', -priority='replace'; // looks for header "x-moz: prefetch" currently sent by Google Web Accelerator and Mozilla browsers // more info on prefetching: // http://webaccelerator.google.com/webmasterhelp.html // http://www.mozilla.org/projects/netlib/Link_Prefetching_FAQ.html#Do_prefetched_requests_contain_a // http://david.backpackit.com/pub/37983 if: (string_findregexp: client_headers, -find='x-moz:\\s+.*prefetch', -ignorecase)->size; return: true; /if; return: false; /define_tag; ]
No comments
©LassoSoft Inc 2015 | Web Development by Treefrog Inc | Privacy | Legal terms and Shipping | Contact LassoSoft