Extension:AdvancedSkinSystem
![]() |
This extension stores its source code on a wiki page. Please be aware that this code may be unreviewed or maliciously altered. They may contain security holes, outdated interfaces that are no longer compatible etc. Note: No localisation updates are provided for this extension by translatewiki.net. |
AdvancedSkinSystem Release status: unmaintained |
|
---|---|
Implementation | Extended syntax, Skin, Special page |
Description | Implements a flexible skinning framework for your wiki |
Author(s) | Jamasi |
Latest version | 0.9.0 |
MediaWiki | 1.10, 1.11, 1.12, 1.13, 1.14, 1.15, 1.16 |
Database changes | No |
License | AGPL |
Download | Download |
Example | a skin, and its output |
Translate the AdvancedSkinSystem extension if it is available at translatewiki.net |
|
Check usage and version matrix; code metrics |
The AdvancedSkinSystem implements a flexible skinning framework for your wiki. It offers the following features:
- arbitrary number of skins
- skins can be changed on-the-fly depending on namespace or category of an article.
- skin templates are completely editable from the wiki-interface (if your user is equipped with sufficient rights).
- skins can incorporate dynamic wiki-content.
- skin templates can be modularised to share common parts.
- ... (to be continued)
![]() |
If not used properly malicious people could execute any php code on your server. Great power comes with great responsibility. |
Contents
Installing[edit | edit source]
Copy the files into a subfolder of the extensions folder of your MediaWiki installation. Then add the following lines to your LocalSettings.php file (near the top):
#define wgStylePath if not done yet $wgStylePath = "/mediawiki/skins"; #add if not done already require_once("$IP/extensions/ExtensionFunctions.php"); #add Advanced Skin System extension require_once("$IP/extensions/AdvancedSkinSystem/AdvancedSkinSystem.php");
You have to create a subdirectory advancedskin in /mediawiki/skins.
To compile the created skins you have to use Special:UptadeSkins .
TODO: document changes to access rights in skins-folder.
Dependency[edit | edit source]
Please install Extension:ExtensionFunctions.php into $IP/extensions first.
Configuration[edit | edit source]
tags[edit | edit source]
There are 7 tags that can be used.
- <external>
- <internal>
- <dynamic>
- <skintemplate>
- <skinfiller>
- <wikibits>
- <skinflags>
external[edit | edit source]
example
<external> #!Favicon.ico!#==[[Media:Favicon.ico]] #!Style.css!#==[[Filler:WebStyle.css]] </external>
The content of these articles will be stored into the skins/advancedskins folder. so WebStyle.css will be created in skins/advancedskins
internal[edit | edit source]
example
<internal> ##HEADER##==[[Filler:MySkinHeader]] </internal>
The content of these articles will be included during the skin compilation.
dynamic[edit | edit source]
example
<dynamic> #*FOOTER*#==[[MySkinFooter]] </dynamic>
The content of these articles will be included on runtime.
skintemplate[edit | edit source]
example
<skintemplate> ##HEADER## <body> /*have a look at MonoBook or the linked example for some ideas of what to put here*/ </body> <?php /*you can use php-code too*/ ?> </skintemplate>
The content of this tag is used for the main part of the skin you create.
skinfiller[edit | edit source]
example
<skinfiller> <div id="menu-oben"></div> </skinfiller>
The content of this tag is used within the skin you create. Using it you can modularize your code.
wikibits[edit | edit source]
example
<wikibits> '''a bold text using wiki-syntax''' </wikibits>
The content of this tag is used to include texts using the wiki syntax.
skinflags[edit | edit source]
example
<skinflags> Present_To_User </skinflags>
Using the Present_To_User flag makes the skin available for your users in the general settings. Skins that do not use Present_To_User can only be used when a skin that uses Present_To_User is active. The syntax to be used in this case is category:Skin:MySkin, whereas MySkin is the name of your skin which doesn't use the Present_To_User flag.
mapping a namespace to use an ASS-skin as default[edit | edit source]
You can create the page MediaWiki:ASSNamespace2Skin
and put something like this into it:
NamespaceName1=Skinname1 NamespaceName2=Skinname2
Namespace1 will then default to skin1 and namespace2 will default to skin2. You can override this for single pages using the category feature, i.e. [[Category:Skin:Skinname1]]
TODO[edit | edit source]
- implement log message on skin regeneration
- simplify installation
- document