Template:Subject: Difference between revisions
Appearance
wikademia>Mike.lifeguard m Changed protection level for "Template:Subject": project-critical template [edit=sysop:move=sysop] |
wikademia>Swift Added bookcategory to override the default book category. Added Category:Catalogue templates |
||
| Line 1: | Line 1: | ||
<includeonly> | <includeonly> | ||
{{#ifeq:{{#switch:{{#titleparts:{{FULLPAGENAME}}|0}}|{{BOOKNAME}}|{{NAMESPACE}}:{{#titleparts:{{PAGENAME}}|0}} = yes|#default = no}}|yes| | {{#ifeq:{{#switch:{{#titleparts:{{FULLPAGENAME}}|0}}|{{BOOKNAME}}|{{NAMESPACE}}:{{#titleparts:{{PAGENAME}}|0}} = yes|#default = no}}|yes| | ||
{{#if:{{NAMESPACE}}||[[Category:{{BOOKNAME}}]]}} | {{#if:{{NAMESPACE}}||[[Category:{{{bookcatgory|{{BOOKNAME}}}}}]]}} | ||
{{#if:{{{1|}}}|[[Category:{{{1}}}|{{FULLCHAPTERNAME}}]]|[[Category:Uncategorized modules|{{FULLCHAPTERNAME}}]]}} | {{#if:{{{1|}}}|[[Category:{{{1}}}|{{FULLCHAPTERNAME}}]]|[[Category:Uncategorized modules|{{FULLCHAPTERNAME}}]]}} | ||
{{#if:{{{2|}}}|[[Category:{{{2}}}|{{FULLCHAPTERNAME}}]]}}{{#if:{{{3|}}}|[[Category:{{{3}}}|{{FULLCHAPTERNAME}}]]}} | {{#if:{{{2|}}}|[[Category:{{{2}}}|{{FULLCHAPTERNAME}}]]}}{{#if:{{{3|}}}|[[Category:{{{3}}}|{{FULLCHAPTERNAME}}]]}} | ||
| Line 10: | Line 10: | ||
</includeonly><noinclude> | </includeonly><noinclude> | ||
This template categorizes a book in up to 10 categories, plus the book category (this is automatic). | This template categorizes a book in up to 10 categories, plus the book category (this is automatic). The book category can be modified by setting the <code>bookcategory</code> variable | ||
;Example: {{tlx|{{PAGENAME}}|Math|Science|Computing|Programming|etc}} | ;Example: {{tlx|{{PAGENAME}}|Math|Science|Computing|Programming|etc}} | ||
[[Category:Catalogue templates]] | |||
</noinclude> | </noinclude> | ||
Revision as of 04:33, 20 March 2009
This template categorizes a book in up to 10 categories, plus the book category (this is automatic). The book category can be modified by setting the bookcategory variable
- Example
- {{Subject|Math|Science|Computing|Programming|...}}