Datafeedr Support Forums  

Go Back   Datafeedr Support Forums > Current Version (V3) Forum > Questions
Home Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Important - The support forums are now in "read-only" mode as we transition to an alternative help desk solution. Feel free to contact us here with any of your questions or search the forums for an existing solution.
 
 
Thread Tools Search this Thread Display Modes
  #1  
Old October 30th, 2014, 06:12 PM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default search results filterable?

http://saveongolf.net

Hi,
When I search for a term on my site, say "Ping g30 hybrid" , I get pretty good results. However when I used the sort by widget to try and put those results in order from low to high price it doesn't work. It gives me results from the entire site.

Is there a way to filter search results obtained from the search bar?
  #2  
Old October 30th, 2014, 08:24 PM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

Hi,

Search results are returned in order of relevance only.

Eric
  #3  
Old October 31st, 2014, 06:55 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

so once you have the search results you can't filter them further?...say by price?
  #4  
Old October 31st, 2014, 07:15 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

If that is the case, I guess I should remove the "filter by" and "number of page results" widget on the search results page, right? Is that what makes the most sense. Right now if I get results then try to increase the number of results per page or filter them at all it gives results from the entire site. So if search results are a one shot deal, can you show me in my code below exactly what to remove? Thanks

HTML Code:
<style type="text/css">.desc img {float:left;}</style>


<!-- Search Heading -->
<h2>Your Search Results:</h2>
<!-- /Search Heading -->


<!-- Search Fields -->
<ul>
  <?php if (@$_GET['word']){ ?><li><b>Word: </b>[store.get param="word"]</li><?php } ?>
  <?php if (@$_GET['merchant']){ ?><li><b>Merchant: </b>[store.get param="merchant"]</li><?php } ?>
  <?php if (@$_GET['tags']){ ?><li><b>Tags: </b>[store.get param="tags"]</li><?php } ?>
  <?php if (@$_GET['price']){ ?><li><b>Price: </b>[store.get param="price"]</li><?php } ?>
</ul>
<!-- /Search Fields -->


<div class="dffltrs">
  <form method="get">
    <span class="dflside">
      Products per page:
      <?php echo datafeedr_tools()->form_select("ppp",
        array(
        "16" => "16",
        "32" => "32",
        "56" => "56",
        "80" => "80",
        )); ?>
    </span>
    <span class="dfrside">
      Sort by:
      <?php echo datafeedr_tools()->form_select("sort",
        array(
          "-views" => "Views (high to low)",
          "views" => "Views (low to high)",                    
        "sprice"   => "Price (low to high)",
        "-sprice"   => "Price (high to low)",
        "name"     => "Product Name (a - z)",
        "-name"   => "Product Name (z - a)",
          "random"   => "Random",
        )); ?>
      <input type="submit" value="Go" class="dfsbmt" />
    </span>
    <div class="clearingdiv">&nbsp;</div>
    <?php
    if ( isset( $_GET['name'] ) ) {
      echo '<input type="hidden" name="name" value="' . $_GET['name'] . '" />';
    }
    ?>
  </form>
</div>


<!-- Pagination Links (Top) -->
<div class="pgr">
  Pages:
  [pager.first text='<img src="[server.plugin_url]/first.gif" alt="first page" />' alt='']
  [pager.prev text='<img src="[server.plugin_url]/prev.gif" alt="prev page" />' alt='']
  [pager.pages delim=' ']
  [pager.next text='<img src="[server.plugin_url]/next.gif" alt="next page" />' alt='']
  [pager.last text='<img src="[server.plugin_url]/last.gif" alt="last page" />' alt='']
</div>
<!-- /Pagination Links (Top) -->

<!-- Product List -->
   <ul class="products grid">
