• Resolved hebhansen

    (@hebhansen)


    Hey Relevans

    Amelia is a great booking plugin with Service Categories and services available for online booking. I cannot see them idex in search. Also I cannot activate the above for indexing. Do you have any advise to make this happen? I would say it’s quite important if hairdress is your business, then haircut, beard and brazilian wax is searchable.

    Amelia is not structured in pages/posts but rather a java/Json or something structure.

    Btw: I have the java search thing with the blue arrow. Can I advise that you color it achromatic from white over grey to black. This way it matches all themes. Do you have css, so that I can color arrow and also background and text color. I have a site where text is white on white, so it is not seen. I wish to theme text i field also and the x for delete.

    Further questions:

    Can you confirm this code is no longer relevant?

    //Relevanssi Ajax - Fix after wp 6.5
    add_filter( 'relevanssi_live_search_add_result_div', '__return_false' );

    And this:

    //Add the Search Form and Javascript
    //Set theme_location parameter by the menu locations theme offers

    add_filter('wp_nav_menu_items', 'add_search_form', 10, 2);

    // Display fontawesome search icon in menus and toggle search form

    function add_search_form($items, $args) {
    if( $args->theme_location == 'primary' )
    $items .= '<li class="search"><a class="search_icon"><i class="fa fa-search"></i></a><div style="display:none;" class="spicewpsearchform">'. get_search_form(false) .'</div></li>';
    return $items;
    }

    //Adding Javascript
    add_action( 'wp_head', function () { ?>

    <script>
    jQuery(document).ready(function($) {
    $(".search_icon").click(function() {
    $(".spicewpsearchform").slideToggle();
    });

    $(document).keydown(function(e) {
    if (e.keyCode == 27) {
    //$(modal_or_menu_element).closeElement();
    $(".spicewpsearchform").hide();
    }
    });
    });

    Thx. love this plugin

    • This topic was modified 1 month, 3 weeks ago by hebhansen.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Mikko Saari

    (@msaari)

    I don’t know how the Amelia plugin works. However, if it doesn’t use posts to store the data, it’s out of reach for Relevanssi. Relevanssi can only work with posts. This is strictly impossible to fix, it’s as the data doesn’t exist as far as Relevanssi is concerned.

    Whether relevanssi_live_search_add_result_div set to false is relevant or not depends on your theme. Sometimes you need it, sometimes you don’t. It’s better if you don’t need it. Using wp_nav_menu_items to add the search form to the nav menu is relevant if you want a search form in the nav menu.

    The default blue colour is fine. It’s easy to change with CSS to whatever you want. The same with the text colours, you can CSS whatever you want there.

    Thread Starter hebhansen

    (@hebhansen)

    Theme is TT4 So a block theme. Nav menu is a block. How can I tell if I need it?

    Do you have CSS available to acomplish this?

    Plugin Author Mikko Saari

    (@msaari)

    I don’t think block menus use wp_nav_menu_items.

    Here’s the CSS:

    .rlv-has-spinner {
    border-color: <color here>;
    border-right-color: transparent;
    }

    .rlv-has-spinner::after {
    background-color: <color here>;
    }

    Thread Starter hebhansen

    (@hebhansen)

    Thx for sharing and working. I still have white search result links on white background = not readable..

    WP TT4 theme sets nav color based on background color. Black on light and white on colored. This color is applied to search links. I need search links to be other color on white, but without changing all links on the site and other sites (multisite). I tried this:

    .ajax-results .relevanssi-live-search-result:a {
    color: yellow;
    font-size: inherit;
    line-height: 1.2rem;
    }

    .ajax-results .relevanssi-live-search-result-status {
    color: #636363;
    }

    Status color works fine. Search result links does not…. So how can I grab those? Note: !important does not work…

    You may try search here. Try to search orange, hello or page. That should give you 1 result

    • This reply was modified 1 month, 3 weeks ago by hebhansen.
    • This reply was modified 1 month, 3 weeks ago by hebhansen.
    • This reply was modified 1 month, 3 weeks ago by hebhansen.
    Plugin Author Mikko Saari

    (@msaari)

    Your theme sets the text color here:

    a:where(:not(.wp-element-button)) {
    color: var(--wp--preset--color--contrast);
    text-decoration: underline;
    }

    You need to override this. This should work:

    .relevanssi-live-search-result a {
    color: yellow;
    }

    The .relevanssi-live-search-result:a is not correct syntax, it needs to be a space, not a colon.

    Thread Starter hebhansen

    (@hebhansen)

    Perfect thx. That works.

    To whom it may concern, working css:

    /******** Search Relevanssi - Links Styling ********/
    .ajax-results .relevanssi-live-search-result a {
    color: #111111;
    font-size: inherit;
    line-height: 1rem;
    text-decoration: none;
    }

    Marked as solved

Viewing 6 replies - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.