Sophie

Sophie

distrib > Mageia > 7 > aarch64 > by-pkgid > d8544620e4ac7bee48ddb48c85d55709 > files > 113

ikiwiki-3.20190228-1.mga7.noarch.rpm

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>meta</title>
<meta name="viewport" content="width=device-width, initial-scale=1" />

<link rel="stylesheet" href="../../style.css" type="text/css" />

<link rel="stylesheet" href="../../local.css" type="text/css" />






<meta name="robots" content="noindex, follow" />



</head>
<body>

<div class="page">

<div class="pageheader">
<div class="header">
<span>
<span class="parentlinks">

<a href="../../index.html">ikiwiki</a>/ 

<a href="../../ikiwiki.html">ikiwiki</a>/ 

<a href="../directive.html">directive</a>/ 

</span>
<span class="title">
meta

</span>
</span>



</div>









</div>





<div id="pagebody">

<div id="content" role="main">
<p>The <code>meta</code> directive is supplied by the <a href="http://ikiwiki.info/plugins/meta/">meta</a> plugin.</p>

<p>This directive allows inserting arbitrary metadata into the source of a page.
Enter the metadata as follows:</p>

<pre><code>[[!meta  field="value"]]
[[!meta  field="value" param="value" param="value"]]
</code></pre>

<p>The first form sets a given field to a given value, while the second form
also specifies some additional sub-parameters. You can have only one field
per <code>meta</code> directive, use more directives if you want to specify more fields.</p>

<p>The field values are treated as HTML entity-escaped text, so you can include
a quote in the text by writing <code>&amp;quot;</code> and so on.</p>

<h2>Supported fields</h2>

<ul>
<li><p>title</p>

<p>Overrides the title of the page, which is generally the same as the
page name.</p>

<p>Note that if the title is overridden, a "title_overridden" variable will
be set to a true value in the template; this can be used to format things
differently in this case.</p>

<p>An optional <code>sortas</code> parameter will be used preferentially when
<a href="../pagespec/sorting.html">sorting</a> by <code>meta(title)</code>:</p>

<p>[[!meta  title="The Beatles" sortas="Beatles, The"]]</p>

<p>[[!meta  title="David Bowie" sortas="Bowie, David"]]</p></li>
<li><p>license</p>

<p>Specifies a license for the page, for example, "GPL". Can contain
WikiLinks and arbitrary markup.</p></li>
<li><p>copyright</p>

<p>Specifies the copyright of the page, for example, "Copyright 2007 by
Joey Hess". Can contain WikiLinks and arbitrary markup.</p></li>
<li><p>author</p>

<p>Specifies the author of a page.</p>

<p>An optional <code>sortas</code> parameter will be used preferentially when
<a href="../pagespec/sorting.html">sorting</a> by <code>meta(author)</code>:</p>

<p>[[!meta  author="Joey Hess" sortas="Hess, Joey"]]</p></li>
<li><p>authorurl</p>

<p>Specifies an url for the author of a page.</p></li>
<li><p>description</p>

<p>Specifies a short description for the page. This will be put in
the html header, and can also be displayed by eg, the <a href="./map.html">map</a> directive.</p></li>
<li><p>keywords</p>

<p>Specifies keywords summarizing the contents of the page. This
information will be put in the html header.  Only letters,
numbers, spaces and commas are allowed in this string; other
characters are stripped.  Note that the majority of search
engines, including Google, do not use information from the
keywords header.</p></li>
<li><p>permalink</p>

<p>Specifies a permanent link to the page, if different than the page
generated by ikiwiki.</p></li>
<li><p>date</p>

<p>Specifies the creation date of the page. This creates a 
<code>&lt;meta name="date" content="..."&gt;</code> header in the HTML output, but also
modifies the internal <code>ctime</code> in the
<a href="http://ikiwiki.info/tips/inside_dot_ikiwiki/">internal index</a>.
The date can be entered in nearly any format, since it's parsed by
<a href="http://search.cpan.org/search?mode=dist&amp;query=TimeDate">TimeDate</a> but invalid dates yield an error in 3.20180321
or later.</p></li>
<li><p>stylesheet</p>

