• Resolved jmwfs

    (@jmwfs)


    Does the plugin allow for accordion/tab content to be searched as they are not currently appearing in my search results?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author Vinod Dalvi

    (@vinod-dalvi)

    I hope you are well today and thank you for your question.

    Are you creating the accordion/tab content using shortcodes?

    Best regards,

    Thread Starter jmwfs

    (@jmwfs)

    Thanks for the reply. Below is an example of my php code. It’s pulling in the content from ACF fields.

    <?php /* Template Name: History Template */ get_header(); ?>

    <!– History Start –>

    <section class=”history-wrapper”>

    <div class=”container”>
    <div class=”row”>

    <div class=”nine columns indented”>
    <h1><?php the_title(); ?></h1>
    <?php the_content(); ?>

    <div class=”history-accordion”>
    <ul class=”accordion”>

    <li class=”accordion-item”>
    Short History of the Commons
    <ul class=”accordion-collapse”>
    <?php the_field(‘short_history_text’); ?>

    <li class=”accordion-item”>
    Extended History of the Commons
    <ul class=”accordion-collapse”>

    <li class=”accordion-item”>
    Mesolithic hunter-gatherers dwelling amidst the rocks
    <div class=”accordion-collapse”>
    <?php the_field(‘mesolithic_text’); ?>
    </div>

    <li class=”accordion-item”>
    Saxon times (400-1066) – Rustwell and early settlements
    <div class=”accordion-collapse”>
    <?php the_field(‘saxon_text’); ?>
    </div>

    <li class=”accordion-item”>
    Later medieval times (1066-1599)
    <div class=”accordion-collapse”>
    <?php the_field(‘medieval_text’); ?>
    </div>

    <li class=”accordion-item”>
    Early modern times (1600-1837) – the springs
    <div class=”accordion-collapse”>
    <?php the_field(‘early_modern_text’); ?>
    </div>

    <li class=”accordion-item”>
    The Victorian years
    <div class=”accordion-collapse”>
    <?php the_field(‘victorian_text’); ?>
    </div>

    <li class=”accordion-item”>
    The early 1900s
    <div class=”accordion-collapse”>
    <?php the_field(‘early_1900s_text’); ?>
    </div>

    <li class=”accordion-item”>
    Modern-Elizabethan period
    <div class=”accordion-collapse”>
    <?php the_field(‘elizabethan_text’); ?>
    </div>

    <li class=”accordion-item”>
    The Freehold Tenants of the Manor of Rusthall
    <ul class=”accordion-collapse”>
    <?php the_field(‘freehold_tenants_text’); ?>

    </div>

    </div>

    </div>
    </div>

    </section>

    <!– History End –>

    <?php get_footer();?>

    Plugin Author Vinod Dalvi

    (@vinod-dalvi)

    If it is saved in the custom fields then please make sure that you have configured the plugin to search custom field values as below.

    https://ivorysearch.com/docs/search-custom-fields-and-meta-boxes/

    Thread Starter jmwfs

    (@jmwfs)

    Awesome. That picks out the correct page but doesn’t pick out or take me to the exact content I’ve searched for.

    Eg. I have several mentions on the word ‘bees’ but the search only show 1 result.

    Plugin Author Vinod Dalvi

    (@vinod-dalvi)

    Awesome. That picks out the correct page but doesn’t pick out or take me to the exact content I’ve searched for.

    Do you mean after clicking on the search results you want to redirect to the page and scroll to the word on that page?

    Eg. I have several mentions on the word ‘bees’ but the search only show 1 result.

    Could you please share the page URL from your site where the work is displaying so that I can troubleshoot it?

    Thread Starter jmwfs

    (@jmwfs)

    Hi apologies for delay it was a local site so I’ve uploaded a test site for you to look at.

    It’s only the Homepage and Nature page that are visible. But if you use the word ‘bees’ in the search bar.

    You’ll see although there are multiple references to bees on the nature page that it only display 1 result.

    I’m assuming that it should show multiple results for ‘bees’ and that when one of the results is clicked it takes you (scrolls) to where that word is?

    https://search.cordiscreative.com/

    Thanks

    Plugin Author Vinod Dalvi

    (@vinod-dalvi)

    No, this does not work like this.

    The AJAX search results only display one result per page and clicking on it redirects to the page but does not scroll to the searched word on the page.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Accordion/Tab Content’ is closed to new replies.