urvanov-ru / crayon-syntax-highlighter

Syntax Highlighter supporting multiple languages, themes, fonts, highlighting from a URL, local file or post text.
https://wordpress.org/plugins/urvanov-syntax-highlighter/
GNU General Public License v3.0
60 stars 11 forks source link

Feature: Ajax Reload Highlighter #31

Open ayachi-core-001 opened 3 years ago

ayachi-core-001 commented 3 years ago

Sorry here again. How can I fire the Highlighter when using ajax to show a post page.

Does this in your code works? I also use ajax to "show more posts, but sometimes it won't work.

$(document).ready(function () {
        UrvanovSyntaxHighlighterSyntax.init();
    });
urvanov-ru commented 3 years ago

@lmcdn yes, this code is initialization for highlighter. I don't know, can it work with ajax or no. I never used it in my site.