diff options
author | Fabio Comuni <fabrix.xm@gmail.com> | 2012-01-06 09:11:48 +0100 |
---|---|---|
committer | Fabio Comuni <fabrix.xm@gmail.com> | 2012-01-06 09:11:48 +0100 |
commit | f9b0af6f2f0c57481a0b5b3dc269b2389f3fa872 (patch) | |
tree | f06c87479be60f3c601cbeed6088e6e74d97785c /js/main.js | |
parent | efe308b5ac9ac7e8d399fb880f31b6967de8fec1 (diff) | |
parent | c3ada095f4156bba01e77d2d250d5821ba5e859e (diff) | |
download | volse-hubzilla-f9b0af6f2f0c57481a0b5b3dc269b2389f3fa872.tar.gz volse-hubzilla-f9b0af6f2f0c57481a0b5b3dc269b2389f3fa872.tar.bz2 volse-hubzilla-f9b0af6f2f0c57481a0b5b3dc269b2389f3fa872.zip |
Merge remote-tracking branch 'friendica/master'
Diffstat (limited to 'js/main.js')
-rw-r--r-- | js/main.js | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/js/main.js b/js/main.js index 96c7fa642..009fb55bb 100644 --- a/js/main.js +++ b/js/main.js @@ -389,6 +389,7 @@ unpause(); commentBusy = true; $('body').css('cursor', 'wait'); + $("#comment-preview-inp-" + id).val("0"); $.post( "item", $("#comment-edit-form-" + id).serialize(), @@ -411,6 +412,28 @@ return false; } + + function preview_comment(id) { + $("#comment-preview-inp-" + id).val("1"); + $("#comment-edit-preview-" + id).show(); + $.post( + "item", + $("#comment-edit-form-" + id).serialize(), + function(data) { + if(data.preview) { + + $("#comment-edit-preview-" + id).html(data.preview); + $("#comment-edit-preview-" + id + " a").removeAttr('href'); + } + }, + "json" + ); + return true; + } + + + + function unpause() { // unpause auto reloads if they are currently stopped totStopped = false; |