Extension:ClientSide

From MediaWiki.org
Jump to: navigation, search

Other languages:
Deutsch • ‎English • ‎español • ‎日本語 • ‎polski • ‎sicilianu • ‎中文
MediaWiki extensions manualManual:Extensions
Crystal Clear action run.png
ClientSide

Release status:Extension status stable

ImplementationTemplate:Extension#type Parser extension
DescriptionTemplate:Extension#description Provides functions for generating code in client-side formats such as HTML, CSS and JavaScript
Author(s)Template:Extension#username Trevor Parscaltalk
Latest versionTemplate:Extension#version 0.1.1 (2009-02-14)
MediaWikiTemplate:Extension#mediawiki 1.16+
PHPTemplate:Extension#php 5.3+
Database changesTemplate:Extension#needs-updatephp No
LicenseTemplate:Extension#license GPLv2
Download

Translate the ClientSide extension if it is available at translatewiki.net

Check usage and version matrix.

The ClientSide extension provides functions for generating code in client-side formats such as HTML, CSS and JavaScript. Required by Extension:CommunityVoiceExtension:CommunityVoice.

Purpose[edit]

The concept of this code is to provide procedural constructs for generating code which will be sent to the client. This is an alternative to embedding these client side languages as string throughout the PHP. This approach is inline with the design of the XML class present in the MediaWiki core, however ClientSide takes the concept a step further with CSS and JavaScript generation while providing a somewhat more flexible function argument structure.

Installation[edit]

  • Download and place the file(s) in a directory called ClientSide in your extensions/ folder.
  • Add the following code at the bottom of your LocalSettings.php:
    require_once "$IP/extensions/ClientSide/ClientSide.php";
    
  • YesY Done - Navigate to Special:Version on your wiki to verify that the extension is successfully installed.