summaryrefslogtreecommitdiff
path: root/extensions/ImageMap/ImageMap.php
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/ImageMap/ImageMap.php')
-rw-r--r--extensions/ImageMap/ImageMap.php23
1 files changed, 23 insertions, 0 deletions
diff --git a/extensions/ImageMap/ImageMap.php b/extensions/ImageMap/ImageMap.php
new file mode 100644
index 00000000..aa4cfa0d
--- /dev/null
+++ b/extensions/ImageMap/ImageMap.php
@@ -0,0 +1,23 @@
+<?php
+
+$dir = __DIR__ . '/';
+$wgExtensionMessagesFiles['ImageMap'] = $dir . 'ImageMap.i18n.php';
+$wgAutoloadClasses['ImageMap'] = $dir . 'ImageMap_body.php';
+$wgHooks['ParserFirstCallInit'][] = 'wfSetupImageMap';
+
+$wgExtensionCredits['parserhook']['ImageMap'] = array(
+ 'path' => __FILE__,
+ 'name' => 'ImageMap',
+ 'author' => 'Tim Starling',
+ 'url' => 'https://www.mediawiki.org/wiki/Extension:ImageMap',
+ 'descriptionmsg' => 'imagemap_desc',
+);
+
+/**
+ * @param $parser Parser
+ * @return bool
+ */
+function wfSetupImageMap( &$parser ) {
+ $parser->setHook( 'imagemap', array( 'ImageMap', 'render' ) );
+ return true;
+}