<p>Adds a stylesheet to a page. The stylesheet is treated as a wiki link to
a <code>.css</code> file in the wiki, so it cannot be used to add links to external
stylesheets. Example:</p>

<p>[[!meta  stylesheet=somestyle rel="alternate stylesheet"
title="somestyle"]]</p>

<p>However, this will be scrubbed away if the 
<a href="http://ikiwiki.info/plugins/htmlscrubber/">htmlscrubber</a> plugin is enabled,
since it can be used to insert unsafe content.</p></li>
<li><p>script</p>

<p>Adds a script to a page. The script is treated as a wiki link to
a <code>.js</code> file in the wiki, so it cannot be used to add links to external
scripts. The optional <code>defer</code> and <code>async</code> keywords can be used to set
the corresponding HTML4 and HTML5 script options. Example:</p>

<p>[[!meta  script=somescript defer async]]</p>

<p>The tag is subject to scrubbing as with the stylesheet and link fields.</p></li>
<li><p>openid</p>

<p>Adds html &lt;link&gt; tags to perform OpenID delegation to an external
OpenID server. This lets you use an ikiwiki page as your OpenID.</p>

<p>By default this will delegate for both <code>openid</code> and <code>openid2</code>. To only
delegate for one, add a parameter such as <code>delegate=openid</code>.</p>

<p>An optional <code>xrds-location</code>
parameter lets you specify the location of any <a href="http://www.windley.com/archives/2007/05/using_xrds.shtml">eXtensible Resource
DescriptorS</a>.</p>

<p>Example:</p>

<p>[[!meta  openid="http://joeyh.myopenid.com/"
server="http://www.myopenid.com/server"
xrds-location="http://www.myopenid.com/xrds?username=joeyh.myopenid.com"]]</p></li>
<li><p>link</p>

<p>Specifies a link to another page. This can be used as a way to make the
wiki treat one page as linking to another without displaying a user-visible
<a href="../wikilink.html">WikiLink</a>:</p>

<p>[[!meta  link=otherpage]]</p>

<p>It can also be used to insert a html &lt;link&gt; tag. For example:</p>

<p>[[!meta  link="http://joeyh.myopenid.com/" rel="openid.delegate"]]</p>

<p>However, this latter syntax won't be allowed if the 
<a href="http://ikiwiki.info/plugins/htmlscrubber/">htmlscrubber</a> plugin is enabled, since it can be used to
insert unsafe content.</p></li>
<li><p>enclosure</p>

<p>Specifies a link to a file to be rendered as an "enclosure" in
RSS/Atom feeds (and a plain old link in HTML). Useful for
<a href="http://ikiwiki.info/podcast/">podcasting</a>.</p></li>
<li><p>redir</p>

<p>Causes the page to redirect to another page in the wiki.</p>

<p>[[!meta  redir=otherpage]]</p>

<p>The default is to redirect without delay.
Optionally, a delay (in seconds) can be specified: "delay=10"</p>

<p>It can also be used to redirect to an external url. For example:</p>

<p>[[!meta  redir="http://example.com/"]]</p>

<p>However, this latter syntax won't be allowed if the 
<a href="http://ikiwiki.info/plugins/htmlscrubber/">htmlscrubber</a> plugin is enabled, since it can be used to
insert unsafe content.</p>

<p>For both cases, an anchor to jump to inside the destination page may also be
specified using the common <code>#ANCHOR</code> syntax.</p></li>
<li><p>robots</p>

<p>Causes the robots meta tag to be written:</p>

<pre><code>[[!meta  robots="index, nofollow"]]
</code></pre>

<p>Valid values for the attribute are: "index", "noindex", "follow", and
"nofollow". Multiple comma-separated values are allowed, but obviously only
some combinations make sense. If there is no robots meta tag, "index,
follow" is used as the default.</p>

<p>The value is escaped, but its contents are not otherwise checked.</p></li>
<li><p>guid</p>

