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] [vi] [zh] Espace de traduction

Download

|liens_absolus

July 2010 — updated on : June 2010

All the versions of this article:


The |liens_absolus (absolute links) filter (since SPIP 1.8.2) is applied to a text type tag, e.g. (#TEXTE, #DESCRIPTIF, etc.), and transforms all links contained in that text (<a href=..., <link href:..., <img src=... and <script src=...) into absolute links (with the site’s complete URL address).

Example:
<img src="local/cache-vignettes/L500xH333/nice_picture.jpg"..
will be translated into
<img src="http://le_site.fr/local/cache-vignettes/L500xH333/nice_picture.jpg"...

and
<a href="spip.php?page=article&amp;id_article=25"...
will come out as
<a href="http://le_site.fr/spip.php?page=article&amp;id_article=25"...

-  This filter is particularly useful in templates for RSS feeds, for example.


See also the |url_absolue and |abs_url filters.


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