Widget:Tweet: Difference between revisions
Tag: Undo |
Added parameter explanation |
||
Line 6: | Line 6: | ||
<code><nowiki>{{#widget:</nowiki>{{PAGENAME}}<nowiki>|id = example}}</nowiki></code> | <code><nowiki>{{#widget:</nowiki>{{PAGENAME}}<nowiki>|id = example}}</nowiki></code> | ||
Replace <code>example</code> with the ID of the Tweet found in the URL. | Replace <code>example</code> with the ID of the Tweet found in the URL. You can also add the following optional parameters (separated using <code>|</code> symbols within the brackets): | ||
* <code>width = W</code> (replace <code>W</code> with the desired width in pixels) | |||
* <code>float</code> (places the video along the right side of the page, also changes the default width) | |||
</noinclude><includeonly><div <!--{if isset($float)}-->style="float: right; margin-bottom: 0.5em; margin-left: 1em; width: <!--{if isset($float)}--><!--{$width|escape:'html'|default:'440'}--><!--{else}--><!--{$width|escape:'html'|default:'550'}--><!--{/if}-->px;"<!--{/if}-->><blockquote class="twitter-tweet" data-dnt="true"><a href="https://twitter.com/_/status/<!--{$id|escape:'urlpathinfo'}-->"></a></blockquote></div><script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script></includeonly> | </noinclude><includeonly><div <!--{if isset($float)}-->style="float: right; margin-bottom: 0.5em; margin-left: 1em; width: <!--{if isset($float)}--><!--{$width|escape:'html'|default:'440'}--><!--{else}--><!--{$width|escape:'html'|default:'550'}--><!--{/if}-->px;"<!--{/if}-->><blockquote class="twitter-tweet" data-dnt="true"><a href="https://twitter.com/_/status/<!--{$id|escape:'urlpathinfo'}-->"></a></blockquote></div><script async src="https://platform.twitter.com/widgets.js" charset="utf-8"></script></includeonly> |
Revision as of 06:39, 22 January 2023
This widget allows you to add a Tweet card to your wiki page.
Using this widget
To insert this widget, use the following syntax:
{{#widget:Tweet|id = example}}
Replace example
with the ID of the Tweet found in the URL. You can also add the following optional parameters (separated using |
symbols within the brackets):
width = W
(replaceW
with the desired width in pixels)float
(places the video along the right side of the page, also changes the default width)