django summernote create custom buttons -


i'd add custom button similar one:

$('#makesnote').click(function(event) {  var highlight = window.getselection(),      spn = document.createelement('span'),    range = highlight.getrangeat(0)     spn.innerhtml = highlight;    spn.classname = 'snote';      spn.style.color = 'blue';     range.deletecontents();    range.insertnode(spn); }); 

js fiddle

http://jsfiddle.net/ypweuw1l/

i'm not sure how go adding django app? don't see in django-summernote docs.

i don't know django-summernote well. can create custom button , use on toolbar options.

for more details... http://summernote.org/deep-dive/#custom-button


Comments

Popular posts from this blog

android - Why am I getting the message 'Youractivity.java is not an activity subclass or alias' -

python - How do I create a list index that loops through integers in another list -

c# - “System.Security.Cryptography.CryptographicException: Keyset does not exist” when reading private key from remote machine -