[Content_Expires]

Description

Link: [Content_Expires]
Author: Daniel Logue
Category: Technical
Version: 8.5.x
License: Public Domain
Posted: Sep. 28, 2007
Updated: Sep. 28, 2007
More by this author...
This tag modifies the content headers with an appropriately formatted date/time string for the page to expire, based on 1 date/time parameter.

Parameters

-date date, optional The date/time you want the content to expire.

Sample Usage

[

Content_Expires:(Date_Add:date,-Minutes=15);

]
						

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.
1
2
3
4
5
6
7
8
9
10
11
12
[

Define_Tag:'Content_Expires',
-Required='date';

   Local:'expires'=(Date_LocalToGMT:#date);

   Content_Header+='Expires: '#expires->(Format:'%a')', '#expires->(Format:'%d')' '#expires->(Format:'%b')' '#expires->(Format:'%Y')' '#expires->(Format:'%T')' GMT\r\n';
   
/Define_Tag;

]

 

Comments

none

Email:


Password:



Newest

Most Popular

Support tagSwap.net