Template:Breadcrumbs: Difference between revisions

Template page
No edit summary
(Automate breadcrumbs instead of using parameters)
Line 1: Line 1:
<templatestyles src="Breadcrumbs/styles.css" /><div class="breadcrumbs">[[Turing Complete Wiki|Turing Complete Wiki]] &gt;
<templatestyles src="Breadcrumbs/styles.css" /><div class="breadcrumbs">[[Turing Complete Wiki|Turing Complete Wiki]] &gt;
{{#if:{{{2|}}}
{{#ifeq: {{#titleparts:TCWIKI/{{FULLPAGENAME}}|1|-2}} | TCWIKI
|  {{#if:{{{1|}}}
|  {{SUBPAGENAME}}
     |   [[{{{1|}}}|{{{1|}}}]] &gt;
|  {{#ifeq: {{#titleparts:TCWIKI/{{FULLPAGENAME}}|1|-3}} | TCWIKI
     |   ... &gt;
     |   [[{{#titleparts:{{FULLPAGENAME}}|-1}}|{{#titleparts:{{FULLPAGENAME}}|1|-2}}]] &gt;
    }} [[{{{2|}}}|{{{2|}}}]] &gt;
        {{SUBPAGENAME}}
|   {{#if:{{{1|}}}
     |   {{#ifeq: {{#titleparts:TCWIKI/{{FULLPAGENAME}}|1|-4}} | TCWIKI
    | [[{{{1|}}}|{{{1|}}}]] &gt;
        |    [[{{#titleparts:{{FULLPAGENAME}}|-2}}|{{#titleparts:{{FULLPAGENAME}}|1|-3}}]] &gt;
    | <b></b>
              [[{{#titleparts:{{FULLPAGENAME}}|-1}}|{{#titleparts:{{FULLPAGENAME}}|1|-2}}]] &gt;
              {{SUBPAGENAME}}
        |   ... &gt;
              [[{{#titleparts:{{FULLPAGENAME}}|-1}}|{{#titleparts:{{FULLPAGENAME}}|1|-2}}]] &gt;
              {{SUBPAGENAME}}
        }}
     }}
     }}
}} '''{{SUBPAGENAME}}'''</div>
}} </div>
<noinclude>{{Documentation}}</noinclude>
<noinclude>{{Documentation}}</noinclude>

Revision as of 09:05, 19 February 2025

This page has been transcluded from Template:Breadcrumbs/Documentation.


Display a breadcrumbs-style navigation bar. The top level (Turing Complete Wiki) and the current page are always shown. - If there is one intermediate page, it will be treated as the direct parent. - If there are two intermediate pages, the first will be treated as the grandparent and the second will be treated as the direct parent. - If there are more than two intermediate pages, ... will be used to indicate deep nesting, with the direct parent shown.

Usage

{{Breadcrumbs}}
{{Breadcrumbs|Page}}
{{Breadcrumbs|Parent/Page}}
{{Breadcrumbs|Grandparent/Parent/Page}}
{{Breadcrumbs|Greatgrandparent/Grandparent/Parent/Page}}
{{Breadcrumbs|Greatgreatgrandparent/Greatgrandparent/Grandparent/Parent/Page}}