Update by natay on Wed Jun  5 08:16:42 EDT 2019 from H7-D25RF0PLGQ18
@@ -180,47 +180,6 @@ function remove_trigger() {
});
}
-function enable_inline_editing(editing, post_uid) {
- // Make element 'editing_elem' editable with given params.
-
- // Determine number of rows in textarea from number of lines in content
- var arraytxt = editing.text().split('\n');
- var rows = arraytxt.length;
- // Url to reload html when user cancels edit.
- var html_url = '/ajax/html/' + post_uid + '/';
- // Url to edit text on POST request and return text on GET request
- var edit_url = '/ajax/edit/';
- // Vary the width of textarea displayed
- //var width = editing.attr('inputwidth') || '605px';
-
- // Make element editable.
- editing.editable(edit_url, {
- loadurl: edit_url,
- loadtype:'POST',
- onblur: 'ignore',
- onreset: function (settings, original) {
- editing.load(html_url);
- },
- rows: rows,
- name: 'content',
- submit: 'Save',
- cancel: 'Cancel',
- formid: 'inputform',
- submitcssclass: 'ui green small button save inline-buttons',
- cancelcssclass: 'ui orange small button cancel inline-buttons',
- type: 'textarea',
- width: '605px',
- cssclass: "ui inline-post form"
- }).keydown(function (event) {
- // Submit edit with CTRL-ENTER
- if ((event.ctrlKey || event.metaKey) && (event.keyCode === 13 || event.keyCode === 10)) {
- event.preventDefault();
- $(this).find('.save.inline-buttons').click();
- }
- });
-}
-
-
function edit_post(post_uid) {
var edit_url = '/ajax/edit/';
var form_elem = $('#inplace-form-' + post_uid);
