Difference between revisions of "Template:Ifexist not redirect/doc"
Jump to navigation
Jump to search
imported>Alex 21 (Create doc) |
imported>Alex 21 |
||
| Line 2: | Line 2: | ||
<!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) --> | <!-- Please place categories where indicated at the bottom of this page and interwikis at Wikidata (see [[Wikipedia:Wikidata]]) --> | ||
== Usage == | == Usage == | ||
| − | The | + | The '''<nowiki>{{</nowiki>Ifexist not redirect}}''' template returns true if an article exists ''and'' exists as an actual article, and returns false if the article either does not exist or exists as a redirect, whereas {{#ifexist}} will return true if the article is a redirect. Use the format <code><nowiki>{{Ifexist not redirect|article}}</nowiki></code>. |
==Examples== | ==Examples== | ||
| − | + | ''Existing article'' ([[List of Doctor Who serials]]): | |
| − | * {{ | + | * <code><nowiki>{{Ifexist not redirect|List of Doctor Who serials}}</nowiki></code>: {{Ifexist not redirect|List of Doctor Who serials}} |
* <code><nowiki>{{#ifexist:List of Doctor Who serials|yes}}</nowiki></code>: {{#ifexist:List of Doctor Who serials|yes}} | * <code><nowiki>{{#ifexist:List of Doctor Who serials|yes}}</nowiki></code>: {{#ifexist:List of Doctor Who serials|yes}} | ||
| − | + | ''Redirect'' ([[List of Daredevil episodes]]): | |
| − | * {{ | + | * <code><nowiki>{{Ifexist not redirect|List of Daredevil episodes}}</nowiki></code>: {{Ifexist not redirect|List of Daredevil episodes}} |
* <code><nowiki>{{#ifexist:List of Daredevil episodes|yes}}</nowiki></code>: {{#ifexist:List of Daredevil episodes|yes}} | * <code><nowiki>{{#ifexist:List of Daredevil episodes|yes}}</nowiki></code>: {{#ifexist:List of Daredevil episodes|yes}} | ||
| − | + | ''Non-existant article'' ([[Green Arrow episodes]]): | |
| − | * {{ | + | * <code><nowiki>{{Ifexist not redirect|Green Arrow episodes}}</nowiki></code>: {{Ifexist not redirect|Green Arrow episodes}} |
* <code><nowiki>{{#ifexist:Green Arrow episodes|yes}}</nowiki></code>: {{#ifexist:Green Arrow episodes|yes}} | * <code><nowiki>{{#ifexist:Green Arrow episodes|yes}}</nowiki></code>: {{#ifexist:Green Arrow episodes|yes}} | ||
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | | <includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | | ||
<!-- Categories below this line, please; interwikis at Wikidata --> | <!-- Categories below this line, please; interwikis at Wikidata --> | ||
}}</includeonly> | }}</includeonly> | ||
Revision as of 03:11, 28 February 2016
| This is a documentation subpage for Template:Ifexist not redirect. It contains usage information, categories and other content that is not part of the original template page. |
Usage
The {{Ifexist not redirect}} template returns true if an article exists and exists as an actual article, and returns false if the article either does not exist or exists as a redirect, whereas {{#ifexist}} will return true if the article is a redirect. Use the format {{Ifexist not redirect|article}}.
Examples
Existing article (List of Doctor Who serials):
{{Ifexist not redirect|List of Doctor Who serials}}:{{#ifexist:List of Doctor Who serials|yes}}:
Redirect (List of Daredevil episodes):
{{Ifexist not redirect|List of Daredevil episodes}}:{{#ifexist:List of Daredevil episodes|yes}}:
Non-existant article (Green Arrow episodes):
{{Ifexist not redirect|Green Arrow episodes}}:{{#ifexist:Green Arrow episodes|yes}}: