SPIP

[ar] [ast] [bg] [br] [ca] [co] [cpf] [cs] [da] [de] [en] [eo] [es] [eu] [fa] [fon] [fr] [gl] [id] [it] [ja] [lb] [nl] [oc] [pl] [pt] [ro] [ru] [sk] [sv] [tr] [uk] [vi] [zh] Espace de traduction

Download

#HTTP_HEADER

July 2010

All the versions of this article:


The #HTTP_HEADER{argument} tag (since SPIP 1.9) is used to modify the HTTP header for the page generated by SPIP.

Remarks:
-  #HTTP_HEADER can not be preceded by any character or blank space.
-  #HTTP_HEADER must not be preceded by any other HTML code. Example:

 
 <BOUCLE_truc(ARTICLES)>        
 <!-- start of the page -->
 #HTTP_HEADER{...}                  
 ...
 
_

not good!

_

 
 <BOUCLE_truc(ARTICLES)>        
 #HTTP_HEADER{...}                  
 <!-- start of the page -->
 ...
 
_

correct!

_

-  Using this tag deletes the administration buttons.
-  This tag can not be used in template files included using the <INCLURE> syntax.

Usage examples:
-  #HTTP_HEADER{Content-Type: text/css} is used to specify that the template (with the .html file extension) is in fact a stylesheet. For more information on this, refer to the article on SPIP-Contrib: Dynamic stylesheets - loops and tags in the CSS.
-  #HTTP_HEADER{Content-Type: text/plain; charset=#CHARSET} for the text version of an article.
-  #HTTP_HEADER{Content-Type: text/csv; charset=#CHARSET}
#HTTP_HEADER{Content-Disposition: attachment; filename=rapport.csv} for a template file that generates a CSV file.


Show the template of this page Site powered by SPIP | Translation area | Private area