Page 1 of 2

[vQmod] Hide Empty Categories

Posted: Wed Aug 10, 2011 12:15 am
by uksitebuilder
Simple mod that hides empty categories on front-end

Tested on 1.5.x
This mod is currently not compatible with the following mods

subcat_images
remove category counts


Working on a solution

Re: [vQmod] Hide Empty Categories

Posted: Tue Aug 30, 2011 1:31 am
by onlinephilately
Hi,

Super idea.

I have Accordion Menu installed. Any chance to use it for that mod?

Re: [vQmod] Hide Empty Categories

Posted: Tue Aug 30, 2011 3:29 pm
by uksitebuilder
Not sure what or how the accordion menu is.

However, if you look at the code in the vqmod xml, it should be quite self explanatory on what you need to do.

It basically uses conditional statements to see if category count is greater than zero.

Re: [vQmod] Hide Empty Categories

Posted: Tue Oct 25, 2011 9:55 am
by aurevilly
Thanks for this contribution.

Re: [vQmod] Hide Empty Categories

Posted: Wed Mar 14, 2012 3:51 am
by graded
uksitebuilder wrote:Simple mod that hides empty categories on front-end

Tested on 1.5.x
uksb_hide_empty_categories.xml
This mod is currently not compatible with the following mods

subcat_images
remove category counts


Working on a solution

Any chanse that you made it work with remove category counts? :)

Great VQmod!

Re: [vQmod] Hide Empty Categories

Posted: Wed Mar 28, 2012 7:00 am
by aaron1988
Same any update on a sub_images and remove category count solution please? for 1.5.1.3

Thanks
Aaron

Re: [vQmod] Hide Empty Categories

Posted: Tue Apr 17, 2012 3:29 am
by tdaubs
+1 for update to work with hidden category counts.

Re: [vQmod] Hide Empty Categories

Posted: Fri Aug 24, 2012 11:16 am
by mammax
I removed the count by removing

Code: Select all

. ' (' . $product_total . ')'
from three locations of the mod.

Looks like its still working okay.


And thanks uksitebuilder, great mod. One less job for the client.

Re: [vQmod] Hide Empty Categories

Posted: Fri Jan 25, 2013 5:53 pm
by 247shop
I am using 1.5.4 and the mod hides some of my categories that do have products in it. They are all parent categories where only the sub categories have products in them. I have another mod that shows all the product in the parent that is in the sub categories, but even after removing that the problem persists.

Is this maybe incompatible with 1.5.4?

Re: [vQmod] Hide Empty Categories

Posted: Fri Mar 29, 2013 7:30 am
by mytindahan
works fine on my 1.5.5.1

Re: [vQmod] Hide Empty Categories

Posted: Tue May 28, 2013 11:48 pm
by MikeSCC
uksitebuilder wrote:Simple mod that hides empty categories on front-end

Tested on 1.5.x
uksb_hide_empty_categories.xml
This mod is currently not compatible with the following mods

subcat_images
remove category counts


Working on a solution
Please could you advise if there is a version of this which works with version 1.5.4?

Thanks in advance,

Mike

Re: [vQmod] Hide Empty Categories

Posted: Sat Aug 03, 2013 8:41 am
by djiz
Hello I tried using the vQmod on my store its currently running 1.5.5.1 and it hides all my category including the ones with products in them is it compatible with this version?

Re: [vQmod] Hide Empty Categories

Posted: Sat Sep 07, 2013 5:44 pm
by popcorn0124
It's very very helpful!! Make shopping experience better!! :) LOVE IT and works perfect on 1.5.4.1

Re: [vQmod] Hide Empty Categories

Posted: Mon Oct 21, 2013 12:11 am
by Ljubo
1.5.3.1 and it hides all categories, empty or not.
error says:

Code: Select all

 PHP Notice:  Undefined variable: product_total in /home/.../public_html/vqmod/vqcache/vq2-catalog_controller_module_category.php on line 67
AND I HAVE FINALY MADE IT WORK.
For the first two operations in vqmod, I have put Index 1 value, but also for third operation I have changed Offset from 3 to 5 and added one closing middle bracket in modification line.

Thank you UKSB! O0

Re: [vQmod] Hide Empty Categories

Posted: Thu Jan 16, 2014 2:58 pm
by markkusz
please provide VQmod how you adjust it now, hopefuly it will work with 1.5.6

Re: [vQmod] Hide Empty Categories

Posted: Thu Jan 23, 2014 12:13 pm
by fraveton
Hi,
Syntax looks quite ok, but I am getting this error when adding the xml in OC 1.5.6:

Parse error: syntax error, unexpected T_DOUBLE_ARROW in /home/levetotc/public_html/vqmod/vqcache/vq2-catalog_controller_product_category.php on line 390

Any clue?
Thx.

Re: [vQmod] Hide Empty Categories

Posted: Sat Jan 25, 2014 2:35 pm
by byens
Hello,

it works, but it shows double main category in the top.

I am using opencart 1.5.4.1 and custome theme. Can not find what caused this.

Re: [vQmod] Hide Empty Categories

Posted: Sat Feb 01, 2014 1:14 pm
by markkusz
Please provide VQmod. We are unable to get it done manually. GREATLY APPRECIATED :)

Re: [vQmod] Hide Empty Categories

Posted: Thu Feb 20, 2014 7:46 am
by essexboyupnorth
Tiny bug, I had a category enabled but not assigned to the top menu or given a parent category and I got a:

Notice: Undefined variable: product_total in /home/*/public_html/vqmod/vqcache/vq2-catalog_controller_module_category.php on line 64

I know, why would you do that? I'm an idiot. Took me an evening to track down the error to this excellent and very useful VQMod combined with a very particular category setup.

Thanks for creating this UKSB.

Re: [vQmod] Hide Empty Categories

Posted: Mon Jun 30, 2014 11:56 pm
by joemaydew
Does this work with Sub_cat images yet ????

I would love to use this but I use sub_cat images as well