diff options
author | zotlabs <mike@macgirvin.com> | 2017-12-04 15:14:58 -0800 |
---|---|---|
committer | zotlabs <mike@macgirvin.com> | 2017-12-04 15:14:58 -0800 |
commit | cb39d9435da54239e8e36d2d53877a19c10bab83 (patch) | |
tree | be89ef38d054ab88276fde0410182ce44a8bc193 /Zotlabs/Module/Update.php | |
parent | 0305983360568f991365cd815d081afedaa6d742 (diff) | |
download | volse-hubzilla-cb39d9435da54239e8e36d2d53877a19c10bab83.tar.gz volse-hubzilla-cb39d9435da54239e8e36d2d53877a19c10bab83.tar.bz2 volse-hubzilla-cb39d9435da54239e8e36d2d53877a19c10bab83.zip |
We only require one Update module. The rest are superfluous.
Diffstat (limited to 'Zotlabs/Module/Update.php')
-rw-r--r-- | Zotlabs/Module/Update.php | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/Zotlabs/Module/Update.php b/Zotlabs/Module/Update.php new file mode 100644 index 000000000..e7470363b --- /dev/null +++ b/Zotlabs/Module/Update.php @@ -0,0 +1,34 @@ +<?php +namespace Zotlabs\Module; + + +class Update extends \Zotlabs\Web\Controller { + + function get() { + + $profile_uid = intval($_GET['p']); + + if(argc() < 2) { + killme(); + } + + // These modules don't have a completely working liveUpdate implementation currently + + if(in_array(strtolower(argv(1)),['articles','cards'])) + killme(); + + $module = "\\Zotlabs\\Module\\" . ucfirst(argv(1)); + $load = (((argc() > 2) && (argv(2) == 'load')) ? 1 : 0); + + $mod = new $module; + + header("Content-type: text/html"); + + echo "<!DOCTYPE html><html><body><section>\r\n"; + echo $mod->get($profile_uid, $load); + echo "</section></body></html>\r\n"; + + killme(); + + } +} |