diff options
author | Mike Macgirvin <mike@macgirvin.com> | 2010-09-20 22:27:33 -0700 |
---|---|---|
committer | Mike Macgirvin <mike@macgirvin.com> | 2010-09-20 22:27:33 -0700 |
commit | a428695f8e9e3441bd3012a74a8385a713034007 (patch) | |
tree | cb3e9b1dbed5ab0a6e03c2cd9fe8fa006b6f3462 /include/main.js | |
parent | b9247f1dcccd18bcfa402852f5ab7878cef8d105 (diff) | |
download | volse-hubzilla-a428695f8e9e3441bd3012a74a8385a713034007.tar.gz volse-hubzilla-a428695f8e9e3441bd3012a74a8385a713034007.tar.bz2 volse-hubzilla-a428695f8e9e3441bd3012a74a8385a713034007.zip |
pass vars via javascript, not html. Also fix broken pause img on IE
Diffstat (limited to 'include/main.js')
-rw-r--r-- | include/main.js | 16 |
1 files changed, 6 insertions, 10 deletions
diff --git a/include/main.js b/include/main.js index 1ddab0dc2..8245cef2f 100644 --- a/include/main.js +++ b/include/main.js @@ -49,15 +49,11 @@ event.preventDefault(); if(stopped == false) { stopped = true; - $('#pause img').attr('src','images/pause.gif'); - $('#pause img').css({'border': '1px solid black'}); - + $('#pause').html('<img src="images/pause.gif" alt="pause" style="border: 1px solid black;" />'); } else { stopped = false; - $('#pause img').attr('src',''); - $('#pause img').css({'border': 'none'}); - + $('#pause').html(''); } } }); @@ -65,8 +61,8 @@ function NavUpdate() { - if($('#live-network').length) { src = 'network'; pr = $('#live-network').attr('profile'); liveUpdate(); } - if($('#live-profile').length) { src = 'profile'; pr = $('#live-profile').attr('profile'); liveUpdate(); } + if($('#live-network').length) { src = 'network'; liveUpdate(); } + if($('#live-profile').length) { src = 'profile'; liveUpdate(); } if(! stopped) { $.get("ping",function(data) { @@ -91,14 +87,14 @@ } function liveUpdate() { - if((src == null) || (stopped)) { $('.like-rotator').hide(); return; } + if((src == null) || (stopped) || (! profile_uid)) { $('.like-rotator').hide(); return; } if($('.comment-edit-text-full').length) { livetime = setTimeout(liveUpdate, 10000); return; } prev = 'live-' + src; - $.get('update_' + src + '?p=' + pr + '&msie=' + ((msie) ? 1 : 0),function(data) { + $.get('update_' + src + '?p=' + profile_uid + '&msie=' + ((msie) ? 1 : 0),function(data) { $('.wall-item-outside-wrapper',data).each(function() { var ident = $(this).attr('id'); if($('#' + ident).length == 0) { |