Want to contribute? Join the Discord and ask for the editor role.
Template:SEO: Difference between revisions
Template page
RTGame>Alistair3149 (cache seo description for 1 day) |
No edit summary Tag: 2017 source edit |
||
(One intermediate revision by the same user not shown) | |||
Line 3: | Line 3: | ||
API call | API call | ||
Retrieve description from TextExtracts through Mediawiki Action API | Retrieve description from TextExtracts through Mediawiki Action API | ||
https:// | https://wiki.rtgame.co.uk/api.php?action=help&modules=query%2Bextracts | ||
-->{{#get_web_data:url={{SERVER}}/api.php?action=query&smaxage=86400&maxage=86400&format=json&prop=extracts&titles={{#ifeq:{{lc:{{#titleparts:{{FULLPAGENAME}}|1|-1}}}}|{{#language:{{#titleparts:{{FULLPAGENAME}}|1|-1}}}}|{{#ifexist:{{FULLPAGENAME}}/en|{{FULLPAGENAMEE}}/en|{{FULLPAGENAMEE}}}}|{{FULLPAGENAMEE}}}}&exintro=1&exchars=160&explaintext=1|format=JSON|data=description=extract}}<!-- | -->{{#get_web_data:url={{SERVER}}/api.php?action=query&smaxage=86400&maxage=86400&format=json&prop=extracts&titles={{#ifeq:{{lc:{{#titleparts:{{FULLPAGENAME}}|1|-1}}}}|{{#language:{{#titleparts:{{FULLPAGENAME}}|1|-1}}}}|{{#ifexist:{{FULLPAGENAME}}/en|{{FULLPAGENAMEE}}/en|{{FULLPAGENAMEE}}}}|{{FULLPAGENAMEE}}}}&exintro=1&exchars=160&explaintext=1|format=JSON|data=description=extract}}<!-- | ||
Line 12: | Line 12: | ||
-->{{#if:{{#var:infoboxseo}}|{{#seo: | -->{{#if:{{#var:infoboxseo}}|{{#seo: | ||
|description={{#if:{{{description|}}}|{{{description}}}|{{#if:{{#external_value:description}}|{{#external_value:description}}|No description is found for this page. The | |description={{#if:{{{description|}}}|{{{description}}}|{{#if:{{#external_value:description}}|{{#external_value:description}}|No description is found for this page. The RTGame Wiki: Everything you need to know about everyone's favourite irish content creator. Subscribe to his channel or else.}}}} | ||
}}|{{#seo: | }}|{{#seo: | ||
|description={{#if:{{{description|}}}|{{{description}}}|{{#if:{{#external_value:description}}|{{#external_value:description}}|No description is found for this page. The | |description={{#if:{{{description|}}}|{{{description}}}|{{#if:{{#external_value:description}}|{{#external_value:description}}|No description is found for this page. The RTGame Wiki: Everything you need to know about everyone's favourite irish content creator. Subscribe to his channel or else.}}}} | ||
|keywords=wiki, | |keywords=wiki,rtgame{{#if:{{{keywords|}}}|,{{{keywords}}}}} | ||
|image={{#if:{{{image|}}}|{{{image}}}}} | |image={{#if:{{{image|}}}|{{{image}}}}} | ||
|type=article | |type=article | ||
|locale={{PAGELANGUAGE}} | |locale={{PAGELANGUAGE}} | ||
|site_name= | |site_name=RTGame Wiki | ||
}}}}<!-- | }}}}<!-- | ||
Latest revision as of 13:15, 7 May 2021
This documentation is transcluded from Template:SEO/doc. Changes can be proposed in the talk page.
{{SEO}} adds SEO configurations to an article page. This should be added to the bottom of all article pages on main namespace, below navplates and above short description, categories, and stub template. See RT:LAYOUT for details on where to place it.