hideCategories

Views: 105,228

Results 481 to 488 of 488
5 Aug 2020, 2:43 PM
#481
niccol avatar

niccol

Totally Zenned

Join Date:
Apr 2009
Posts:
2,138
Plugin Contributions:
1

hideCategories

I do not believe there is a built in function to do what you want. I'd have a look in the 'plugins' section to see if anyone has solved that already. If not then you will probably need to hire someone to write some code for you. It is not a huge job :-)

You may have more luck with this question if you start a new thread because this thread is for a particular plugin.

(is that 'Yourstore' theme?)

Nick
iszent.com

5 Aug 2020, 2:45 PM
#482
chuckrey avatar

chuckrey

Zen Follower

Join Date:
Aug 2020
Location:
Richarson
Posts:
160
Plugin Contributions:
0

Re: hideCategories

niccol:

I do not believe there is a built in function to do what you want. I'd have a look in the 'plugins' section to see if anyone has solved that already. If not then you will probably need to hire someone to write some code for you. It is not a huge job :-)

You may have more luck with this question if you start a new thread because this thread is for a particular plugin.

(is that 'Yourstore' theme?)

Thank you very much for your response. I will start a new thread. I checked the plugins but could not find anything. And Yes, that is a YourStore template.

Thank you very much!

5 Aug 2020, 11:02 PM
#483
IDEASLady avatar

IDEASLady

Totally Zenned

Join Date:
Aug 2005
Location:
Trujillo Alto, Puerto Rico
Posts:
1,449
Plugin Contributions:
3

Re: hideCategories

As a result customers must login to view prices and must be authorized to view those prices. I would like to have content exclusive to authorized customers only.

Probably Twitch Wholesale module might help you: Twitch Wholesale with Twitch Wholesale Attributes

The module will give access only to certain customers to certain categories. You can also combine it with Dual Pricing for more control on pricing for those specific customers.

We worked something similar for a customer. Any info, send PM.

IDEASLady
IDEAS Creative Studio

Your image... our business!

24 Jun 2021, 7:13 AM
#484
mshultise avatar

mshultise

Zen Follower

Join Date:
Feb 2005
Location:
Captain Cook, Hawaii
Posts:
172
Plugin Contributions:
0

Re: hideCategories

niccol:

admin/categories.php

The most recent version of this addon still contains the line ;

require(DIR_WS_MODULES . 'prod_cat_header_code.php');

> 
> I don't think recent versions (>= 1.5.6) of Zen have that file.
> 
> Attached is a version of categories.php that is working for me at the moment. Just a hacked together version of previous code in a way that doesn't conflict.  Still developing the site so I guess I may come up with other glitches.

I am running 1.5.7c and installed the downloaded ZIP files. All worked fine and I could make an existing Category hidden. However, when I tried to create a new category I got an error at the bottom of the page saying:

WARNING: An Error occurred, please refresh the page and try again.If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.

The error in my log is:

PHP Fatal error: 1064:You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'LIMIT 1' at line 4 :: select visibility_status
FROM zen_hide_categories
WHERE categories_id =
LIMIT 1 ==> (as called by) on line 419 <== in /home/www/mysite.org/store/includes/classes/db/mysql/query_factory.php on line 170.


Since I had downloaded the revised CATEGORIES.PHP mentioned in this post, I sent NICCOL a message and he replied with the following suggestion (which appears to have solved the problem).

=====

Try replacing this:

Code:

		//Begin hideCategories code
		$sql = "select visibility_status
				FROM " . TABLE_HIDE_CATEGORIES . "
				WHERE categories_id = " . $cInfo->categories_id . "
				LIMIT 1";
		$hide_status = $db->Execute($sql);
		switch ($hide_status->fields['visibility_status']) {
			case 1:
				$hide_category_normal = false;
				$hide_category_nomenu = true;
				$hide_category_hidden = false;
			break;
			case 2:
				$hide_category_normal = false;
				$hide_category_nomenu = false;
				$hide_category_hidden = true;
			break;
			default:
				$hide_category_normal = true;
				$hide_category_nomenu = false;
				$hide_category_hidden = false;
			break;
		}

With this:

Code:

    if($cInfo->categories_id > 0) {
      $sql = "select visibility_status
          FROM " . TABLE_HIDE_CATEGORIES . "
          WHERE categories_id = " . $cInfo->categories_id . "
          LIMIT 1";
      $hide_status = $db->Execute($sql);
      switch ($hide_status->fields['visibility_status']) {
        case 1:
          $hide_category_normal = false;
          $hide_category_nomenu = true;
          $hide_category_hidden = false;
        break;
        case 2:
          $hide_category_normal = false;
          $hide_category_nomenu = false;
          $hide_category_hidden = true;
        break;
        default:
          $hide_category_normal = true;
          $hide_category_nomenu = false;
          $hide_category_hidden = false;
        break;
      }      
      
    }

Aloha from Hawaii! (its a dirty job, but SOMEBODY has to live here...)

24 Jun 2021, 9:46 AM
#485
niccol avatar

niccol

Totally Zenned

Join Date:
Apr 2009
Posts:
2,138
Plugin Contributions:
1

Re: hideCategories

It should be noted that this plugin has not been updated since 2016.

I am not involved in its maintenance and have no responsibility for it.

Make your own choices people.

Nick
iszent.com

12 Nov 2021, 5:56 PM
#486
wsworx avatar

wsworx

Zen Follower

Join Date:
Jun 2012
Location:
California
Posts:
260
Plugin Contributions:
0

Re: hideCategories

Any of you ZenMasters interested in upgrading this to 1.5.7c and if so how much do you want to do it?

20 Feb 2025, 2:26 AM
#487
IDEASLady avatar

IDEASLady

Totally Zenned

Join Date:
Aug 2005
Location:
Trujillo Alto, Puerto Rico
Posts:
1,449
Plugin Contributions:
3

Re: hideCategories

Hi, I'm working on an update for this, and it's practically done, I just need few things fixed/done to pack it and upload, and I need help because I'm not a coder:

One of them is that this module uses the old folder icon images to display the folders "faded" and now since they are font-awesome icons that look opened while hovering, I don't know how to, either: change the icon color for the "hidden categories", or change the icon to something else to identify them on the list. :sadwalk:

I didn't find any documentation on the wiki about this. :blink: Can someone point me in the right direction? Maybe: @swguy @lat9 @DrByte

IDEASLady
IDEAS Creative Studio

Your image... our business!

10 Oct 2026, 12:45 AM
#488
IDEASLady avatar

IDEASLady

Totally Zenned

Join Date:
Aug 2005
Location:
Trujillo Alto, Puerto Rico
Posts:
1,449
Plugin Contributions:
3

Re: hideCategories

A new version of Hide Categories has been submitted and is pending of approval.

IDEASLady
IDEAS Creative Studio

Your image... our business!