Hello,
you can comment those two pieces of code, which are responsible for hiding the annotations in the frontend.
1) add_filter('the_content', 'tma_annotate_backend');
….
2) function tma_annotate_backend($content) {
return preg_replace('/(<[^>]+) class="annotation".*?data-annotation=".*?"/i', '$1', $content);
}
Also, annotations can be seen by unregistered users in the frontend.
Thanks for using the plugin.
Raúl
Thank you so much for your fast answer! <3 This is a lifesaver! I’ll rate the plugin when I try it later today!
In the meantime, feel free to ask if you find any problem with it 🙂 I wrote that code some time ago so I might be missing something 😉
I tried this method and here are 2 annotation example posts but both just show the style of the highlighter and not the actual annotation. https://anyshapemusic.com/blog/ Any advice would be appreciated!
You have to get a TinyMCE instance in frontend as the plugin works with that editor.
If you don’t have an editor in frontend, you can’t load the plugin.js as the editor doesn’t exists.