Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Contribution] Match Categories in Search Results for osCommerce versions 2.3.x


auzStar

Recommended Posts

Support Thread for Match Categories in Search Results for osCommerce versions 2.3.x

 

Report problems here.

 

I will monitor this thread and try to answer as many questions as I can.

 

Feedback and comments appreciated.

 

 

Download link:

http://addons.oscommerce.com/info/9197
 

 

Dom

Edited by auzStar

My Add-ons
Advanced Cache Control Tool for osCommerce 2.3.x (non-bootstrap) Download Support
Ajax Product Listing for osC 2.3.4 (bootstrap) Download Support
Category New Products Carousel for osC 2.3.4 (bootstrap) Download Support
Category Popular Products Carousel for osC 2.3.4 (bootstrap) Download Support
Customer Testimonials for osCommerce 2.3.4 (bootstrap and non-bootstrap) Download Support
Front Page New Products Carousel for osC 2.3.4 (bootstrap) Download Support

Index Nested - Product Listing for osC 2.3.4 (bootstrapDownload Support
Match Categories in Search Results for osCommerce versions 2.3.x (non-bootstrap) Download Support
Modular Category Page for osC 2.3.4 (bootstrap)
Download Support

NEW Australia Post Shipping Modules for osCommerce 2.3.x (non-bootstrap) Download Support
NEW Equal Height Module for osC 2.3.4 (bootstrapDownload Support
Products Low Stock Report for osC 2.3.x (bootstrap and non-bootstrap) Download Support
Twitter Typeahead Autocomplete Search for osCommerce 2.3.4 (bootstrap and non-bootstrap)
Download Support

Upcoming Products Modules for osC 2.3.4 (bootstrap) Download Support

 
Assisted Add-ons
Scroll Boxes for osCommerce 2.3.x (bootstrap and non-bootstrap) Download Support
 
Bootstrap Add-ons created by other members
osCommerce Bootstrap Addons and Code

Link to comment
Share on other sites

  • 2 weeks later...

@@Hostecom

 

Hi John,

 

Thanks for testing and feedback.

 

Could you please post the changes you made to the tables. May help others.

 

cheers

My Add-ons
Advanced Cache Control Tool for osCommerce 2.3.x (non-bootstrap) Download Support
Ajax Product Listing for osC 2.3.4 (bootstrap) Download Support
Category New Products Carousel for osC 2.3.4 (bootstrap) Download Support
Category Popular Products Carousel for osC 2.3.4 (bootstrap) Download Support
Customer Testimonials for osCommerce 2.3.4 (bootstrap and non-bootstrap) Download Support
Front Page New Products Carousel for osC 2.3.4 (bootstrap) Download Support

Index Nested - Product Listing for osC 2.3.4 (bootstrapDownload Support
Match Categories in Search Results for osCommerce versions 2.3.x (non-bootstrap) Download Support
Modular Category Page for osC 2.3.4 (bootstrap)
Download Support

NEW Australia Post Shipping Modules for osCommerce 2.3.x (non-bootstrap) Download Support
NEW Equal Height Module for osC 2.3.4 (bootstrapDownload Support
Products Low Stock Report for osC 2.3.x (bootstrap and non-bootstrap) Download Support
Twitter Typeahead Autocomplete Search for osCommerce 2.3.4 (bootstrap and non-bootstrap)
Download Support

Upcoming Products Modules for osC 2.3.4 (bootstrap) Download Support

 
Assisted Add-ons
Scroll Boxes for osCommerce 2.3.x (bootstrap and non-bootstrap) Download Support
 
Bootstrap Add-ons created by other members
osCommerce Bootstrap Addons and Code

Link to comment
Share on other sites

Hi, sure:

 

 

step 1

 
FIND AROUND LINE 133 to 135:
 
<h1><?php echo HEADING_TITLE_2; ?></h1>
 
<div class="contentContainer">
 
 
REPLACE WITH ALL THE CODE BELOW:
 
<div class="contentContainer">
 
<!-- begin Match Categories in Search Results -->
<?php
  if ((ENABLE_CATEGORY_LIST_IN_SEARCH == 'true' && ((ENABLE_CATEGORY_LIST_USER_CONTROL == 'false') || (isset($HTTP_GET_VARS['cat_search']) && $HTTP_GET_VARS['cat_search'] == '1') || (isset($HTTP_GET_VARS['cat_only']) && $HTTP_GET_VARS['cat_only'] == '1')) && (!isset($HTTP_GET_VARS['page']) || $HTTP_GET_VARS['page'] == '1')) || (ENABLE_CATEGORY_LIST_IN_SEARCH == 'true' && ENABLE_CATEGORY_SEARCH_ONLY == 'true')) {
    include('category_search_result.php');
  }
 
  if ((ENABLE_CATEGORY_LIST_IN_SEARCH == 'false' || ENABLE_CATEGORY_SEARCH_ONLY == 'false') && (!isset($HTTP_GET_VARS['cat_only']) || $HTTP_GET_VARS['cat_only'] != '1')) {
?>
<!-- end Match Categories in Search Results -->
 
<h1><?php echo HEADING_TITLE_2; ?></h1>

 

just changed to:

 

 

step 1

 
FIND AROUND LINE 133 to 135:
 
<h1><?php echo HEADING_TITLE_2; ?></h1>
 
<div class="contentContainer">
 
 
REPLACE WITH ALL THE CODE BELOW:
 
          <tr>
          <td>
<!-- begin Match Categories in Search Results -->
<?php
  if ((ENABLE_CATEGORY_LIST_IN_SEARCH == 'true' && ((ENABLE_CATEGORY_LIST_USER_CONTROL == 'false') || (isset($HTTP_GET_VARS['cat_search']) && $HTTP_GET_VARS['cat_search'] == '1') || (isset($HTTP_GET_VARS['cat_only']) && $HTTP_GET_VARS['cat_only'] == '1')) && (!isset($HTTP_GET_VARS['page']) || $HTTP_GET_VARS['page'] == '1')) || (ENABLE_CATEGORY_LIST_IN_SEARCH == 'true' && ENABLE_CATEGORY_SEARCH_ONLY == 'true')) {
    include('category_search_result.php');
  }
 
  if ((ENABLE_CATEGORY_LIST_IN_SEARCH == 'false' || ENABLE_CATEGORY_SEARCH_ONLY == 'false') && (!isset($HTTP_GET_VARS['cat_only']) || $HTTP_GET_VARS['cat_only'] != '1')) {
?>
</td></tr>

 

Some classes from stylesheet.css located in files are different from my version, but its very easy to customize the results. Without this stylesheet changes the result still show right, uses table default styles. 

 

Thanks to your module my search now has new life :)

Link to comment
Share on other sites

  • 6 months later...

Hi

Firstly thanks for this amazing Mod you have created...

I am getting the below error on installing this mod on the advanced search result page-

 

1054 - Unknown column 'c.categories_status' in 'where clause'

select c.categories_id, cd.categories_name from categories c left join categories_description cd on c.categories_id = cd.categories_id where c.categories_status = 1 and cd.language_id = '1' and ((cd.categories_name like '%flute%') ) order by categories_name

 

Your help will be deeply appreciated...

Link to comment
Share on other sites

just remove

 

c.categories_status = 1 and

 

from the sql where clause and you should be fine.

 

it is a field that comes from a enable/disable categories contribution

KEEP CALM AND CARRY ON

I do not use the responsive bootstrap version since i coded my responsive version earlier, but i have bought every 28d of code package to support burts effort and keep this forum alive (albeit more like on life support).

So if you are still here ? What are you waiting for ?!

 

Find the most frequent unique errors to fix:

grep "PHP" php_error_log.txt | sed "s/^.* PHP/PHP/g" |grep "line" |sort | uniq -c | sort -r > counterrors.txt

Link to comment
Share on other sites

@@radhavallabh

@@bruyndoncx

 

Hi guys, sorry I've only just seen this now.

 

There's no need to alter the sql statement. In "admin->configuration->categories search" set Don't show hidden categories to false.

 

That option is there for the "Hidden Categories" add-on, if you have it installed, to allow you to include/exclude hidden categories from search results. i.e. if that add-on is installed, set the above option to true to control whether or not to hide categories which have been set for each category via the "Hidden Categories" add-on. If the "Hidden Categories" add-on is not installed then set it to false. (If set to false and the "Hidden Categories" add-on is installed then hidden categories will still be seen in search results regardless of whether they are hidden or not) 

 

If you don't have that add-on installed you set this option to false. It's mentioned in the install documentation.

 

cheers

 

My Add-ons
Advanced Cache Control Tool for osCommerce 2.3.x (non-bootstrap) Download Support
Ajax Product Listing for osC 2.3.4 (bootstrap) Download Support
Category New Products Carousel for osC 2.3.4 (bootstrap) Download Support
Category Popular Products Carousel for osC 2.3.4 (bootstrap) Download Support
Customer Testimonials for osCommerce 2.3.4 (bootstrap and non-bootstrap) Download Support
Front Page New Products Carousel for osC 2.3.4 (bootstrap) Download Support

Index Nested - Product Listing for osC 2.3.4 (bootstrapDownload Support
Match Categories in Search Results for osCommerce versions 2.3.x (non-bootstrap) Download Support
Modular Category Page for osC 2.3.4 (bootstrap)
Download Support

NEW Australia Post Shipping Modules for osCommerce 2.3.x (non-bootstrap) Download Support
NEW Equal Height Module for osC 2.3.4 (bootstrapDownload Support
Products Low Stock Report for osC 2.3.x (bootstrap and non-bootstrap) Download Support
Twitter Typeahead Autocomplete Search for osCommerce 2.3.4 (bootstrap and non-bootstrap)
Download Support

Upcoming Products Modules for osC 2.3.4 (bootstrap) Download Support

 
Assisted Add-ons
Scroll Boxes for osCommerce 2.3.x (bootstrap and non-bootstrap) Download Support
 
Bootstrap Add-ons created by other members
osCommerce Bootstrap Addons and Code

Link to comment
Share on other sites

@@radhavallabh

 

If you have the "Hidden Categories" add-on installed then you should have a "categories_status" field in the "categories" table, because the "Match Categories in Search Results" add-on relies on this when the setting Don't show hidden categories is set to true. If "categories_status" field is not used in the "categories" table, then there is some info in the install doco on how to modify the files.

 

cheers

 

My Add-ons
Advanced Cache Control Tool for osCommerce 2.3.x (non-bootstrap) Download Support
Ajax Product Listing for osC 2.3.4 (bootstrap) Download Support
Category New Products Carousel for osC 2.3.4 (bootstrap) Download Support
Category Popular Products Carousel for osC 2.3.4 (bootstrap) Download Support
Customer Testimonials for osCommerce 2.3.4 (bootstrap and non-bootstrap) Download Support
Front Page New Products Carousel for osC 2.3.4 (bootstrap) Download Support

Index Nested - Product Listing for osC 2.3.4 (bootstrapDownload Support
Match Categories in Search Results for osCommerce versions 2.3.x (non-bootstrap) Download Support
Modular Category Page for osC 2.3.4 (bootstrap)
Download Support

NEW Australia Post Shipping Modules for osCommerce 2.3.x (non-bootstrap) Download Support
NEW Equal Height Module for osC 2.3.4 (bootstrapDownload Support
Products Low Stock Report for osC 2.3.x (bootstrap and non-bootstrap) Download Support
Twitter Typeahead Autocomplete Search for osCommerce 2.3.4 (bootstrap and non-bootstrap)
Download Support

Upcoming Products Modules for osC 2.3.4 (bootstrap) Download Support

 
Assisted Add-ons
Scroll Boxes for osCommerce 2.3.x (bootstrap and non-bootstrap) Download Support
 
Bootstrap Add-ons created by other members
osCommerce Bootstrap Addons and Code

Link to comment
Share on other sites

  • 2 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...