Can I change the wiki? I want to add template for languages.

General discussion about LÖVE, Lua, game development, puns, and unicorns.
Post Reply
User avatar
MD
Prole
Posts: 10
Joined: Sat Oct 31, 2009 2:56 am
Location: Spain
Contact:

Can I change the wiki? I want to add template for languages.

Post by MD »

Hi.

I want to add template for other foreing languages (like spanish ;) ) same at the page in this wiki http://faq.tuxfamily.org/Welcome/Sp . You can see the blue box the wiki links of the same page in other languages. And other example of language template is http://www.mediawiki.org/wiki/Template:Languages (but this example is little more complicate).

And why? Because I want translate into spanish the content of wiki into spanish. And I don't want to modify the wiki without "permission".

Thanks ,bye.
User avatar
MD
Prole
Posts: 10
Joined: Sat Oct 31, 2009 2:56 am
Location: Spain
Contact:

Re: Can I change the wiki? I want to add template for languages.

Post by MD »

:o it don't run fine, http://love2d.org/wiki/index.php?title= ... :Languages because in only page in the only page translate http://love2d.org/wiki/index.php?title=Lua/ES The template take the BASEPAGENAME all page....in this case "Lua/ES" and it show in this template "Lua/ES/ES".
User avatar
MD
Prole
Posts: 10
Joined: Sat Oct 31, 2009 2:56 am
Location: Spain
Contact:

Re: Can I change the wiki? I want to add template for languages.

Post by MD »

I study in deep the documentation of mediawiki, http://www.mediawiki.org/wiki/BASEPAGENAME#Page_names . And the {{BASEPAGENAME}} return the string "a/b" for "a/b" or "a/b/c"....

Maybe I found the solution is with the extension ParserFunctions (http://www.mediawiki.org/wiki/Extension:ParserFunctions) because it has the "function" #titleparts (http://www.mediawiki.org/wiki/Help:Exte ... titleparts) that return a chunck of title for example (the example is the posibility solution)
"{{#titleparts: Talk:Foo/bar/baz/quok | 1 }} → Talk:Foo"

Well, I haven't no more ;) .
User avatar
MD
Prole
Posts: 10
Joined: Sat Oct 31, 2009 2:56 am
Location: Spain
Contact:

Re: Can I change the wiki? I want to add template for languages.

Post by MD »

I re-code the template languages:

Code: Select all

<onlyinclude>
{| cellpadding="0" cellspacing="0" style="color: white;background-color: #e658a0;border: 5px solid #f0a4c8;padding: 2px 5px;text-align: center;"
|''This page is available in: [[{{#titleparts: {{BASEPAGENAME}}| 1 }} |English]] - [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/ES|Español]] - [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/PT|Portugese]] -  [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/FR|Français]] - [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/DE|Deutsch]] - [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/IT|Italiano]]- [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/RU|Russian]]- [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/SV|Svenska]] - [[{{#titleparts: {{BASEPAGENAME}}| 1 }}/CZ|Czech]]''
|}
</onlyinclude>
And I test in my personal wiki (a small and alone wiki :ultrahappy: ) and the template run fine.

But the version of http://www.mediawiki.org/wiki/Extension:ParserFunctions has the Love Wiki is old. Maybe you must update the versión, because a wiki with international articles are more useful (for pleope that we are speak other languages).

Can you update the extension of the wiki? Thanks ;)
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 2 guests