Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • James 2 posts 72 karma points
    Jul 12, 2016 @ 22:33
    James
    0

    Examine Search - cannot search for macro content inserted inside an RTE

    Hello, looking for some help with RTE macros and search.

    I implemented a search feature for my site using ezSearch - it was easy to install and create a search results page.

    Many pages on my site are using the RTE for content input. As the scope of features grew, I expanded the use of the RTE to allow for a macro to be inserted. The macro is rendered correctly in both the back-end RTE as well as on the front end size.

    My problem: The normal rich text content inside the RTE CAN be indexed and discovered via Examine search (ezSearch), however the content inside the RTE which is inserted via a Macro CANNOT be indexed and discovered.

    Why does this happen? How can I provide search functionality for the RTE content that is inserted via a macro?

    Thanks,

  • David Peck 690 posts 1896 karma points c-trib
    Jul 13, 2016 @ 07:40
    David Peck
    0

    So the macro only gets added as a placeholder in the RTE (like a shortcode in Wordpress), and so it doesn't get referenced. It's one reason not to use macros. A few options for you:

    1. Use Google Custom Search Engine instead
    2. Add the macro text in to the index using the HTMLAgilityPack (server side JQuery... kind of)
    3. Add the macro text in to the index using the umbraco.library.RenderMacroContent

    And how do you add the content in to the index? There are a few posts around. This is the first on I came across.

  • James 2 posts 72 karma points
    Jul 13, 2016 @ 18:32
    James
    0

    Thanks for your response. I'll look into switching to using Google Custom Search Engine.

Please Sign in or register to post replies

Write your reply to:

Draft