Main Restorations Software Audio/Jukebox/MP3 Everything Else Buy/Sell/Trade
Project Announcements Monitor/Video GroovyMAME Merit/JVL Touchscreen Meet Up Retail Vendors
Driving & Racing Woodworking Software Support Forums Consoles Project Arcade Reviews
Automated Projects Artwork Frontend Support Forums Pinball Forum Discussion Old Boards
Raspberry Pi & Dev Board controls.dat Linux Miscellaneous Arcade Wiki Discussion Old Archives
Lightguns Arcade1Up --- Bug Reports --- Site News

Unread posts | New Replies | Recent posts | Rules | Chatroom | Wiki | File Repository | RSS | Submit news

  

Author Topic: Templates  (Read 3656 times)

0 Members and 1 Guest are viewing this topic.

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Templates
« on: March 02, 2006, 08:57:09 am »
Thought this might be a useful note

While enhancing my wikifu, I came across this.

Creating, editing and using templates

You start a new template in the same way you would start a normal page. The only difference is that its title must start with Template:

(eg. Template:templatename)

Once you have made the template, you can add {{templatename}} to the pages you want to use it on. Every page using this template will get the same boilerplate text, each time a user visits it. When the template is updated, all pages containing the template tag will automatically be updated.
Alternatively, you can add {{subst:templatename}} to the pages you want to use the boilerplate text on. The system will fetch a one-time copy of the template text and substitute it into the page, in place of the template tag. If anyone edits the template afterwards, pages that used the subst: keyword will not be updated. Sometimes that's what you want.

If the template you want to edit looks like {{foo}}, you would go to Template:foo to edit it. To get there, type in the URL to your address bar, search for it, or make a link in the sandbox and click on it.
Once you are there, just click "edit" or "edit this page" and edit it in the same way you would any other page. You can add anything you would add to a normal page, including text, images and other templates. Please be aware that your edit might affect many pages, so be cautious.

Also use
{{Cleanup}} To insert standard "clean this up" boilerplate text.
Formerly known for the (apparently now defunct) arcadeartlibrary

JoyMonkey

  • Voodoo Wiki Master . . .
  • Wiki Master
  • Trade Count: (+5)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2899
  • Last login:July 11, 2019, 08:04:24 am
  • Candy is Dandy but Liquor is Quicker
    • JoyMonkey.com
Re: Templates
« Reply #1 on: March 02, 2006, 09:49:50 am »
I'm still not sure of what these templates are used for.
Could it be used to modify a pages overall flow, so the table of contents could be shown on the right instead of left, or running alongside the main body of text?

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Re: Templates
« Reply #2 on: March 02, 2006, 10:05:16 am »
Basically just adding an initial set of text to a page. And any time that template text is updated, it updates the templated page. Limited functionality, but it can be useful. The subst:templatename might be more helpful because it would allow you to create a standard starting point for various types of pages. Like if someone were to make some sort of obnoxious processor / motherboard / mame comparison at some point and you wanted to have a standard set of information presented, like

Processor:
Ram Amount:
Motherboard:
Video Card: 
etc.. and have that information be presented consistently. The subst:templatename would come in handy because with that use, the data on the page doesn't get updated, the template just gets used the one time and then becomes an editable part of the page.
Formerly known for the (apparently now defunct) arcadeartlibrary

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Re: Templates
« Reply #3 on: March 02, 2006, 10:08:38 am »
Oh, and the templates can also add an automatic link to the proper category page. You could just as easily add the category:categoryname to the bottom of the page every time, but updating a category on a template would edit the category for all of those templated pages as well in one go. 
Formerly known for the (apparently now defunct) arcadeartlibrary

sirwoogie

  • Supreme Chancellor
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 753
  • Last login:January 12, 2019, 11:28:27 am
  • It's Hollyfeld in a Winnebago!
    • Build Your Own Arcade Controls
Re: Templates
« Reply #4 on: March 02, 2006, 10:18:43 am »
I created the Template:Cleanup a few days ago. I haven't added anymore. Like the pages, I'm open for anybody to put templates up there as they see fit. I'll eventually have a bot reap anything that isn't used.

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Re: Templates
« Reply #5 on: March 02, 2006, 02:54:46 pm »
good use for templates example;

http://wiki.arcadecontrols.com/wiki/FCE_Ultra_161_Ini_File

Created a template for use with creating Mamewah ini files. this type of tempalate could be very useful to display info from other programs that use preformatted files like this.
Formerly known for the (apparently now defunct) arcadeartlibrary

JoyMonkey

  • Voodoo Wiki Master . . .
  • Wiki Master
  • Trade Count: (+5)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2899
  • Last login:July 11, 2019, 08:04:24 am
  • Candy is Dandy but Liquor is Quicker
    • JoyMonkey.com
