aboutsummaryrefslogtreecommitdiff
path: root/documentation/examples/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'documentation/examples/plugins')
-rw-r--r--documentation/examples/plugins/README.txt3
-rw-r--r--documentation/examples/plugins/actions/.gitignore (renamed from documentation/examples/plugins/skeleton/start.php)0
-rw-r--r--documentation/examples/plugins/languages/en.php24
-rw-r--r--documentation/examples/plugins/manifest.xml (renamed from documentation/examples/plugins/skeleton/manifest.xml)0
-rw-r--r--documentation/examples/plugins/manifest_options/manifest.xml95
-rw-r--r--documentation/examples/plugins/start.php0
-rw-r--r--documentation/examples/plugins/views/default/.gitignore0
7 files changed, 27 insertions, 95 deletions
diff --git a/documentation/examples/plugins/README.txt b/documentation/examples/plugins/README.txt
new file mode 100644
index 000000000..9eb04391d
--- /dev/null
+++ b/documentation/examples/plugins/README.txt
@@ -0,0 +1,3 @@
+Plugin Skeleton
+=========================
+
diff --git a/documentation/examples/plugins/skeleton/start.php b/documentation/examples/plugins/actions/.gitignore
index e69de29bb..e69de29bb 100644
--- a/documentation/examples/plugins/skeleton/start.php
+++ b/documentation/examples/plugins/actions/.gitignore
diff --git a/documentation/examples/plugins/languages/en.php b/documentation/examples/plugins/languages/en.php
new file mode 100644
index 000000000..35f838560
--- /dev/null
+++ b/documentation/examples/plugins/languages/en.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * The core language file is in /languages/en.php and each plugin has its
+ * language files in a languages directory. To change a string, copy the
+ * mapping into this file.
+ *
+ * For example, to change the blog Tools menu item
+ * from "Blog" to "Rantings", copy this pair:
+ * 'blog' => "Blog",
+ * into the $mapping array so that it looks like:
+ * 'blog' => "Rantings",
+ *
+ * Follow this pattern for any other string you want to change. Make sure this
+ * plugin is lower in the plugin list than any plugin that it is modifying.
+ *
+ * If you want to add languages other than English, name the file according to
+ * the language's ISO 639-1 code: http://en.wikipedia.org/wiki/List_of_ISO_639-1_codes
+ */
+
+$mapping = array(
+ 'string:here' => 'Display string here',
+);
+
+add_translation('en', $mapping);
diff --git a/documentation/examples/plugins/skeleton/manifest.xml b/documentation/examples/plugins/manifest.xml
index e31624432..e31624432 100644
--- a/documentation/examples/plugins/skeleton/manifest.xml
+++ b/documentation/examples/plugins/manifest.xml
diff --git a/documentation/examples/plugins/manifest_options/manifest.xml b/documentation/examples/plugins/manifest_options/manifest.xml
deleted file mode 100644
index baa6cc3fa..000000000
--- a/documentation/examples/plugins/manifest_options/manifest.xml
+++ /dev/null
@@ -1,95 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<plugin_manifest xmlns="http://www.elgg.org/plugin_manifest/1.8">
- <name>My Plugin</name>
- <author>Elgg</author>
- <version>1.0</version>
- <blurb>A concise description.</blurb>
- <description>This is a longer, more interesting description of my plugin, its features, and other important information.</description>
- <website>http://www.elgg.org/</website>
- <copyright>(C) Elgg 2011</copyright>
- <license>GNU General Public License version 2</license>
-
- <requires>
- <type>elgg_version</type>
- <version>2009030802</version>
- </requires>
-
- <requires>
- <type>elgg_release</type>
- <version>1.8</version>
- </requires>
-
- <screenshot>
- <description>An example screenshot</description>
- <path>graphics/plugin_ss1.png</path>
- </screenshot>
-
- <screenshot>
- <description>Another screenshot</description>
- <path>graphics/plugin_ss2.png</path>
- </screenshot>
-
- <category>admin</category>
- <category>api</category>
-
- <requires>
- <type>php_extension</type>
- <name>gd</name>
- </requires>
-
- <requires>
- <type>php_ini</type>
- <name>short_open_tag</name>
- <value>off</value>
- </requires>
-
- <requires>
- <type>php_extension</type>
- <name>made_up</name>
- <version>1.0</version>
- </requires>
-
- <requires>
- <type>plugin</type>
- <name>fake_plugin</name>
- <version>1.0</version>
- </requires>
-
- <requires>
- <type>plugin</type>
- <name>profile</name>
- <version>1.0</version>
- </requires>
-
- <requires>
- <type>plugin</type>
- <name>profile_api</name>
- <version>1.3</version>
- <comparison>lt</comparison>
- </requires>
-
- <requires>
- <type>priority</type>
- <priority>after</priority>
- <plugin>blog</plugin>
- </requires>
-
- <conflicts>
- <type>plugin</type>
- <name>profile_api</name>
- <version>1.0</version>
- </conflicts>
-
- <provides>
- <type>plugin</type>
- <name>profile_api</name>
- <version>1.3</version>
- </provides>
-
- <provides>
- <type>php_extension</type>
- <name>curl</name>
- <version>1.0</version>
- </provides>
-
-</plugin_manifest>
diff --git a/documentation/examples/plugins/start.php b/documentation/examples/plugins/start.php
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/documentation/examples/plugins/start.php
diff --git a/documentation/examples/plugins/views/default/.gitignore b/documentation/examples/plugins/views/default/.gitignore
new file mode 100644
index 000000000..e69de29bb
--- /dev/null
+++ b/documentation/examples/plugins/views/default/.gitignore