aboutsummaryrefslogtreecommitdiff
path: root/mod
diff options
context:
space:
mode:
Diffstat (limited to 'mod')
-rw-r--r--mod/developers/languages/en.php14
-rw-r--r--mod/developers/manifest.xml20
-rw-r--r--mod/developers/start.php19
-rw-r--r--mod/developers/views/default/admin/developers/preview.php8
4 files changed, 61 insertions, 0 deletions
diff --git a/mod/developers/languages/en.php b/mod/developers/languages/en.php
new file mode 100644
index 000000000..644acfb5f
--- /dev/null
+++ b/mod/developers/languages/en.php
@@ -0,0 +1,14 @@
+<?php
+/**
+ * Elgg developer tools English language file.
+ *
+ */
+
+$english = array(
+ // menu
+ 'admin:developers' => 'Developers',
+ 'admin:developers:settings' => 'Settings',
+ 'admin:developers:preview' => 'CSS Preview',
+);
+
+add_translation('en', $english);
diff --git a/mod/developers/manifest.xml b/mod/developers/manifest.xml
new file mode 100644
index 000000000..ed5aadd62
--- /dev/null
+++ b/mod/developers/manifest.xml
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<plugin_manifest version="1.8">
+ <name>Elgg Developer Tools</name>
+ <author>Cash Costello</author>
+ <version>1.0</version>
+ <blurb>Developer tools</blurb>
+ <description>A set of tools for writing plugins and themes.</description>
+ <website>http://www.elgg.org/</website>
+ <copyright>(C) Cash Costello 2011</copyright>
+ <license>GNU Public License version 2</license>
+
+ <requires>
+ <type>elgg_version</type>
+ <version>2009030802</version>
+ </requires>
+
+ <category>Development</category>
+ <admin_interface>advanced</admin_interface>
+
+</plugin_manifest>
diff --git a/mod/developers/start.php b/mod/developers/start.php
new file mode 100644
index 000000000..ba84c3234
--- /dev/null
+++ b/mod/developers/start.php
@@ -0,0 +1,19 @@
+<?php
+/**
+ * Elgg developer tools
+ */
+
+elgg_register_event_handler('init', 'system', 'developers_init');
+
+function developers_init() {
+
+ elgg_register_event_handler('pagesetup', 'system', 'developers_setup_menu');
+}
+
+function developers_setup_menu() {
+ if (elgg_in_context('admin')) {
+ elgg_add_admin_menu_item('developers', elgg_echo('admin:developers'));
+ elgg_add_admin_menu_item('settings', elgg_echo('admin:developers:settings'), 'developers');
+ elgg_add_admin_menu_item('preview', elgg_echo('admin:developers:preview'), 'developers');
+ }
+} \ No newline at end of file
diff --git a/mod/developers/views/default/admin/developers/preview.php b/mod/developers/views/default/admin/developers/preview.php
new file mode 100644
index 000000000..a51c99bee
--- /dev/null
+++ b/mod/developers/views/default/admin/developers/preview.php
@@ -0,0 +1,8 @@
+<?php
+/**
+ * CSS Preview
+ */
+
+$url = elgg_get_site_url() . 'documentation/css/preview/index.php';
+?>
+<iframe style="width:100%; height:100%;" src="<?php echo $url; ?>" style="width: 100%;"></iframe> \ No newline at end of file