aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Nojs.php
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Module/Nojs.php')
-rw-r--r--Zotlabs/Module/Nojs.php15
1 files changed, 15 insertions, 0 deletions
diff --git a/Zotlabs/Module/Nojs.php b/Zotlabs/Module/Nojs.php
new file mode 100644
index 000000000..6fd6d8106
--- /dev/null
+++ b/Zotlabs/Module/Nojs.php
@@ -0,0 +1,15 @@
+<?php
+namespace Zotlabs\Module;
+
+
+class Nojs extends \Zotlabs\Web\Controller {
+
+ function init() {
+ $n = ((argc() > 1) ? intval(argv(1)) : 1);
+ setcookie('jsdisabled', $n, 0, '/');
+ $p = $_GET['redir'];
+ $hasq = strpos($p,'?');
+ goaway(z_root() . (($p) ? '/' . $p : '') . (($hasq) ? '' : '?f=' ) . '&jsdisabled=' . $n);
+
+ }
+}