Difference between revisions of "Template:Domain uses/doc"

From blackwiki
Jump to navigation Jump to search
imported>Newslinger
(Create documentation for Template:Domain uses)
 
imported>Newslinger
(→‎Usage: Clarify unnamed)
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
{{Documentation subpage}}
 
{{Documentation subpage}}
 
<!-- 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]]) -->
 +
{{tsh|duses}}
 
This template displays three links to search results for uses of a [[domain name]] across Wikipedia pages:
 
This template displays three links to search results for uses of a [[domain name]] across Wikipedia pages:
 
# An <code>[[H:INSOURCE|insource:]]</code> [[Special:Search|search]] for the domain name
 
# An <code>[[H:INSOURCE|insource:]]</code> [[Special:Search|search]] for the domain name
Line 7: Line 8:
  
 
== Usage ==
 
== Usage ==
This template accepts two parameters:
+
This template accepts two unnamed [[WP:PARAMETER|parameters]]:
 
# The domain name to be searched, e.g. <code>example.com</code> or <code>subdomain.example.com</code>
 
# The domain name to be searched, e.g. <code>example.com</code> or <code>subdomain.example.com</code>
 
# Link text for the first link (which uses <code>[[H:INSOURCE|insource:]]</code>)
 
# Link text for the first link (which uses <code>[[H:INSOURCE|insource:]]</code>)
#* This parameter is optional, and defaults to parameter #1 if left empty.
+
#* This parameter is optional, and defaults to the domain name if left empty.
  
 
== Examples ==
 
== Examples ==
Line 29: Line 30:
 
<includeonly>{{sandbox other||
 
<includeonly>{{sandbox other||
 
<!-- Categories below this line, please; interwikis at Wikidata -->
 
<!-- Categories below this line, please; interwikis at Wikidata -->
 
+
[[Category:Search templates|{{PAGENAME}}]]
 +
[[Category:External link templates|{{PAGENAME}}]]
 
}}</includeonly>
 
}}</includeonly>

Latest revision as of 14:52, 13 January 2019

This template displays three links to search results for uses of a domain name across Wikipedia pages:

  1. An insource: search for the domain name
  2. An external links search for https:// URLs of the domain and its subdomains
  3. An external links search for http:// URLs of the domain and its subdomains

Usage

This template accepts two unnamed parameters:

  1. The domain name to be searched, e.g. example.com or subdomain.example.com
  2. Link text for the first link (which uses insource:)
    • This parameter is optional, and defaults to the domain name if left empty.

Examples

{{Domain uses|example.com}}

example.com HTTPS links HTTP links


{{Domain uses|example.com|Link text}}

Link text HTTPS links HTTP links

See also