summaryrefslogtreecommitdiff
path: root/backend.php
diff options
context:
space:
mode:
authorAndrew Dolgov <[email protected]>2021-02-17 21:44:21 +0300
committerAndrew Dolgov <[email protected]>2021-02-17 21:44:21 +0300
commite4609c18efceebb1e021d814f53061ada7f6489a (patch)
tree0968e0da3dc2d1b4cdc12c2a29549c27dc82ea14 /backend.php
parentb16abc157ee584f4be80a537ee24ec9e5ff25496 (diff)
* add (disabled) shortcut syntax for plugin methods
* add controls shortcut for pluginhandler tags * add similar shortcut for frontend * allow plugins to selectively exclude their methods from CSRF checking
Diffstat (limited to 'backend.php')
-rw-r--r--backend.php11
1 files changed, 11 insertions, 0 deletions
diff --git a/backend.php b/backend.php
index 9ecc22914..e64c6561f 100644
--- a/backend.php
+++ b/backend.php
@@ -88,6 +88,17 @@
5 => __("Power User"),
10 => __("Administrator"));
+ // shortcut syntax for plugin methods (?op=plugin--pmethod&...params)
+ /* if (strpos($op, PluginHost::PUBLIC_METHOD_DELIMITER) !== false) {
+ list ($plugin, $pmethod) = explode(PluginHost::PUBLIC_METHOD_DELIMITER, $op, 2);
+
+ // TODO: better implementation that won't modify $_REQUEST
+ $_REQUEST["plugin"] = $plugin;
+ $method = $pmethod;
+ $op = "pluginhandler";
+ } */
+
+ // TODO: figure out if is this still needed
$op = str_replace("-", "_", $op);
$override = PluginHost::getInstance()->lookup_handler($op, $method);