Manual:Botclasses.php
Botclasses.php is PHP file with several classes to provide access to MediaWiki API. It was originally made by Chris G in 2008 and updated by others up to 2018.
Site statistics
editUpdates by 24pm include some functions to get site statistics. You can use function wiki_statistics()
to get it and place wherever in the skin. For now you can show the number of:
- activeusers - active users
- admins - adminstrators
- articles - articles
- category - articles in category
- edits - edits
- images - uploaded files
- pages - pages
- users - users
Installation
edit- Download Botclasses.php and wikistat.php from GitHub.
- Place them in the root directory of the skin.
- Edit
wikistat.php
and assign correct values to the variables: $wikiAPI, $wikiUser and $wikiPass - Done
- Documentation in Russian is available.
Usage
edit1. Include wikistat.php
in skin code (for Vector skin it is VectorTemplate.php)
<?php require_once( "wikistat.php" ); ?>
2. Add HTML code with PHP function:
<p>Images uploaded to this site: <b><?php echo wiki_statistics('images'); ?> </b></p>
More info
edit- Manual:Chris G's botclasses - usage of botclasses.php
- Documentation in Russian on botclasses.php