From 454aa6bff38ee540b7467f3caa3d6651b70f14ef Mon Sep 17 00:00:00 2001 From: friendica Date: Sun, 13 Oct 2013 20:09:11 -0700 Subject: turn off endless scroll if we have no more content to load - currently for mod_display, need to add to other content modules --- include/items.php | 1 + js/main.js | 4 +++- mod/display.php | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/include/items.php b/include/items.php index 28aa632ca..2229da5db 100755 --- a/include/items.php +++ b/include/items.php @@ -1825,6 +1825,7 @@ function item_store_update($arr,$allow_exec = false) { unset($arr['id']); unset($arr['uid']); + if(array_key_exists('edit',$arr)) unset($arr['edit']); $arr['mimetype'] = ((x($arr,'mimetype')) ? notags(trim($arr['mimetype'])) : 'text/bbcode'); diff --git a/js/main.js b/js/main.js index d5260a4be..11a3b360c 100644 --- a/js/main.js +++ b/js/main.js @@ -137,7 +137,9 @@ e.tipTip({defaultPosition: pos, edgeOffset: 8}); });*/ - + var e = document.getElementById('content-complete'); + if(typeof e !== 'undefined') + pageHasMoreContent = false; /* setup onoff widgets */ $(".onoff input").each(function(){ diff --git a/mod/display.php b/mod/display.php index c9f6595c6..41df5fca6 100644 --- a/mod/display.php +++ b/mod/display.php @@ -166,6 +166,8 @@ function display_content(&$a, $update = 0, $load = false) { ); } + $o .= '
'; + return $o; -- cgit v1.2.3