Skip to content

Commit

Permalink
Fix for Issues sheadawson#52,sheadawson#49 and sheadawson#45 - save c…
Browse files Browse the repository at this point in the history
…ontent using setContent, call _super for saving of HTMLEditorField content
  • Loading branch information
JamesDPC committed Feb 23, 2017
1 parent d0d146b commit f9466d8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions javascript/shortcodable.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@
var shortcodable = tinyMCE.activeEditor.plugins.shortcodable;
var ed = this.getEditor();
var newContent = shortcodable.replacePlaceholdersWithShortcodes($(this).val(), ed);
$(this).val(newContent);
ed.setContent(newContent);
this._super(e);
}
},
});
Expand Down Expand Up @@ -74,7 +75,6 @@
var shortcodable = tinyMCE.activeEditor.plugins.shortcodable;
ed.replaceContent(shortcode);
var newContent = shortcodable.replaceShortcodesWithPlaceholders(ed.getContent(), ed.getInstance());
console.log(newContent);
ed.setContent(newContent);
});
}
Expand Down

0 comments on commit f9466d8

Please sign in to comment.