Support » Plugin: SearchWP Live Ajax Search » Using (overriding) stylesheet from template directory

  • Resolved peoy


    When updating the plugin, the stylesheet is replaced with the default one.

    Is there any way to get the plugin using a user/template stylesheet (if it exists) in place of the one supplied with the plugin ?

    I would like to place a copy of the plugin’s assets/styles/style.css in my theme directory, subfolder searchwp-live-ajax-search (as with the override for the search result template “search-results.php”) and then do my customization there.

Viewing 2 replies - 1 through 2 (of 2 total)
  • solved, and request for the next update…

    file: includes/class-form.php

            function assets() {
                    // styles
                    $custom_css_file = '/searchwp-live-ajax-search/style.css';
                    if (file_exists(get_stylesheet_directory() . $custom_css_file))
                      wp_enqueue_style( 'searchwp-live-search', get_stylesheet_directory_uri() . $custom_css_file, null, $this->version );
                      wp_enqueue_style( 'searchwp-live-search', $this->url . '/assets/styles/style.css', null, $this->version );
                    // scripts
    • This reply was modified 2 years, 1 month ago by  peoy.
    Plugin Author Jonathan Christopher


    Hi there, editing the plugin code isn’t recommended, instead there is a hook to disable the output of the styles:

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Using (overriding) stylesheet from template directory’ is closed to new replies.