Forums Forums Search Search Results for 'results.php'

Viewing 10 results - 751 through 760 (of 1,224 total)
  • Author
    Search Results
  • #100917

    Anonymous
    Inactive

    Thanks for the chat! I don’t seem to be able to find the results.php within the pro or free plugin?

    #100774

    Trevor
    Participant

    If you are using the shortcode method, did you follow this customization guide:

    https://www.designsandcode.com/documentation/search-filter-pro/search-results/using-a-shortcode/#Customising_the_Results

    You can then edit the copy results.php directly.

    #100161

    In reply to: How to edit the form


    Trevor
    Participant

    Can you post the results.php here? You can make it a ‘code block’ by putting a back tick before and after the code (it is the key on the left of the ‘1’ key on most keyboards:

    Snippet Key

    #100150

    In reply to: How to edit the form


    Anonymous
    Inactive

    Thanks! It works now!

    Last small problem: I am trying to edit the ‘No Results Found’ in the results.php, but if I edit it, it gives a syntax error. Link: http://www.knappekoppen.work

    #98736

    Trevor
    Participant

    OK, so, in the no-results.php template file I referred to earlier, does the no results message have that same class attached to its wrapper?

    #98612

    Trevor
    Participant

    Hi

    You would need to know which template file your theme is using. In Divi I believe it might be this file:

    /wp-content/themes/Divi/includes/no-results.php

    Have a look in there and see if that is the message you see. If so, make a little edit and check again to see if that edit is showing, and then if it is, you can set it as you want?


    Anonymous
    Inactive

    Hi, I have about 15 artists to display in the search results, and I’d like to be able to define one of the “best” or most representative pieces of art to display first for each artist, even after more posts continue to be added, so that they don’t get lost in the mix. This would be very useful in the first look at the search form, where no filters have been applied, as well as in a very broad search, where one search term results in several artists, with dozens of examples each.

    I have custom fields working in the results.php already, so the image results can link directly to the artist page defined in the custom field, like this:

    <?php
      if ( has_post_thumbnail() ) { ?>
        <span class="responsive"><a href="<?php echo get_post_meta($query->post->ID,'artistpage',true); ?>">

    It seems like I should also be able to say, “display featured results first, then display as usual.” Do you think this is possible?

    Liz

    #97262

    Trevor
    Participant

    So, on the panels at the moment they are both set to float: left;

    Are you able to past your results.php template contents here (or put it on a file sharing site like dropbox and give me the link)? If putting code here, can you put it inside back ticks (the angular quote marks on the key next to the 1 key on most keyboards)?

    #97258

    Trevor
    Participant

    Ah, but that was why I asked. In Firefox, on page opening, they (the images) are on the right.

    But, you are working with a customised results.php template, so, as I said, you need to use CSS to add a width to the panels (I would suggest 50%?).

    #97045

    Anonymous
    Inactive

    Hi, that was my mistake – I was experimenting with edits to see what effect it would have. I have made the changes you suggested, and it looks like clearfix fixed the starting grid. (Thank you!)

    However, when I click on one category, it still shows fewer results, and moves one over. When I refresh the page, the problem is fixed. See the result here:

    http://brushproject.brightartmedia.com/wp-content/uploads/2017/03/SearchResults3.jpg

    Do you have any suggestions for what has caused this error? Could it be an ajax issue?

    Current results.php:

    <?php
    /**
     * Search & Filter Pro 
     *
     * Sample Results Template
     * 
     * @package   Search_Filter
     * @author    Ross Morsali
     * @link      http://www.designsandcode.com/
     * @copyright 2015 Designs & Code
     * 
     * Note: This template has been modified to link search results 
     * images to artist pages that need to be defined in 
     * Custom Fields in the individual image post. 
     * 
     * The custom field is “artistpage” . 
     * The image in search results will incorporate the link you set  
     * for that custom field. If no link is defined, the image will
     * not link to an artist page.
     *
     * 
     *
     */
    
    if ( $query->have_posts() )
    {
    	?>
    	
    	<div class="sixteencolumns clearfix">Found <?php echo $query->found_posts; ?> Results<br />
    	Page <?php echo $query->query['paged']; ?> of <?php echo $query->max_num_pages; ?><br />
    	
    	<div class="pagination">
    		
    		<div class="nav-previous"><?php next_posts_link( 'More Murals', $query->max_num_pages ); ?></div>
    		<div class="nav-next"><?php previous_posts_link( 'Recent Murals' ); ?></div>
    		
    		
    
    		<?php
    			/* example code for using the wp_pagenavi plugin */
    			if (function_exists('wp_pagenavi'))
    			{
    				echo "<br />";
    				wp_pagenavi( array( 'query' => $query ) );
    			}
    		?>
    	</div></div>
    	
    	<?php
    	$column_count = 0;
    	$last_class = "";
    	while ($query->have_posts())
    	{
    		$query->the_post();
    
    		if ($column_count == 0) echo '<div class="sixteencolumns clearfix">';
    		?>
    		<div class="one_fourth<?php echo $last_class;?>">
    			
    		
    <?php
      if ( has_post_thumbnail() ) { ?>
        <span class="responsive"><a href="<?php echo get_post_meta($query->post->ID,'artistpage',true); ?>">
    <?php the_post_thumbnail("small");?></a></span>
      <?php	} ?>		
    		</div>
    		
    		<?php
    	 $column_count ++;
     if ($column_count == 4) {
    			$column_count = 0;
    			echo '</div>';
    			$last_class = "";
    		}
    if ($column_count == 3) {
    			$last_class = " last";
    		}
    
    				}
    
    	if ($column_count > 0) echo '</div>';
           	?>
    
    	<div class="sixteencolumns clearfix">Page <?php echo $query->query['paged']; ?> of <?php echo $query->max_num_pages; ?><br />
    	
    	<div class=“pagination">
    		
    		<div class="nav-previous"><?php next_posts_link( 'More Murals', $query->max_num_pages ); ?></div>
    		<div class="nav-next"><?php previous_posts_link( 'Recent Murals' ); ?></div>
    		<?php
    			/* example code for using the wp_pagenavi plugin */
    			if (function_exists('wp_pagenavi'))
    			{
    				echo "<br />";
    				wp_pagenavi( array( 'query' => $query ) );
    			}
    		?>
    	</div></div>
    	<?php
    }
    else
    {
    	echo "No Results Found";
    }
    ?>
Viewing 10 results - 751 through 760 (of 1,224 total)