X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=view%2Ftheme%2Ffrio%2Ftemplates%2Fjot-header.tpl;h=6d481451185c6c8aa9cdf633599141df742ebb56;hb=0f8148a4cb7c477b363cccdb5c638cd10d9df531;hp=5b826f45e2f41d06e59dedb098ff9f12de4b3578;hpb=8ec424325375aa923c7d2d78ac8ddcc352f09cff;p=friendica.git diff --git a/view/theme/frio/templates/jot-header.tpl b/view/theme/frio/templates/jot-header.tpl index 5b826f45e2..6d48145118 100644 --- a/view/theme/frio/templates/jot-header.tpl +++ b/view/theme/frio/templates/jot-header.tpl @@ -283,23 +283,11 @@ function enableOnUser(){ } function jotShare(id) { -// if ($('#jot-popup').length != 0) $('#jot-popup').show(); -// -// $('#like-rotator-' + id).show(); -// $.get('share/' + id, function(data) { -// if (!editor) $("#profile-jot-text").val(""); -// initEditor(function(){ -// addeditortext(data); -// $('#like-rotator-' + id).hide(); -// $(window).scrollTop(0); -// }); -// -// }); - $.get('share/' + id, function(data) { - if (!editor) $("#profile-jot-text").val(""); + // remove the former content of the text input + $("#profile-jot-text").val(""); initEditor(function(){ - addeditortext(data); + addeditortext(data); }); }); @@ -399,18 +387,11 @@ function enableOnUser(){ function jotShow() { var modal = $('#jot-modal').modal(); - var jot = $("#profile-jot-form"); - - // Clear bs modal on close - // We need this to prevent that the modal displays old content - $('body').on('hidden.bs.modal', '#jot-modal', function () { - $(this).removeData('bs.modal'); - $("#jot-content").append(jot); - }); + jotcache = $("#profile-jot-form"); modal .find('#jot-modal-body') - .append(jot) + .append(jotcache) .modal.show ; }