aboutsummaryrefslogtreecommitdiffstats
path: root/mod/display.php
diff options
context:
space:
mode:
authorredmatrix <git@macgirvin.com>2016-04-12 22:55:26 -0700
committerredmatrix <git@macgirvin.com>2016-04-12 22:55:26 -0700
commit91cc36514306e827c126ceed6c17486c85f5544c (patch)
treebb763fc5e2bb5e3becbce685efc977acb63b5979 /mod/display.php
parentf4a27afee9c1dc12afd2a15adef9f33654fa5ddd (diff)
downloadvolse-hubzilla-91cc36514306e827c126ceed6c17486c85f5544c.tar.gz
volse-hubzilla-91cc36514306e827c126ceed6c17486c85f5544c.tar.bz2
volse-hubzilla-91cc36514306e827c126ceed6c17486c85f5544c.zip
reverse the logic of the jsenabled setting so that sessions without js are performance penalised instead of regular sessions.
Diffstat (limited to 'mod/display.php')
-rw-r--r--mod/display.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/mod/display.php b/mod/display.php
index ef140d454..9c50eb9c0 100644
--- a/mod/display.php
+++ b/mod/display.php
@@ -168,13 +168,13 @@ function display_content(&$a, $update = 0, $load = false) {
$sql_extra = public_permissions_sql($observer_hash);
- if(($update && $load) || ($_COOKIE['jsAvailable'] != 1)) {
+ if(($update && $load) || ($_COOKIE['jsdisabled'] == 1)) {
$updateable = false;
$pager_sql = sprintf(" LIMIT %d OFFSET %d ", intval(App::$pager['itemspage']),intval(App::$pager['start']));
- if($load || ($_COOKIE['jsAvailable'] != 1)) {
+ if($load || ($_COOKIE['jsdisabled'] == 1)) {
$r = null;
require_once('include/identity.php');
@@ -290,13 +290,13 @@ function display_content(&$a, $update = 0, $load = false) {
}
- if ($_COOKIE['jsAvailable'] == 1) {
- $o .= conversation($a, $items, 'display', $update, 'client');
- } else {
+ if ($_COOKIE['jsdisabled'] == 1) {
$o .= conversation($a, $items, 'display', $update, 'traditional');
if ($items[0]['title'])
App::$page['title'] = $items[0]['title'] . " - " . App::$page['title'];
-
+ }
+ else {
+ $o .= conversation($a, $items, 'display', $update, 'client');
}
if($updateable) {