<div class="pl">
  [product.each]
  <div class="t1 col4">
  <div class="bdr">
    <h2><a href="[product.link]" title="[product.name]">[product.name]</a></h2>
    <div class="thmb"><a href="[product.link]" title="[product.name]">[product.thumbnail tag='1']</a></div>   
    
    
    <?php if ($product->saleprice > 0 &&  $product->saleprice < $product->price) { ?>
  <div class="prc">
    <small>
      <span style="text-decoration: line-through;">[product.currency mode='sign'][product.price]</span>
      <span style="font-weight: bold; color:red;">[product.currency mode='sign'][product.saleprice]</span>
    </small>
  </div>
<?php } else { ?>
  <div class="prc">
    <small>
      [product.currency mode='sign'][product.price]
    </small>
  </div>    
<?php } ?>
    <p class="desc">[product.description]</p>
    <div class="logo">[product.merchant_logo]</div>
    <div class="btns">
    <?php if ( $product->compset_status > 0 ) : ?>
  <a href="[product.link]" class="dfbutton dforange dfmedium dfrounded" title="Find the best price for [product.name]">Compare Prices</a>
<?php else : ?>
  <a href="[product.link]" class="dfbutton dfgreen dfmedium dfrounded" title="View details of [product.name]">Details</a>
<?php endif; ?>
    </div>
    <div class="clearingdiv"> </div>
  </div>
  </div>
  [/product.each]
  <div class="clearingdiv"> </div>
</div>
</ul>
<!-- /Product List -->


<!-- Search Results -->

<!-- /Search Results -->
<!-- Pagination Links (Bottom) -->
<div class="pgr">
  Pages:
  [pager.first text='<img src="[server.plugin_url]/first.gif" alt="first page" />' alt='']
  [pager.prev text='<img src="[server.plugin_url]/prev.gif" alt="prev page" />' alt='']
  [pager.pages delim=' ']
  [pager.next text='<img src="[server.plugin_url]/next.gif" alt="next page" />' alt='']
  [pager.last text='<img src="[server.plugin_url]/last.gif" alt="last page" />' alt='']
</div>
<!-- /Pagination Links (Bottom) -->
  #5  
Old October 31st, 2014, 09:15 AM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

Hi,

Here's the code you need:

HTML Code:
<style type="text/css">.desc img {float:left;}</style>

<!-- Search Heading -->
<h2>Your Search Results:</h2>
<!-- /Search Heading -->

<!-- Search Fields -->
<ul>
  <?php if (@$_GET['word']){ ?><li><b>Word: </b>[store.get param="word"]</li><?php } ?>
  <?php if (@$_GET['merchant']){ ?><li><b>Merchant: </b>[store.get param="merchant"]</li><?php } ?>
  <?php if (@$_GET['tags']){ ?><li><b>Tags: </b>[store.get param="tags"]</li><?php } ?>
  <?php if (@$_GET['price']){ ?><li><b>Price: </b>[store.get param="price"]</li><?php } ?>
</ul>
<!-- /Search Fields -->

<!-- Pagination Links (Top) -->
<div class="pgr">
  Pages:
  [pager.first text='<img src="[server.plugin_url]/first.gif" alt="first page" />' alt='']
  [pager.prev text='<img src="[server.plugin_url]/prev.gif" alt="prev page" />' alt='']
  [pager.pages delim=' ']
  [pager.next text='<img src="[server.plugin_url]/next.gif" alt="next page" />' alt='']
  [pager.last text='<img src="[server.plugin_url]/last.gif" alt="last page" />' alt='']
</div>
<!-- /Pagination Links (Top) -->

<!-- Product List -->
   <ul class="products grid">
