Template:MainMenu
Line 65: | Line 65: | ||
* [[MYSQL_Guide|MySQL Guide]]| | * [[MYSQL_Guide|MySQL Guide]]| | ||
<!-- BEGIN OTHER LOCALE MENU --> | <!-- BEGIN OTHER LOCALE MENU --> | ||
− | + | * {{#ifexist: Roster/{{SUBPAGENAME}}|[[Roster/{{SUBPAGENAME}}|Roster]]|[[Roster|Roster]]}} | |
− | * {{#ifexist: Roster|[[Roster/{{SUBPAGENAME}}|Roster]]|[[Roster|Roster]]}} | + | |
{{#ifeq:{{{1}}}|Roster| | {{#ifeq:{{{1}}}|Roster| | ||
− | ** {{#ifexist: Roster:Requirements|[[Roster:Requirements/{{SUBPAGENAME}}|Requirements]]|[[Roster:Requirements|Requirements]]}} | + | ** {{#ifexist: Roster:Requirements/{{SUBPAGENAME}}|[[Roster:Requirements/{{SUBPAGENAME}}|Requirements]]|[[Roster:Requirements|Requirements]]}} |
− | ** {{#ifexist: Roster:ChangeLog|[[Roster:ChangeLog/{{SUBPAGENAME}}|Change Log]]|[[Roster:ChangeLog|Change Log]]}} | + | ** {{#ifexist: Roster:ChangeLog/{{SUBPAGENAME}}|[[Roster:ChangeLog/{{SUBPAGENAME}}|Change Log]]|[[Roster:ChangeLog|Change Log]]}} |
− | ** {{#ifexist: Roster:Install|[[Roster:Install/{{SUBPAGENAME}}|Installing Roster]]|[[Roster:Install|Installing Roster]]}} | + | ** {{#ifexist: Roster:Install/{{SUBPAGENAME}}|[[Roster:Install/{{SUBPAGENAME}}|Installing Roster]]|[[Roster:Install|Installing Roster]]}} |
− | ** {{#ifexist: Roster:FirstUpload|[[Roster:FirstUpload/{{SUBPAGENAME}}|First Upload]]|[[Roster:FirstUpload|First Upload]]}} | + | ** {{#ifexist: Roster:FirstUpload/{{SUBPAGENAME}}|[[Roster:FirstUpload/{{SUBPAGENAME}}|First Upload]]|[[Roster:FirstUpload|First Upload]]}} |
− | ** {{#ifexist: Roster:CP|[[Roster:CP/{{SUBPAGENAME}}|Control Panel]]|[[Roster:CP|Control Panel]]}} | + | ** {{#ifexist: Roster:CP/{{SUBPAGENAME}}|[[Roster:CP/{{SUBPAGENAME}}|Control Panel]]|[[Roster:CP|Control Panel]]}} |
− | ** {{#ifexist: Roster:RosterDiag|[[Roster:RosterDiag/{{SUBPAGENAME}}|Roster Diagnosics]]|[[Roster:RosterDiag|Roster Diagnosics]]}} | + | ** {{#ifexist: Roster:RosterDiag/{{SUBPAGENAME}}|[[Roster:RosterDiag/{{SUBPAGENAME}}|Roster Diagnosics]]|[[Roster:RosterDiag|Roster Diagnosics]]}} |
− | ** {{#ifexist: Roster:Menu|[[Roster:Menu/{{SUBPAGENAME}}|Roster Main Menu]]|[[Roster:Menu|Roster Main Menu]]}} | + | ** {{#ifexist: Roster:Menu/{{SUBPAGENAME}}|[[Roster:Menu/{{SUBPAGENAME}}|Roster Main Menu]]|[[Roster:Menu|Roster Main Menu]]}} |
− | ** {{#ifexist: Roster:Updating|[[Roster:Updating/{{SUBPAGENAME}}|Updating Character and Guild Data to Roster]]|[[Roster:Updating|Updating Character and Guild Data to Roster]]}} | + | ** {{#ifexist: Roster:Updating/{{SUBPAGENAME}}|[[Roster:Updating/{{SUBPAGENAME}}|Updating Character and Guild Data to Roster]]|[[Roster:Updating|Updating Character and Guild Data to Roster]]}} |
− | ** {{#ifexist: Roster:Addon|[[Roster:Addon/{{SUBPAGENAME}}|Roster Addons]]|[[Roster:Addon|Roster Addons]]}} ([[AddonSDK|AddOn SDK]]) | + | ** {{#ifexist: Roster:Addon/{{SUBPAGENAME}}|[[Roster:Addon/{{SUBPAGENAME}}|Roster Addons]]|[[Roster:Addon|Roster Addons]]}} ([[AddonSDK|AddOn SDK]]) |
− | ** {{#ifexist: Roster:FunctionsOverview|[[Roster:FunctionsOverview/{{SUBPAGENAME}}|Functions Overview]]|[[Roster:FunctionsOverview|Functions Overview]]}} | + | ** {{#ifexist: Roster:FunctionsOverview/{{SUBPAGENAME}}|[[Roster:FunctionsOverview/{{SUBPAGENAME}}|Functions Overview]]|[[Roster:FunctionsOverview|Functions Overview]]}} |
− | ** {{#ifexist: Roster:Port|[[Roster:Port/{{SUBPAGENAME}}|Roster CMS Integration]]|[[Roster:Port|Roster CMS Integration]]}} | + | ** {{#ifexist: Roster:Port/{{SUBPAGENAME}}|[[Roster:Port/{{SUBPAGENAME}}|Roster CMS Integration]]|[[Roster:Port|Roster CMS Integration]]}} |
{{#ifeq: {{{2}}}|Port| | {{#ifeq: {{{2}}}|Port| | ||
− | *** {{#ifexist: Roster:Port:WoWRosterDF|[[Roster:Port:WoWRosterDF/{{SUBPAGENAME}}|WoWRosterDF]]|[[Roster:Port:WoWRosterDF|WoWRosterDF]]}} | + | *** {{#ifexist: Roster:Port:WoWRosterDF/{{SUBPAGENAME}}|[[Roster:Port:WoWRosterDF/{{SUBPAGENAME}}|WoWRosterDF]]|[[Roster:Port:WoWRosterDF|WoWRosterDF]]}} |
|}} | |}} | ||
|}} | |}} | ||
− | * {{#ifexist: UniUploader|[[UniUploader/{{SUBPAGENAME}}|UniUploader]]|[[UniUploader|UniUploader]]}} | + | * {{#ifexist: UniUploader/{{SUBPAGENAME}}|[[UniUploader/{{SUBPAGENAME}}|UniUploader]]|[[UniUploader|UniUploader]]}} |
{{#ifeq:{{{1}}}|UniUploader| | {{#ifeq:{{{1}}}|UniUploader| | ||
− | ** {{#ifexist: UniUploader:BasicSetup|[[UniUploader:BasicSetup/{{SUBPAGENAME}}|Basic Setup]]|[[UniUploader:BasicSetup|Basic Setup]]}} | + | ** {{#ifexist: UniUploader:BasicSetup/{{SUBPAGENAME}}|[[UniUploader:BasicSetup/{{SUBPAGENAME}}|Basic Setup]]|[[UniUploader:BasicSetup|Basic Setup]]}} |
− | ** {{#ifexist: UniUploader:Advanced|[[UniUploader:Advanced/{{SUBPAGENAME}}|Advanced Techniques]]|[[UniUploader:Advanced|Advanced Techniques]]}} | + | ** {{#ifexist: UniUploader:Advanced/{{SUBPAGENAME}}|[[UniUploader:Advanced/{{SUBPAGENAME}}|Advanced Techniques]]|[[UniUploader:Advanced|Advanced Techniques]]}} |
− | ** {{#ifexist: UniUploader:PluginFramework|[[UniUploader:PluginFramework/{{SUBPAGENAME}}|Plugin Framework]]|[[UniUploader:PluginFramework|Plugin Framework]]}} | + | ** {{#ifexist: UniUploader:PluginFramework/{{SUBPAGENAME}}|[[UniUploader:PluginFramework/{{SUBPAGENAME}}|Plugin Framework]]|[[UniUploader:PluginFramework|Plugin Framework]]}} |
− | *** {{#ifexist: UniUploader:PluginFramework:Tutorial|[[UniUploader:PluginFramework:Tutorial/{{SUBPAGENAME}}|Plugin Tutorial]]|[[UniUploader:PluginFramework:Tutorial|Plugin Tutorial]]}} | + | *** {{#ifexist: UniUploader:PluginFramework:Tutorial/{{SUBPAGENAME}}|[[UniUploader:PluginFramework:Tutorial/{{SUBPAGENAME}}|Plugin Tutorial]]|[[UniUploader:PluginFramework:Tutorial|Plugin Tutorial]]}} |
− | ** {{#ifexist: UniUploader:Distribution|[[UniUploader:Distribution/{{SUBPAGENAME}}|Distribution]]|[[UniUploader:Distribution|Distribution]]}} | + | ** {{#ifexist: UniUploader:Distribution/{{SUBPAGENAME}}|[[UniUploader:Distribution/{{SUBPAGENAME}}|Distribution]]|[[UniUploader:Distribution|Distribution]]}} |
|}} | |}} | ||
− | * {{#ifexist: JUniUploader|[[JUniUploader/{{SUBPAGENAME}}|java UniUploader]]|[[JUniUploader|java UniUploader]]}} | + | * {{#ifexist: JUniUploader/{{SUBPAGENAME}}|[[JUniUploader/{{SUBPAGENAME}}|java UniUploader]]|[[JUniUploader|java UniUploader]]}} |
{{#ifeq:{{{1}}}|jUniUploader| | {{#ifeq:{{{1}}}|jUniUploader| | ||
− | ** {{#ifexist: JUniUploader:BasicSetup|[[JUniUploader:BasicSetup/{{SUBPAGENAME}}|Basic Setup]]|[[JUniUploader:BasicSetup|Basic Setup]]}} | + | ** {{#ifexist: JUniUploader:BasicSetup/{{SUBPAGENAME}}|[[JUniUploader:BasicSetup/{{SUBPAGENAME}}|Basic Setup]]|[[JUniUploader:BasicSetup|Basic Setup]]}} |
|}} | |}} | ||
− | * {{#ifexist: phpUniUploader|[[phpUniUploader/{{SUBPAGENAME}}|PHP UniUploader]]|[[phpUniUploader|PHP UniUploader]]}} | + | * {{#ifexist: phpUniUploader/{{SUBPAGENAME}}|[[phpUniUploader/{{SUBPAGENAME}}|PHP UniUploader]]|[[phpUniUploader|PHP UniUploader]]}} |
{{#ifeq: {{{1}}}|phpUniUploader | {{#ifeq: {{{1}}}|phpUniUploader | ||
||}} | ||}} | ||
− | * {{#ifexist: UniAdmin|[[UniAdmin/{{SUBPAGENAME}}|UniAdmin]]|[[UniAdmin|UniAdmin]]}} | + | * {{#ifexist: UniAdmin/{{SUBPAGENAME}}|[[UniAdmin/{{SUBPAGENAME}}|UniAdmin]]|[[UniAdmin|UniAdmin]]}} |
{{#ifeq:{{{1}}}|UniAdmin| | {{#ifeq:{{{1}}}|UniAdmin| | ||
− | ** {{#ifexist: UniAdmin:Help|[[UniAdmin:Help/{{SUBPAGENAME}}|Help]]|[[UniAdmin:Help|Help]]}} | + | ** {{#ifexist: UniAdmin:Help/{{SUBPAGENAME}}|[[UniAdmin:Help/{{SUBPAGENAME}}|Help]]|[[UniAdmin:Help|Help]]}} |
|}} | |}} | ||
− | * {{#ifexist: WoWAddon|[[WoWAddon/{{SUBPAGENAME}}|WoWAddons]]|[[WoWAddon|WoWAddons]]}} | + | * {{#ifexist: WoWAddon/{{SUBPAGENAME}}|[[WoWAddon/{{SUBPAGENAME}}|WoWAddons]]|[[WoWAddon|WoWAddons]]}} |
{{#ifeq:{{{1}}}|WoWAddon| | {{#ifeq:{{{1}}}|WoWAddon| | ||
− | ** {{#ifexist: CharacterProfiler|[[CharacterProfiler/{{SUBPAGENAME}}|CharacterProfiler]]|[[CharacterProfiler|CharacterProfiler]]}} | + | ** {{#ifexist: CharacterProfiler/{{SUBPAGENAME}}|[[CharacterProfiler/{{SUBPAGENAME}}|CharacterProfiler]]|[[CharacterProfiler|CharacterProfiler]]}} |
− | ** {{#ifexist: GuildProfiler|[[GuildProfiler/{{SUBPAGENAME}}|GuildProfiler]]|[[GuildProfiler|GuildProfiler]]}} | + | ** {{#ifexist: GuildProfiler/{{SUBPAGENAME}}|[[GuildProfiler/{{SUBPAGENAME}}|GuildProfiler]]|[[GuildProfiler|GuildProfiler]]}} |
− | ** {{#ifexist: PvPLog|[[PvPLog/{{SUBPAGENAME}}|PvPLog]]|[[PvPLog|PvPLog]]}} | + | ** {{#ifexist: PvPLog/{{SUBPAGENAME}}|[[PvPLog/{{SUBPAGENAME}}|PvPLog]]|[[PvPLog|PvPLog]]}} |
{{#ifeq: {{{2}}}|PvPLog| | {{#ifeq: {{{2}}}|PvPLog| | ||
− | *** {{#ifexist: PvPLog:Changes|[[PvPLog:Changes/{{SUBPAGENAME}}|Change Log]]|[[PvPLog:Changes|Change Log]]}} | + | *** {{#ifexist: PvPLog:Changes/{{SUBPAGENAME}}|[[PvPLog:Changes/{{SUBPAGENAME}}|Change Log]]|[[PvPLog:Changes|Change Log]]}} |
− | *** {{#ifexist: PvPLog:TODO|[[PvPLog:TODO/{{SUBPAGENAME}}|TODO]]|[[PvPLog:TODO|TODO]]}} | + | *** {{#ifexist: PvPLog:TODO/{{SUBPAGENAME}}|[[PvPLog:TODO/{{SUBPAGENAME}}|TODO]]|[[PvPLog:TODO|TODO]]}} |
|}} | |}} | ||
|}} | |}} | ||
Line 115: | Line 114: | ||
* [[CodingStandards|Coding Standards]] | * [[CodingStandards|Coding Standards]] | ||
* [[Special:Categories|Categories]] | * [[Special:Categories|Categories]] | ||
− | * {{#ifexist: MYSQL_Guide|[[MYSQL_Guide/{{SUBPAGENAME}}|MySQL Guide]]|[[MYSQL_Guide|MySQL Guide]]}} | + | * {{#ifexist: MYSQL_Guide/{{SUBPAGENAME}}|[[MYSQL_Guide/{{SUBPAGENAME}}|MySQL Guide]]|[[MYSQL_Guide|MySQL Guide]]}} |
}} | }} | ||
Revision as of 06:07, 10 February 2008
Important note: When you edit this page, you agree to release your contribution into the public domain. |
Template
Syntax
This is the Main Menu for our wiki
It uses a template parameter and conditionals to display sub menus
The Roster menu is called like so
{{MainMenu|Roster}}
MainMenu is the name of this template
Roster is the first parameter
{{#ifeq:{{{1}}}|Roster| ** [[SomePage|SomePage]] |}}
This is a conditional that determines if we are printing a sub menu
{{#ifeq:{{{1}}}|Roster|
This means if the first template parameter equals Roster, then display the sub menu
|}}
This closes the conditional
If we want a sub menu in a sub menu, then we use more parameters when calling the template
{{MainMenu|Roster|Addons}}
MainMenu is the name of this template
Roster is the first parameter
Addons is the second parameter
{{#ifeq:{{{1}}}|Roster| ** [[SomePage|SomePage]] {{#ifeq:{{{2}}}|Addons| *** [[AnotherPage|AnotherPage]] |}} |}}
The Other Locale Duplicate
To make the menu keep linking to the same language, we copy the menu once and add "/{{SUBPAGENAME}}" to the link
This will make the menu link to the pages in the menu, keeping the same locale
If the page does not exist for that locale, then it should link to the English version
The syntax for this is quite complex as we detect if the translated page exists
Each link needs to look like this:
{{#ifexist: PageName/{{SUBPAGENAME}}|[[PageName/{{SUBPAGENAME}}|Page Name Text]]|[[PageName|Page Name Text]]}}
Some links need to stay linked to the English version, such as the Coding Standards, The Team, and the AddOn SDK
These page may be changed on every release version of our software or even between versions