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.
Parameters
none
Sample Usage
if: lp_client_isPrefetch;
'You are prefetching this content!';
/if;
Source Code
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;
]