<div class="pl">
  [product.each]
  <div class="t1 col4">
  <div class="bdr">
    <h2><a href="[product.link]" title="[product.name]">[product.name]</a></h2>
    <div class="thmb"><a href="[product.link]" title="[product.name]">[product.thumbnail tag='1']</a></div>   
    
    
    <?php if ($product->saleprice > 0 &&  $product->saleprice < $product->price) { ?>
  <div class="prc">
    <small>
      <span style="text-decoration: line-through;">[product.currency mode='sign'][product.price]</span>
      <span style="font-weight: bold; color:red;">[product.currency mode='sign'][product.saleprice]</span>
    </small>
  </div>
<?php } else { ?>
  <div class="prc">
    <small>
      [product.currency mode='sign'][product.price]
    </small>
  </div>    
<?php } ?>
    <p class="desc">[product.description]</p>
    <div class="logo">[product.merchant_logo]</div>
    <div class="btns">
    <?php if ( $product->compset_status > 0 ) : ?>
  <a href="[product.link]" class="dfbutton dforange dfmedium dfrounded" title="Find the best price for [product.name]">Compare Prices</a>
<?php else : ?>
  <a href="[product.link]" class="dfbutton dfgreen dfmedium dfrounded" title="View details of [product.name]">Details</a>
<?php endif; ?>
    </div>
    <div class="clearingdiv"> </div>
  </div>
  </div>
  [/product.each]
  <div class="clearingdiv"> </div>
</div>
</ul>
<!-- /Product List -->

<!-- Pagination Links (Bottom) -->
<div class="pgr">
  Pages:
  [pager.first text='<img src="[server.plugin_url]/first.gif" alt="first page" />' alt='']
  [pager.prev text='<img src="[server.plugin_url]/prev.gif" alt="prev page" />' alt='']
  [pager.pages delim=' ']
  [pager.next text='<img src="[server.plugin_url]/next.gif" alt="next page" />' alt='']
  [pager.last text='<img src="[server.plugin_url]/last.gif" alt="last page" />' alt='']
</div>
<!-- /Pagination Links (Bottom) -->
Eric
  #6  
Old October 31st, 2014, 10:21 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

Eric,

if I want the search bar to search the product title and not the description, how do I do that? Right now I'm getting a lot of irrelevant results mixed in.
  #7  
Old October 31st, 2014, 10:26 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

Do I have this set correctly to search by relevance?
Attached Thumbnails
Click image for larger version

Name:	search settings..JPG
Views:	110
Size:	64.6 KB
ID:	827  
  #8  
Old October 31st, 2014, 10:32 AM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

Hi
Quote:
Originally Posted by yankeestonk View Post
if I want the search bar to search the product title and not the description, how do I do that? Right now I'm getting a lot of irrelevant results mixed in.
You need to change name="word" to name="name" in your search form. However there are limitations to doing this.

Quote:
Originally Posted by yankeestonk View Post
Do I have this set correctly to search by relevance?
The sort setting is ignored on the Search page.
  #9  
Old October 31st, 2014, 10:43 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

Thanks Eric!

last question on this... The problem I'm having is that it is searching the description, when I need it to search just the title. (when I search for "golf bag" it returns a lot of products that do not have the word golf bag in the title) Can I make it search just the title?

Nevermind. You answered this above. I misunderstood.

Last edited by yankeestonk : October 31st, 2014 at 10:44 AM. Reason: nevermind
  #10  
Old October 31st, 2014, 10:49 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

do I change both to "name"?
Attached Thumbnails
Click image for larger version

Name:	name.JPG
Views:	104
Size:	128.5 KB
ID:	828  
  #11  
Old October 31st, 2014, 10:51 AM
Eric's Avatar
Eric Eric is offline
Datafeedr Team
 
Join Date: Feb 2008
Posts: 16,902
Default

Hi,

Almost...



Eric
  #12  
Old October 31st, 2014, 10:59 AM
yankeestonk yankeestonk is offline
 
Join Date: Jun 2013
Posts: 605
Default

Thank you.
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Price In the search results vijjus2 Questions 1 August 11th, 2013 09:09 AM
bad search results Michaelgs Questions 1 December 1st, 2012 02:16 PM
? search results with pagination Task001 Questions 2 May 16th, 2012 03:14 PM


All times are GMT -5. The time now is 05:40 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2021, Jelsoft Enterprises Ltd.