Support » Fixing WordPress » Google Search Hilite plugin

Viewing 7 replies - 1 through 7 (of 7 total)
  • Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Heh, I can’t even find your site in Google. What were the search terms you used?

    This question has been answered before a number of times. If the search returns ONE post, there is no highlighting of the words – it goes directly to the post. Highlighting occurs only if there are TWO or MORE posts returned in the search function.

    Moderator James Huff

    (@macmanx)

    Volunteer Moderator

    Beel, I have no problems if only one post is found on my site. What search terms did you use to find programmerfreak’s site?

    I just tested your site and the plugin seems to work correctly. I used happy as the search term and there were two post results with the term highlighted in orange.
    Phillip

    Google has always been slow on indexing a new website…
    Thanks Beel and Philip, and I’m sure it has been asked a bunch of times, but I am just too lazy to look through someone else’s code at the moment.
    Thanks again everyone.

    macmanx: The site is evidently not indexed by Google yet, I just know it works by performing the on-site search function. The plugin does work for single posts returned from Google, Lycos, and Yahoo just not on-site searches.
    On-site, a search returning multiple posts will have “index.php?s=blah-blah&submit=Go%21” and the plugin can do it’s thing on the search terms, but there are none when a single post is returned so the css is in the head, but no words highlighted 🙁

    The plugin (as included in WP 1.2) does not work with languages that don’t use space to mark word boundaries, such as Chinese, Japanese. This can be fixed most easily by removing the \b from instances of

    /(\b$term\b)/i

    Basically just forget about trying to detect word boundaries and just highlight all matching terms. This could cause “mail” to also highlight “Gmail”, “email”, etc. But hey, this could be a feature, too.

    Caveat: above hack not yet tested, so….

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Google Search Hilite plugin’ is closed to new replies.