Template

Difference between revisions of "FeedData"

 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>{{#vardefine:feedimage|{{{image|}}}}}{{#vardefine:feeddesc|{{{desc|}}}}}</includeonly><noinclude>
<includeonly>{{#vardefine:feedimage|{{{image|}}}}}{{#vardefine:feeddesc|{{{desc|}}}}}{{#feedtags:{{{tags|}}}}}</includeonly><noinclude>
This template stores the thumbnail image and short description used when this page appears in a feed.
Put this at the very top of any page that should look good in a Feed. It shows nothing on the page itself; the feed reads the values typed here.


Usage: place at the very top of any article/post:
<pre>
<pre>
{{FeedData
{{FeedData
|image=SomePicture.jpg
|image=CampingTrail.jpg
|desc=A short one or two sentence teaser, no more than a couple lines.
|desc=A short teaser, one or two sentences.
|cta=https://example.com/book
|ctalabel=Book now
}}
}}
</pre>
</pre>
</noinclude>


<includeonly>{{#vardefine:feedimage|{{{image|}}}}}{{#vardefine:feeddesc|{{{desc|}}}}}</includeonly><noinclude>
* '''image''' – file name of an uploaded picture, without "File:" in front, or a full web address of a picture (https://.../pic.jpg).
This template stores the thumbnail image and short description used when this page appears in a feed.
* '''desc''' – short teaser (a card shows at most 3 lines).
 
* '''tags''' – OPTIONAL. Keywords separated by commas, without #. They show under the page as #keyword links. (The edit box fills this in.)
Usage: place at the very top of any article/post:
* '''cta''' – OPTIONAL. Web address for this post's own button, starting with <code>https://</code>. It only appears in feeds that have <code>postbuttons=1</code>.
<pre>
* '''ctalabel''' – OPTIONAL. Text on that button (default "Learn more").
{{FeedData
|image=SomePicture.jpg
|desc=A short one or two sentence teaser, no more than a couple lines.
}}
</pre>
</noinclude>
</noinclude>

Latest revision as of 02:18, 21 October 2026

Put this at the very top of any page that should look good in a Feed. It shows nothing on the page itself; the feed reads the values typed here.

{{FeedData
|image=CampingTrail.jpg
|desc=A short teaser, one or two sentences.
|cta=https://example.com/book
|ctalabel=Book now
}}
  • image – file name of an uploaded picture, without "File:" in front, or a full web address of a picture (pic.jpg).
  • desc – short teaser (a card shows at most 3 lines).
  • tags – OPTIONAL. Keywords separated by commas, without #. They show under the page as #keyword links. (The edit box fills this in.)
  • cta – OPTIONAL. Web address for this post's own button, starting with https://. It only appears in feeds that have postbuttons=1.
  • ctalabel – OPTIONAL. Text on that button (default "Learn more").