Template:LinkEppstein: Difference between revisions

From LifeWiki
Jump to navigation Jump to search
Support linking to arbitary pages on David Eppstein's site, using page= ; also document and provide an example.
mNo edit summary
Line 7: Line 7:
To link to a different page on David Eppstein's Glider Database instead, one not describing a specific spaceship, the following parameters can be used:
To link to a different page on David Eppstein's Glider Database instead, one not describing a specific spaceship, the following parameters can be used:


* ''page'' (mandatory), which specifies the path and filename (including the <tt>.html</tt>) suffix of the page being linked to, relative to <tt>http://fano.ics.uci.edu/ca/</tt> ;
* ''page'' (mandatory), which specifies the path and filename (including the <tt>.html</tt> suffix) of the page being linked to, relative to <tt>http://fano.ics.uci.edu/ca/</tt> ;
* ''name'' (or ''patternname''; optional), which specifies the name of the page as it will appear in the link text (default: same as ''page'');
* ''name'' (or ''patternname''; optional), which specifies the name of the page as it will appear in the link text (default: same as ''page'');
* ''style'' (optional), which specifies how to format the link (style=listitem or style=raw; default: listitem)
* ''style'' (optional), which specifies how to format the link (style=listitem or style=raw; default: listitem)

Revision as of 16:54, 23 August 2017

This is a template for including links to David Eppstein's Glider Database in the "External Links" section of an article. It can take three parameters:

  • number (mandatory), which specifies the number of the glider (i.e. spaceship) that will be linked to on the Glider Database;
  • name (or patternname; optional), which specifies the name of the pattern as it will appear in the link text (default: "Glider" followed by the number provided);
  • style (optional), which specifies how to format the link (style=listitem or style=raw; default: listitem)

To link to a different page on David Eppstein's Glider Database instead, one not describing a specific spaceship, the following parameters can be used:

  • page (mandatory), which specifies the path and filename (including the .html suffix) of the page being linked to, relative to http://fano.ics.uci.edu/ca/ ;
  • name (or patternname; optional), which specifies the name of the page as it will appear in the link text (default: same as page);
  • style (optional), which specifies how to format the link (style=listitem or style=raw; default: listitem)

Here are some simple examples of its usage:

You type:

{{LinkEppstein|number=115|patternname=The Glider (glider 115)}}

You see:

You type:

{{LinkEppstein|page=gliders/knightships.html|name=The off-slope gliders}}

You see:

See also