Template:Google custom
From Appropedia
[edit] Documentation
The MediaWiki software transcludes this documentation from Template:Google custom/doc. (edit | history)
Contents |
[edit] Usage
Creates a Google custom search link, which searches one site (and, optionally, pages with URLs containing one directory path in the site). (If you want to search on the entire Web, use {{Google}} instead.) This template takes three unnamed input parameters; you must supply the first one, and the last two are optional.
- A domain name, and optionally the first part of directory path (to specify one part of the site to search). This parameter becomes the values of the
sitesearch=anddomains=parameters in the resulting search URL. If the value ends in a directory path component, it evidently must end with a complete path component. For Wikipedia URLs, this would be everything up to a slash or a colon (including or not including the slash or colon has no effect on the resulting search). (Required.) Examples:-
en.wikipedia.org— (search all of the English Wikipedia) -
en.wikipedia.org/wiki/Wikipedia:Help_desk— (search the English Wikipedia Help desk) -
en.wikipedia.org/wiki/Help:— (search the English Wikipedia's Help: namespace) -
en.wikipedia.org/wiki/Help_— (generates a search link that does not work: try it, evidently because no Wikipedia page URLs contain the string with a colon or a slash immediately after it)
-
- Your search term(s). (Optional.) If this parameter is empty, clicking on the resulting link generates a Google search form with an initially blank input field, ready to search on the site the first parameter specifies.
- Link text to display on your wiki page. (Optional.)
[edit] Examples
To-do: edit the examples to emphasize Appropedia rather than Wikipedia.
| Type this | To get this | What it produces, or searches for |
|---|---|---|
| {{google custom|en.wikipedia.org||Search Wikipedia}} | Search Wikipedia | Blank form to search Wikipedia |
| {{google custom|en.wikipedia.org|google|Search Wikipedia for "google"}} | Search Wikipedia for "google" | Search Wikipedia for "google" |
| {{google custom|en.wikipedia.org/wiki/Wikipedia:||Search Wikipedia's Wikipedia: namespace}} | Search Wikipedia's Wikipedia: namespace | Blank form to search the Wikipedia: namespace |
| {{google custom|en.wikipedia.org/wiki/Wikipedia:Help_desk||Search Wikipedia Help desk}} | Search Wikipedia Help desk | Blank form to search the Wikipedia Help desk |
| {{google custom|en.wikipedia.org/wiki/Wikipedia:Wikipedia_Signpost||Search Wikipedia Signpost}} | Search Wikipedia Signpost | Blank form to search the Wikipedia Signpost |
| {{google custom|en.wikipedia.org/wiki/Category:||Search Wikipedia's Category namespace}} | Search Wikipedia's Category namespace | Blank form to search Wikipedia's Category: namespace |
| {{google custom|en.wikipedia.org/wiki/Help:||Search Wikipedia's Help: namespace}} | Search Wikipedia's Help namespace | Blank form to search Wikipedia's Help: namespace |
| {{google custom|en.wikipedia.org/wiki/Template:|google|Search Wikipedia's Template: namespace for "google"}} | Search Wikipedia's Template: namespace for "google" | Search Wikipedia's Template: namespace for "google" |
| {{google custom|meta.wikimedia.org||Search Meta-Wiki with Google}} | Search Meta-Wiki with Google | Blank form to search Meta-Wiki |
| {{google custom|www.mediawiki.org||Search MediaWiki.org with Google}} | Search MediaWiki.org with Google | Blank form to search MediaWiki.org |
| {{google custom|www.appropedia.org||Search Appropedia}} | Search Appropedia | Blank form to search Appropedia |
For more usage notes and examples, see the template documentation on Wikipedia.
[edit] See also
- {{Appropedia searches}}
- {{Google}}
- {{Google Appropedia}}
- {{Google Wikipedia}}
[edit] External links
| This page or section includes content from Wikipedia. The original article was at Template:Google custom. The list of authors can be seen in the history for that page. As with Appropedia, the text of Wikipedia is available under the CC-BY-SA. |
- wikipedia:Template:Google
- wikipedia:Template:Google images
- wikipedia:Template:Google translation
- meta:Help:ParserFunctions#.23if: - information about
#if: - meta:Help:Parser function#URLENCODE
- wikipedia:WP:EIW#Template - links to many documents about templates, from the Editor's index to Wikipedia
