diff options
author | Git <git@what.cd> | 2013-09-01 08:00:54 +0000 |
---|---|---|
committer | Git <git@what.cd> | 2013-09-01 08:00:54 +0000 |
commit | 25bf6fe0e981c39993436ba852d956e4c4b7a0e4 (patch) | |
tree | b98b0d66692a20bc6123af477590fcc96c55a4a5 /static/functions/news_ajax.js | |
parent | a382d91a3511fae91b5b30bfd57f5e5d47daff05 (diff) | |
download | Gazelle-25bf6fe0e981c39993436ba852d956e4c4b7a0e4.zip Gazelle-25bf6fe0e981c39993436ba852d956e4c4b7a0e4.tar.gz Gazelle-25bf6fe0e981c39993436ba852d956e4c4b7a0e4.tar.bz2 |
Empty commit
Diffstat (limited to 'static/functions/news_ajax.js')
-rw-r--r-- | static/functions/news_ajax.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/static/functions/news_ajax.js b/static/functions/news_ajax.js index 1623937..ae6ee82 100644 --- a/static/functions/news_ajax.js +++ b/static/functions/news_ajax.js @@ -32,11 +32,11 @@ function news_ajax(event, count, offset, privileged) { })); // I'm so happy with this condition statement. if (privileged) { - $('#news' + this[0]).append('<div class="head"><strong>' + this[1] + '</strong> ' + this[2] + ' - <a href="tools.php?action=editnews&id=' + this[0] + '" class="brackets">Edit</a></div>'); + $('#news' + this[0]).append('<div class="head"><strong>' + this[1] + '</strong> ' + this[2] + ' - <a href="tools.php?action=editnews&id=' + this[0] + '" class="brackets">Edit</a><span style="float: right;"><a class="brackets" onclick="$(\'#newsbody' + this[0] + '\').gtoggle(); this.innerHTML=(this.innerHTML == \'Hide\' ? \'Show\' : \'Hide\'); return false;" href="#">Hide</a></span></div>'); } else { - $('#news' + this[0]).append('<div class="head"><strong>' + this[1] + '</strong> ' + this[2] + '</div>'); + $('#news' + this[0]).append('<div class="head"><strong>' + this[1] + '</strong> ' + this[2] + '<span style="float: right;"><a class="brackets" onclick="$(\'#newsbody' + this[0] + '\').gtoggle(); this.innerHTML=(this.innerHTML == \'Hide\' ? \'Show\' : \'Hide\'); return false;" href="#">Hide</a></span></div>'); } - $('#news' + this[0]).append('<div class="pad">' + this[3] + '</div>'); + $('#news' + this[0]).append('<div class="pad" id="newsbody'+this[0]+'">' + this[3] + '</div>'); }); // Update the onclick parameters to appropriate offset. $(event.target).attr('onclick', 'news_ajax(event, ' + count + ', ' + (count + offset) + ', ' + privileged + '); return false;'); |