Forums Forums Search Search Results for 'results.php'

Viewing 10 results - 221 through 230 (of 1,224 total)
  • Author
    Search Results
  • #230156

    Trevor
    Participant

    I see you are using our Shortcode method. If you want a better looking set of results, this method works well with Avada:

    https://searchandfilter.com/documentation/3rd-party/post-grid/

    However, with the Shortcode method, see here (you will need to customising section):

    https://searchandfilter.com/documentation/search-results/using-a-shortcode/

    Except, when copying the file from our plugin templates folder, copy the one for infinite scroll, and rename it to results.php

    If you do not actually edit the file, then you can leave the container settings blank, as the form by default expects you to use this template.

    #230048

    Anonymous
    Inactive

    I understand that I can copy the results.php template file to my theme and modify that. However, I’d like to modify the output of the form itself. I want to take the different sections (taxonomies) of my form and put them into tabs. How can I modify the output of the form? Thank you!

    #229731

    Trevor
    Participant

    Can you try making a test page and test form using our shortcode method, see here (you will need to customising section):

    https://searchandfilter.com/documentation/search-results/using-a-shortcode/

    Except, when copying the file from our plugin templates folder, copy the one for infinite scroll, and rename it to results.php

    Then see if the repeating post issue remains?

    #229282

    Trevor
    Participant

    I think you have placed the search form shortcode INSIDE the results.php file. This you must not do.

    You must put it here:

    https://www.screencast.com/t/63ZskfTyz9

    #228861

    In reply to: Pagination Issue


    Trevor
    Participant

    If you are using code from our results.php file, you may want to install the WP_PageNavi plugin and that should allow numbered navigation (you will see the code in the standard results.php file).

    #228836

    Trevor
    Participant

    It may be, but the root of the problem is the structure of the page template, and the way your theme works. In the end, it might be better to create a test page using our shortcode method, and then customize that to give you what you want, and then simply replace the code in your home page template with our results shortcode.

    So, to do this, follow these instructions:

    https://searchandfilter.com/documentation/search-results/using-a-shortcode/

    Including the Customizing the Results part, but for Infinite Scroll, step 2 would be this:

    2. Copy the file wp-content\plugins\search-filter\templates\results-infinite-scroll.php from the templates folder in to the newly created folder in your theme – wp-content\themes\your-theme-name\search-filter\results.php

    Notice how that file becomes named results.php

    Once that is working OK on the test page, we can then alter the code in it to output to better match your theme.

    #228509

    In reply to: REMOVE TEXT PAGINATION


    Trevor
    Participant

    If you are using our Shortcode results method, you can customise the results.php file, where the HTML structure, divs etc, can be found. See here for how:

    https://searchandfilter.com/documentation/search-results/using-a-shortcode/#customising-the-results

    The lines (#29&30) you may want to add a wrapper around at the top is this:

    Found <?php echo $query->found_posts; ?> Results<br />
    Page <?php echo $query->query['paged']; ?> of <?php echo $query->max_num_pages; ?><br />

    Maybe like this:

    <div class="top-found-post-pages"><p>Found <?php echo $query->found_posts; ?> Results</p>
    <p>Page <?php echo $query->query['paged']; ?> of <?php echo $query->max_num_pages; ?></p></div>

    And at the bottom the line is by default #73

    You can edit the file where you want and the HTML also.

    IT IS RECOMMENDED TO USE A CHILD THEME.

    You can easily make a child theme using a plugin from Orbisius. Follow the default settings and it should work. You can remove the child theme maker plugin after use.

    #228438

    Trevor
    Participant

    If you are using our Shortcode results method, you can customize the results.php file, where the HTML structure, divs etc, can be found. See here for how:

    https://searchandfilter.com/documentation/search-results/using-a-shortcode/#customising-the-results

    The line (#29) you may want to remove is this:

    Found <?php echo $query->found_posts; ?> Results<br />

    You can edit the file and messages also.

    IT IS RECOMMENDED TO USE A CHILD THEME.

    You can easily make a child theme using a plugin from Orbisius. Follow the default settings and it should work. You can remove the child theme maker plugin after use.

    #228434

    Trevor
    Participant

    You should not be adding the query into the results.php file.

    Instead use the Posts tab in the form design, and that has a sort option. Use Meta Value, select the ACF key name (make sure it DOES NOT start with an underscore) and then sort direction. See here an example:

    https://www.screencast.com/t/rVKgFNJl7FD

    Note, when you sort in this way, any post that has no value set will be excluded from the results.

    #227954

    In reply to: Only title search


    Trevor
    Participant

    Two answers.

    The title only search. You will need to follow the instructions for using the 3rd party Relevanssi plugin, here:

    https://searchandfilter.com/documentation/3rd-party/relevanssi/

    You will need to look through the Relevanssi plugin options for what it searches, and whether it searches for whole words etc. I would not recommend the relevance option in your case.

    The image to be clickable. Follow these instructions to be able to modify the results.php file:

    https://searchandfilter.com/documentation/search-results/using-a-shortcode/#customising-the-results

    In the standard results.php, see lines 56-62 (yours may now be different) for the image code:

    <?php 
    if ( has_post_thumbnail() ) {
      echo '<p>';
      the_post_thumbnail("small");
      echo '</p>';
    }
    ?>

    This would need to be changed to:

    <?php
    if ( has_post_thumbnail() ) { ?>
      <a alt="<?php esc_html(get_the_post_thumbnail_caption());?>" href="<?php the_permalink(); ?>"><?php the_post_thumbnail("medium");?></a>
    <?php	} ?>

    Notice I changed the image size also. There are many different sizes you can pick. Normally, the smallest is "thumb"

Viewing 10 results - 221 through 230 (of 1,224 total)