Bücher online kostenlos Kostenlos Online Lesen
Working With MediaWiki

Working With MediaWiki

Titel: Working With MediaWiki Kostenlos Bücher Online Lesen
Autoren: Yaron Koren
Vom Netzwerk:
same display, with some of the subcategories “opened up” to show their own subcategories.
    Figure 11.1 Hierarchical display of subcategories, enabled by CategoryTree extension
    CategoryTree also lets you put, on any page, a similar collapsible, hierarchical list of categories, but this one also listing the pages that each category holds.
    The CategoryTree homepage is at:
https://www.mediawiki.org/wiki/Extension:CategoryTree

SocialProfile
    Social networking in the enterprise is big business, with lots of companies wanting to add replicas of Facebook and the like to their internal network. Social networking can in theory encompass a lot of different features: messaging, user profiles, user groups, blogging, microblogging/”status updates”, and so on. There are some that MediaWiki already has natively; talk pages are arguably one example.
    The SocialProfile extension adds a variety of additional social networking features, and it has a number of spinoff extensions that add even more. These extensions were all originally developed for ArmchairGM, a site that was purchased by Wikia in 2006, and the code for most of them was made public in 2011.
    The SocialProfile extension family is in somewhat of a messy state at the moment: not all of the extensions work well with the latest versions of MediaWiki, and the distribution of functionality across the various extensions seems somewhat haphazard — there are currently 21 extensions tied in with SocialProfile, many of which are very small and look like they could be merged in with others. Still, there is an effort in place to improve all of these extensions, and some wikis have found the SocialProfile functionality very useful.
    Here are the main features of the core SocialProfile extension:
User profile — a wizard lets users easily create a detailed user profile, including uploading an avatar image that is then used in discussions.
Public and private messaging — users can write both private messages to one another, and public messages on a shared “user board”.
Friending/”foeing” — users can publicly specify the other users that they know.
User status — users can set their current status, and users’ status history is preserved, allowing for Twitter-style microblogging.
Rewards system — you can assign points to different actions, like editing a page and friending someone, and then set ranks that users are publicly given when they reach a certain number of points.
    And here are some of the additional SocialProfile-based extensions:
BlogPage — lets users create (non-wiki-page) blog posts.
PollNY — lets users create polls.
QuizGame — lets users create quizzes.
VoteNY — lets users vote on articles.
SiteMetrics — shows administrators various metrics related to usage of SocialProfile tools.
    You can read more about SocialProfile, its current status, and all its related extensions here:
https://www.mediawiki.org/wiki/Extension:SocialProfile

12  Extended MediaWiki syntax
    There’s a variety of other syntax, available through extensions, that can be used for specific purposes: displaying specialized content, handling logic, and displaying page elements such as tabs and footnotes. We’ll get to some of it in this chapter.

ParserFunctions
    The single most indispensable MediaWiki extension, and likely the most popular, is the ParserFunctions extension. As you may be able to guess from its name, ParserFunctions defines a collection of parser functions (see here for an explanation of those). The functions it defines are useful in a variety of circumstances. Since 2010, ParserFunctions has included all the code for what used to be a separate extension, StringFunctions. The original ParserFunctions function are all programmatic in nature: there’s #if, the most important of them, which does conditional display, #expr, which evaluates mathematical expressions, and others along similar lines; the full listing is below. The functions that came from StringFunctions all do typical string-manipulation actions, like getting substrings, and replacing certain substrings with others.
    In practice, almost all of the usages of functions defined by ParserFunctions are in templates, because that’s the one case where you don’t know in advance what all the values passed in will be. That’s why most of the examples later on for ParserFunctions functions take place within the context of a template, with passed-in parameters.
    ParserFunctions comes bundled in

Weitere Kostenlose Bücher