<p>Specifies a globally unique ID for a page. This guid should be a URI,
and it will be used to identify the page's entry in RSS
and Atom feeds. If not given, the default is to use the page's URL as its
guid.</p>

<p>This is mostly useful when a page has moved, to keep the guids for
pages unchanged and avoid flooding aggregators
(see <a href="http://ikiwiki.info/tips/howto_avoid_flooding_aggregators/">tips/howto avoid flooding aggregators</a>).</p></li>
<li><p>updated</p>

<p>Specifies a fake modification time for a page, to be output into RSS and
Atom feeds. This is useful to avoid flooding aggregators that sort by
modification time, like Planet: for instance, when editing an old blog post
to add tags, you could set <code>updated</code> to be one second later than the original
value. The date/time can be given in any format that
<a href="http://search.cpan.org/search?mode=dist&amp;query=TimeDate">TimeDate</a> can understand, just like the <code>date</code> field and maps to the
<code>&lt;meta name="updated" content="..."&gt;</code> HTML header and internal <code>mtime</code> field.</p></li>
<li><p>foaf</p>

<p>Adds a Friend of a Friend (<a href="http://wiki.foaf-project.org/w/Autodiscovery">FOAF</a>)
reference to a page.</p>

<p>Example:</p>

<p>[[!meta  foaf=foaf.rdf]]</p></li>
<li><p>name</p>

<p>Adds a HTML <code>&lt;meta&gt;</code> header with this <code>name</code> attribute. Its other attributes are
taken from the other parameters, so for example
<code>[[!meta  name="foo" content="bar" x-non-standard-attribute="baz"]]</code>
becomes <code>&lt;meta name="foo" content="bar" x-non-standard-attribute="baz"&gt;</code>. This
won't be allowed if the <a href="http://ikiwiki.info/plugins/htmlscrubber/">htmlscrubber</a> plugin is enabled,
since it can be used to insert unsafe content.</p></li>
</ul>

<h2>Other fields</h2>

<p>If the field is not one of the above predefined fields, the metadata will be
written to the generated html page as a &lt;meta&gt; header. For example,
<code>[[!meta  foo="bar"]]</code> becomes <code>&lt;meta name="foo" content="bar"&gt;</code>. As
with <code>name</code>, this won't be allowed if the <a href="http://ikiwiki.info/plugins/htmlscrubber/">htmlscrubber</a> plugin is enabled.</p>

<p>This syntax cannot be used for meta headers with unusual names, in
particular names containing <code>:</code> such as <code>flattr:id</code> and <code>twitter:card</code>.
Please use <code>[[!meta  name="..." content="..."]]</code> for those headers.</p>

</div>







</div>

<div id="footer" class="pagefooter" role="contentinfo">

<div id="pageinfo">






<div id="backlinks">
Links:

<a href="./comment.html">comment</a>

<a href="./date.html">date</a>

<a href="./edittemplate.html">edittemplate</a>

<a href="./inline.html">inline</a>

<a href="./map.html">map</a>

<a href="./pagestats.html">pagestats</a>

<a href="../../plugins/contrib/album.html">plugins/contrib/album</a>

<a href="../../plugins/contrib/ikiwiki/directive/albumimage.html">plugins/contrib/ikiwiki/directive/albumimage</a>

<a href="../../plugins/meta.html">plugins/meta</a>

<a href="../../plugins/openid.html">plugins/openid</a>


<span class="popup">...
<span class="balloon">

<a href="../../tips/ikiwiki_as_a_requirements_management_tool.html">tips/ikiwiki as a requirements management tool</a>

<a href="../../tips/optimising_ikiwiki.html">tips/optimising ikiwiki</a>

</span>
</span>

</div>






<div class="pagedate">
Last edited <span class="date">Tue Feb 26 23:01:54 2019</span>
<!-- Created <span class="date">Tue Feb 26 23:01:54 2019</span> -->
</div>

</div>


<!-- from ikiwiki -->
</div>

</div>

</body>
</html>