Forums › Forums › Search & Filter Pro › Results of Search & Filter Pro in Marketify
Tagged: Results in marketify
- This topic has 25 replies, 3 voices, and was last updated 9 years, 8 months ago by Ross.
-
Anonymous(Private) February 6, 2015 at 4:12 pm #11589
Hi, I’ve got a problem with Search & and Filter PRO in Marketify theme. The results page doesn’t look like the results page of the template. I’ve put archive-download.php for the template in Sear & Filter PRO instead of search.php but the problem when I do that the result page look correctly but I’ve no results about my search. It’s about general download nothing about my query. Do you no why?
Thank you
Ross Moderator(Private) February 10, 2015 at 10:07 am #11717Hey Stephane
I’ve just added a new question to the FAQs which I think may apply to you:
http://www.designsandcode.com/wordpress-plugins/search-filter-pro/faqs/#h-bad-template
Let me know
Thanks
Anonymous(Private) February 10, 2015 at 8:20 pm #11738I’ve try everything you said in the FAQ but the results are the same. If I use search.php for the custom template the results are good but in Blog style but if I use the Marketify template I mean archive-download.php my results are all my downloads I don’t understand?
Ross Moderator(Private) February 11, 2015 at 12:28 am #11749Hi again
Just to double check, because from your description above it sounds like you did not follow the FAQ – did you duplicate
archive-download.php
, and rename it?What do you mean you did everything, did you find a custom query in your template file, and if so, did you remove it?
If anything is unclear feel free to ask questions – but its hard for me to guess what is going on, and as you say the problem lies with the template, because the other one seems to load the results fine, just not in the format you wish.
Thanks
Anonymous(Private) February 11, 2015 at 2:17 am #11753Hi! This is the archive-download.php code do you any query to remove???
<?php
/**
* The template for displaying Archive pages.
*
* Learn more: http://codex.wordpress.org/Template_Hierarchy
*
* @package Marketify
*/get_header(); ?>
<header class=”page-header”>
<h1 class=”page-title”>
<?php if ( is_tax() ) : ?>
<?php single_term_title(); ?>
<?php elseif ( is_search() ) : ?>
<?php echo esc_attr( get_search_query() ); ?>
<?php else : ?>
<?php echo apply_filters( ‘marketify_downloads_archive_title’, edd_get_label_plural() ); ?>
<?php endif; ?>
</h1>
</header><!– .page-header –><?php do_action( ‘marketify_entry_before’ ); ?>
<div class=”container”>
<?php if ( ! is_paged() && ! get_query_var( ‘m-orderby’ ) ) : ?>
<?php get_template_part( ‘content-grid-download’, ‘popular’ ); ?>
<?php endif; ?><div id=”content” class=”site-content row”>
<section id=”primary” class=”content-area col-md-<?php echo is_active_sidebar( ‘sidebar-download’ ) ? ‘9’ : ’12’; ?> col-sm-7 col-xs-12″>
<main id=”main” class=”site-main” role=”main”><div class=”section-title”><span>
<?php if ( is_search() ) : ?>
<?php printf( ‘"%s"’, esc_attr( get_search_query() ) ); ?>
<?php else : ?>
<?php marketify_downloads_section_title(); ?>
<?php endif; ?>
</span></div><?php echo do_shortcode( sprintf( ‘[downloads number=”%s”]’, get_option( ‘posts_per_page’ ) ) ); ?>
</main><!– #main –>
</section><!– #primary –><?php get_sidebar( ‘archive-download’ ); ?>
</div><!– #content –>
</div><?php get_footer(); ?>
Thank you!
Ross Moderator(Private) February 12, 2015 at 3:12 pm #11823It looks like this section is handling your loop:
“”<main id=”main” class=”site-main” role=”main"> <div class=”section-title”><span> <?php if ( is_search() ) : ?> <?php printf( ‘"%s"’, esc_attr( get_search_query() ) ); ?> <?php else : ?> <?php marketify_downloads_section_title(); ?> <?php endif; ?> </span></div> <?php echo do_shortcode( sprintf( ‘[downloads number="%s"]‘, get_option( ‘posts_per_page’ ) ) ); ?> </main><!– #main –>
more specifically the
do_shortcode
function.Try replacing the above code with standard WP loop code – so replace above with:
<main id="main" class="site-main" role="main"> <!-- Start the Loop. --> <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?> <!-- Test if the current post is in category 3. --> <!-- If it is, the div box is given the CSS class "post-cat-three". --> <!-- Otherwise, the div box is given the CSS class "post". --> <?php if ( in_category( '3' ) ) : ?> <div class="post-cat-three"> <?php else : ?> <div class="post"> <?php endif; ?> <!-- Display the Title as a link to the Post's permalink. --> <h2><a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2> <!-- Display the date (November 16th, 2009 format) and a link to other posts by this posts author. --> <small><?php the_time('F jS, Y'); ?> by <?php the_author_posts_link(); ?></small> <!-- Display the Post's content in a div box. --> <div class="entry"> <?php the_content(); ?> </div> <!-- Display a comma separated list of the Post's Categories. --> <p class="postmetadata"><?php _e( 'Posted in' ); ?> <?php the_category( ', ' ); ?></p> </div> <!-- closes the first div box --> <!-- Stop The Loop (but note the "else:" - see next line). --> <?php endwhile; else : ?> <!-- The very first "if" tested to see if there were any Posts to --> <!-- display. This "else" part tells what do if there weren't any. --> <p><?php _e( 'Sorry, no posts matched your criteria.' ); ?></p> <!-- REALLY stop The Loop. --> <?php endif; ?> </main><!– #main –>
This code is just taken from the example – http://codex.wordpress.org/The_Loop
Thanks
Ross Moderator(Private) February 12, 2015 at 3:13 pm #11825Also, did you try setting “is_search” to true? You can find this in the “advanced” tab of the settings box
-
AuthorPosts