diff options
-rw-r--r-- | lib/dokuwiki.php | 2 | ||||
-rw-r--r-- | manifest.xml | 14 | ||||
-rw-r--r-- | start.php | 12 |
3 files changed, 13 insertions, 15 deletions
diff --git a/lib/dokuwiki.php b/lib/dokuwiki.php index 9881c0e55..b49e4d4ee 100644 --- a/lib/dokuwiki.php +++ b/lib/dokuwiki.php @@ -58,5 +58,3 @@ function dokuwiki_create_datafolder($path) { dokuwiki_recurse_copy($orig, $path); } - -?> diff --git a/manifest.xml b/manifest.xml index e0821710d..9c9ca808f 100644 --- a/manifest.xml +++ b/manifest.xml @@ -1,24 +1,22 @@ <?xml version="1.0" encoding="UTF-8"?> <plugin_manifest xmlns="http://www.elgg.org/plugin_manifest/1.8"> <name>Dokuwiki</name> - <author>Lorea</author> - <version>1.4.1</version> - <category>bundled</category> + <author>Lorea developers</author> + <version>1.4.2</version> + <category>unbundled</category> <category>content</category> - <category>widget</category> <description>Dokuwiki integration for Elgg</description> <website>https://lorea.cc/</website> <copyright>(C) Lorea 2011</copyright> - <license>GNU Public License version 2</license> + <license>GNU General Public License, version 2 or later</license> <requires> - <type>elgg_version</type> - <version>2011061200</version> + <type>elgg_release</type> + <version>1.8</version> </requires> <requires> <type>priority</type> <priority>after</priority> <plugin>groups</plugin> </requires> - <admin_interface>simple</admin_interface> <activate_on_install>true</activate_on_install> </plugin_manifest> @@ -57,7 +57,7 @@ function dokuwiki_init(){ if ($page[0] === "all") { elgg_set_context("search"); include(elgg_get_plugins_path().'dokuwiki/index.php'); - return; + return true; } elgg_set_context("dokuwiki"); @@ -65,7 +65,7 @@ function dokuwiki_init(){ $dokuwiki_path = elgg_get_plugins_path().'dokuwiki/vendors/dokuwiki/'; $doku = current_dokuwiki_entity(); if (!$doku) // can fail if there is no user and wiki doesnt exist - forward(); + return false; $parsed_url = parse_url(elgg_get_site_url().'dokuwiki/'); $url_base = $parsed_url['path']; if (is_numeric($page[0])) { @@ -74,14 +74,16 @@ function dokuwiki_init(){ if (($ent && $ent instanceof ElggGroup) && $ent->dokuwiki_enable !== 'yes') { // wiki not activated for this group. bail out. - forward(); + elgg_pop_context(); + return false; } if ($ent && (/*$ent instanceof ElggUser ||*/ $ent instanceof ElggGroup)) { elgg_set_page_owner_guid($entity_guid); $data_path = elgg_get_data_path().'wikis/'.$entity_guid; } else { // can't see the group - forward(); + elgg_pop_context(); + return false; } $page = array_slice($page, 1); // pop first element define('DOKU_REL', $url_base.$entity_guid."/"); @@ -135,7 +137,7 @@ function dokuwiki_init(){ $doku_body = elgg_view('dokuwiki/index',array('page'=>implode("/",$page))); echo $doku_body; } - return; + return true; } /** |