Re: Templates
« Reply #6 on: March 02, 2006, 03:07:10 pm »
I think I get it now. The page starts out with bare details and then you just fill in the blanks as necessary. Cool.

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Re: Templates
« Reply #7 on: March 02, 2006, 03:11:18 pm »
If it's a true template it adds standard text or images to the top, and proper category to the bottom if necessary. 

If you subst:templatename, then yeah... fill in the blanks.
Formerly known for the (apparently now defunct) arcadeartlibrary

sirwoogie

  • Supreme Chancellor
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 753
  • Last login:January 12, 2019, 11:28:27 am
  • It's Hollyfeld in a Winnebago!
    • Build Your Own Arcade Controls
Re: Templates
« Reply #8 on: March 02, 2006, 04:57:15 pm »
I've created a Delete template (Template:Delete). Please use this to mark pages for deletion instead of renaming them.

SirPoonga

  • Puck'em Up
  • Global Moderator
  • Trade Count: (+1)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 8176
  • Last login:September 05, 2017, 09:45:52 am
  • The Bears Still Suck!
Re: Templates
« Reply #9 on: March 02, 2006, 05:19:31 pm »
I read the wiki help, I still don't get how to use these.
The examples weren't really examples.  They were examples of the finished product.

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Re: Templates
« Reply #10 on: March 02, 2006, 05:30:42 pm »
the short verision... to use one type {{Template:templatename}} It will put an include of the stuff from the templated page onto your page, but you can't edit the template stuff.

To USE the templated stuff, rather than embed an include version of it use {{subst:templatename}}

To CREATE a template pic any random page and type [[Template:templatename]] save page click on link to go to the template (and then edit it).

Probably should have a sandbox somewhere to do junk like that.
Formerly known for the (apparently now defunct) arcadeartlibrary

SirPoonga

  • Puck'em Up
  • Global Moderator
  • Trade Count: (+1)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 8176
  • Last login:September 05, 2017, 09:45:52 am
  • The Bears Still Suck!
Re: Templates
« Reply #11 on: March 02, 2006, 05:46:41 pm »
Is there a list of templates?

mahuti

  • Wiki Master
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2507
  • Last login:May 24, 2018, 09:13:00 am
  • Back from the dead.
Re: Templates
« Reply #12 on: March 02, 2006, 06:07:43 pm »
I don't know where a list is...
but I know of

Template:Cleanup
Template:Delete
Template:Mamewah161

{{Cleanup}} for instance.
Formerly known for the (apparently now defunct) arcadeartlibrary

sirwoogie

  • Supreme Chancellor
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 753
  • Last login:January 12, 2019, 11:28:27 am
  • It's Hollyfeld in a Winnebago!
    • Build Your Own Arcade Controls
Re: Templates
« Reply #13 on: March 02, 2006, 08:20:49 pm »
You can search for any type of namespace page (e.g. Template) at http://wiki.arcadecontrols.com/wiki/Special:Allpages

Templates specifically are here.

JoyMonkey

  • Voodoo Wiki Master . . .
  • Wiki Master
  • Trade Count: (+5)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2899
  • Last login:July 11, 2019, 08:04:24 am
  • Candy is Dandy but Liquor is Quicker
    • JoyMonkey.com
Re: Templates
« Reply #14 on: March 02, 2006, 08:31:28 pm »
I've a question about the Delete template (you might have noticed that I've been consolidating pages and deleting obsoletes).
How do I enter the 'Reason Given' ?

I tried putting a reason inside {{{these brackets}}} , but it didn't seem to work (the page still read Reason Given: {{{1}}}).

sirwoogie

  • Supreme Chancellor
  • Trade Count: (0)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 753
  • Last login:January 12, 2019, 11:28:27 am
  • It's Hollyfeld in a Winnebago!
    • Build Your Own Arcade Controls
Re: Templates
« Reply #15 on: March 02, 2006, 08:36:48 pm »
Call it by:

Code: [Select]
{{Templatename|parameter}}
Thus, for Delete, it would be:

Code: [Select]
{{Delete|This page sucks}}

Read this specifically: http://meta.wikimedia.org/wiki/Help:Templates#Parameters
« Last Edit: March 02, 2006, 08:39:22 pm by sirwoogie »

JoyMonkey

  • Voodoo Wiki Master . . .
  • Wiki Master
  • Trade Count: (+5)
  • Full Member
  • *****
  • Offline Offline
  • Posts: 2899
  • Last login:July 11, 2019, 08:04:24 am
  • Candy is Dandy but Liquor is Quicker
    • JoyMonkey.com
Re: Templates
« Reply #16 on: March 02, 2006, 08:56:27 pm »
Thanks!