Zen Follower
- Join Date:
- Nov 2007
- Posts:
- 342
- Plugin Contributions:
- 0
hideCategories
Nevermind - fixed that -
One other place where my hidden category turns up is in the "Site Map" - wonder if that can be filtered out -
any ideas?
thanks
gabstero
Views: 104,787
Zen Follower
Nevermind - fixed that -
One other place where my hidden category turns up is in the "Site Map" - wonder if that can be filtered out -
any ideas?
thanks
gabstero
Totally Zenned
Is there any way to get this to work with a header dropdown navigation? Site is http://www.mypandapaws.com/shop.
I have the mod installed fine, but it apparently doesnt work with dropdowns? Please advise! THANK YOU!!!!!
New Zenner
Hi and thank you for the link to the "hide categories" module. I downloaded the module and unzipped the files but I don't know how to install it so that it's available in my ZenCart. Can you please give me some advice on that.
Totally Zenned
Gotta love the thread search!!! Glad I decided to give searching this thread a shot.. (saved me from having to pay/beg someone to help me with this!!!) I know this post is almost 1.5 years old, but this is EXACTLY what I was looking for.. I'm using the Improved SiteMap Display mod, and I needed to make the hidden products disappear!!! So if the author of this post still hangs out here.. thank you thank you thank you!!!
trebor79:
After installing the mod, I noticed that there were a few places where my hidden categories were still showing (Site Map, Customers who bought this product also purchased...).
I haven't seen any posts for solutions to hiding in Site Map & Customers who bought... sections, so I thought I'd post my ideas. I use Zen-Cart 1.3.7 too, BTW.
Here's how I stopped the categories from showing in Site Map & individual products from w/in a hidden category from being shown in Customers who bought...
Customers who bought...
go to: /includes/classes/db/mysql/define_queries.php
and find the section that starts w/ DEFINE('SQL_ALSO_PURCHASED' and make it look like this:
DEFINE('SQL_ALSO_PURCHASED', "select p.products_id, p.products_image
from " . TABLE_ORDERS_PRODUCTS . " opa, " . TABLE_ORDERS_PRODUCTS . " opb, "
. TABLE_ORDERS . " o, " . TABLE_PRODUCTS . " p LEFT JOIN "
. TABLE_HIDE_CATEGORIES . " h ON (p.master_categories_id = h.categories_id)
where (h.visibility_status < 2 OR h.visibility_status IS NULL)
and opa.products_id = '%s'
and opa.orders_id = opb.orders_id
and opb.products_id != '%s'
and opb.products_id = p.products_id
and opb.orders_id = o.orders_id
and p.products_status = 1
group by p.products_id
order by o.date_purchased desc
limit " . MAX_DISPLAY_ALSO_PURCHASED);
> go to: /includes/classes/site_map.php
> On or around line 37 (depending if you've edited this file before) & make sure it looks like this:
>
> ```
$categories_query = "select c.categories_id, cd.categories_name, c.parent_id
from " . TABLE_CATEGORIES . " c LEFT JOIN "
. TABLE_HIDE_CATEGORIES . " h ON (c.categories_id = h.categories_id), "
. TABLE_CATEGORIES_DESCRIPTION . " cd
where (h.visibility_status < 2 OR h.visibility_status IS NULL)
and c.categories_id = cd.categories_id
and cd.language_id = '" . (int)$_SESSION['languages_id'] . "'
and c.categories_status != '0'
order by c.parent_id, c.sort_order, cd.categories_name";
```These changes *should* work. Mileage may vary. Make a copy of these files & backup before editing them in case something looks screwy afterwords.
>
> I hope this is useful to someone out there.
Totally Zenned
Hi there,
Is this mod compatible with BetterCategories? I downloaded the mod and it seems it will overwrite the tpl_categories file that the BetterCategories mod is using. Any way around this?
Thx...
Totally Zenned
Like any mod... see what is being changed and modify/merge your files accordingly. If you don't know how to do that or aren't comfortable with your php skills, then the answer is "no, it isn't compatible".
Totally Zenned
Hi there,
Thanks for the reply. Just wondering, how do I add padding/spacing between each link? #categoriesContent a doesnt seem to work...
Thx...
New Zenner
gabstero:
One other place where my hidden category turns up is in the "Site Map" - wonder if that can be filtered out - any ideas?
Hear hear... Same problem here. Is there a quick fix for that?
Totally Zenned
scatzc:
Hear hear... Same problem here. Is there a quick fix for that?The solution for this is posted TWICE in this thread..
Totally Zenned
DivaVocals:
The solution for this is posted TWICE in this thread..
Thank you.
New Zenner
DivaVocals:
The solution for this is posted TWICE in this thread..
Thanks are you referring to this?
http://www.zen-cart.com/forum/showpost.php?p=753742&postcount=224
New Zenner
OK I think that I found it:
http://www.zen-cart.com/forum/showpost.php?p=466332&postcount=94
It turns out that I was using the wrong keyword in the Thread Search: It should be "site map", not "sitemap".
Totally Zenned
scatzc:
OK I think that I found it:
http://www.zen-cart.com/forum/showpost.php?p=466332&postcount=94It turns out that I was using the wrong keyword in the Thread Search: It should be "site map", not "sitemap".Ummmm okay..:blink:
FYI.. Dunno if you noticed, but this thread is quoted in the post you just asked about earlier..:huh:
Zen Follower
I am using the css_horizontal_dynamic_menu mod, how do i make the hidden categories mod work with the css_horizontal_dynamic_menu mod. I have followed the instruction with the Hidden categories mod however the category that i want to hide still shows up. Any idea?
Totally Zenned
lextechs:
I am using the css_horizontal_dynamic_menu mod, how do i make the hidden categories mod work with the css_horizontal_dynamic_menu mod. I have followed the instruction with the Hidden categories mod however the category that i want to hide still shows up. Any idea?This is probably best asked in the support thread for the menu mod, but you would have to take a look at the query that drives the categories in the menu and adjust it so that it excludes the hidden categories..
Zen Follower
DivaVocals:
This is probably best asked in the support thread for the menu mod, but you would have to take a look at the query that drives the categories in the menu and adjust it so that it excludes the hidden categories..
I do not want to double post the question, is anyone using both these mod together.
Totally Zenned
So if you go to these links you get the errors in the queries as shown:
http://www **dot **hairisle **dot **com/products_new
Quote:
> 1054 Unknown column 'p.master_categories_id' in 'on clause'
in:
[select count(p.products_id) as total FROM zen_products p LEFT JOIN zen_manufacturers m ON (p.manufacturers_id = m.manufacturers_id), zen_products_description pd LEFT JOIN zen_hide_categories h ON (p.master_categories_id = h.categories_id) WHERE (h.visibility_status < 2 OR h.visibility_status IS NULL) AND p.products_status = 1 AND p.products_id = pd.products_id AND pd.language_id = 1 ]http://www** dot **hairisle **dot **com/products_all
Quote:
> 1054 Unknown column 'p.master_categories_id' in 'on clause'
in:
[select count(p.products_id) as total FROM zen_products p LEFT JOIN zen_manufacturers m ON (p.manufacturers_id = m.manufacturers_id), zen_products_description pd LEFT JOIN zen_hide_categories h ON (p.master_categories_id = h.categories_id) WHERE (h.visibility_status < 2 OR h.visibility_status IS NULL) AND p.products_status = 1 AND p.products_id = pd.products_id AND pd.language_id = 1 ]This did not occur on the dev site as you can see:
http://clients **dot **overthehillweb **dot **com/hairisle/products_new
http://clients **dot **overthehillweb dot com/hairisle/products_all
I've been doing a LOT of searching of this forum and Googling, and my research indicates that this might be an issue with the on clause of the left join.. This post was very helpful in nundging me inthe right direction. It reads in part:
http://www.zen-cart.com/forum/showpo...47&postcount=6
Quote:
> The real culprit is Mysql data base queries. Once your host upgrade sql database to 5.x, you need to fix your sql queries...So I took a look at both dev and the live site and yes indeed they are on different versions of mySQL. (thought my server was running 5.x.. it's not... I'll deal with that later this week)
DB Versions:
hairisle dot com - Database: MySQL 5.0.81-community-log
clients dot overthehillweb dot com/hairisle - Database: MySQL 4.1.22-max-log
So I think I have a grasp on WHAT the issue is, and if I can get some assistance to what the corrected syntax for these queries should be, I should be good to go in correcting the queries for these pages..
I am hoping a s_mack can pop in to help.. YES I read other threads on this error.. Unfortunately the queries are different, and I can't make the leap to figure out how to correct the syntax of this query based on some of the other threads.. Hope someone will take pity on me and help..
Totally Zenned
Please see this post for the solution I am trying out to resolve the mySQL v5 issue: http://www.zen-cart.com/forum/showpost.php?p=797128&postcount=14
If you want to read this full thread:
http://www.zen-cart.com/forum/showthread.php?t=139864
I'm still testing to make sure this doesn't break other aspects of the hideCategories add-on. So far so good.. Your mileage may vary..:smile: I also plan to test if this "fix" will work with mySQL v4.x as well.. If I get a different result, I will share those findings as well.
DivaVocals:
So if you go to these links you get the errors in the queries as shown:
http://www **dot **hairisle **dot com/products_new
Quote:
http://www dot **hairisle **dot **com/products_all
Quote:
This did not occur on the dev site as you can see:
http://clients **dot **overthehillweb **dot **com/hairisle/products_new
http://clients **dot **overthehillweb dot com/hairisle/products_allI've been doing a LOT of searching of this forum and Googling, and my research indicates that this might be an issue with the on clause of the left join.. This post was very helpful in nundging me inthe right direction. It reads in part:
http://www.zen-cart.com/forum/showpo...47&postcount=6
Quote:
So I took a look at both dev and the live site and yes indeed they are on different versions of mySQL. (thought my server was running 5.x.. it's not... I'll deal with that later this week)DB Versions:
hairisle dot com - Database: MySQL 5.0.81-community-log
clients dot overthehillweb dot com/hairisle - Database: MySQL 4.1.22-max-logSo I think I have a grasp on WHAT the issue is, and if I can get some assistance to what the corrected syntax for these queries should be, I should be good to go in correcting the queries for these pages..
I am hoping a s_mack can pop in to help.. YES I read other threads on this error.. Unfortunately the queries are different, and I can't make the leap to figure out how to correct the syntax of this query based on some of the other threads.. Hope someone will take pity on me and help..
Totally Zenned
Nope, can't help. Sorry.
I'm no MySQL expert by any stretch of the imagination and I have no idea what's up with your situation. Best of luck though.
Totally Zenned
s_mack:
Nope, can't help. Sorry.
I'm no MySQL expert by any stretch of the imagination and I have no idea what's up with your situation. Best of luck though.Not a problem.. It's a mySQL v5.x compatibility issue with one of the queries in this add-on..
See my post above yours.. I am already working out testing a fix which appears to have resolved the issue.. Looks like one file contained the second left join statement which caused the query to fail (hence the error message). Thanks to DrByte and a friend who both pointed out that this was the cause for the error, I searched the code and found where the second left join was coming from.. Gonna test on mySQL v4.x as well since as I understand things the second left join isn't needed anyway..
Fields marked required must be completed.
Tell staff why this post should be reviewed.
Required for login, security, and core site functionality.
Help us understand how the site is used so we can improve it.
Used for promotion and personalized campaign measurement.