WordPress Highlight Search Terms Plugin and Cufon Conflict Fix

Whilst implementing Highlight Search Terms (HLST) plugin for a client's website that also uses Cufon font replacement, I found that whenever the HLST plugin kicked in, the Cufon'd text disappeared.

The symptom was that Cufon fonts flash up but it looks like they then go 'invisible' when the HLST JS kicks in. I guessed that the insertion of the <span class="hilite"> element breaks Cufon's ability to manipulate the DOM (or something!)?

Tried a quick fix. Whacked Cufon.refresh(); in just before the end of the jQuery document.ready function - i.e. before the last })); in both compressed and uncompressed versions of the plugin's JS file.

Cross-posted from: http://wordpress.org/support/topic/plugin-highlight-search-terms-this-plug-in-create-problem-with-cufon-font-replacement?replies=8#post-1921792

Hope this helps someone!


Digg This
Reddit This
Stumble Now!
Share on Facebook
Bookmark this on Delicious
Share on LinkedIn
Bookmark this on Technorati
Post on Twitter
Buzz this!


Printed from: http://www.divydovy.com/2011/02/wordpress-highlight-search-terms-plugin-and-cufon-conflict/. © divydovy 2014

4 Comments   »

RSS feed for comments on this post , TrackBack URI

Leave a Reply