aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Module/Nojs.php
blob: 6fd6d8106d142d77e54bc35d3f84233da870d8cb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
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);
	
	}
}