hideCategories

Views: 105,228

Results 41 to 60 of 488
22 Feb 2007, 6:09 PM
#41
redheads avatar

redheads

Zen Follower

Join Date:
May 2006
Posts:
119
Plugin Contributions:
0

hideCategories

Figster:

This product sounds like it is down loadable, is it a membership fee, or do they pay by the download? What product type are you listing it under? Is the file for download stored in your zen cart media file? Do you have virtual product checked in your admin product listing, do you have Admin>configuration>Attribute Settings> Download options set correctly?
Do you have admin>configuration>sessions>prevent spider sessions set to true?
Zen cart can handle download products.
Figster

Thank you for your help brainstorming this... what a mess I have made - LOL.

Yes on all of the download options/attributes questions as well as the spider settings, that is not where the problem was. The file is stored correctly.

Here are the details on how I had set it up... just FYI for those who think this is a good idea - LOL. Do not try this at home... :lamo:

People are paying for access to the PHPBB forum, they pay by adding the item to their cart. This item is not hidden. I verify them as a person who has completed the training required to gain access, and then grant them access to the private forum which has the direct links to the goodlies we give people who have done the work. I had attempted to erase all other methods of reaching these links (direct link only). Apparently since they were still showing up in the 'people who bought this also bought' box spiders/google/non-members could get to them to - of course that did not show up in my testing as nobody had purchased these items yet. :blush:

Problem with back-door access links existing solved (I think)... now, how to set it up for those who already paid their membership and I have turned off the categories.. LOL :wacko:

Thanks to everyone for their help on this, much gratitude shooting your way!
Lori

23 Feb 2007, 12:12 AM
#42
redheads avatar

redheads

Zen Follower

Join Date:
May 2006
Posts:
119
Plugin Contributions:
0

Re: hideCategories

Ok, my temporary fix is:

1)turn off all extra boxes at the PHP level so nobody will be offered extra stuff to buy (the bad news is that I am turning them off after learning that they really DO boost sales/downloads - :ohmy: )

2)change the category IDs on every hidden category so the google cached pages give only a 'this product was not found' :lookaroun

  1. linked the sticky notes in the private PHPBB areas to the new categories :smile:

have I missed something which would keep my 'stuff' hidden until I can do a rework of the whole thing? :blink:
:-)

Lori

23 Feb 2007, 1:37 AM
#43
s_mack avatar

s_mack

Totally Zenned

Join Date:
Jun 2005
Location:
Kelowna, BC Canada
Posts:
1,033
Plugin Contributions:
4

Re: hideCategories

probably would have been easier to adjust hideCategories to apply to the "also purchased" module. I think I gave hints in the readme.

  • Steven
23 Feb 2007, 3:06 AM
#44
redheads avatar

redheads

Zen Follower

Join Date:
May 2006
Posts:
119
Plugin Contributions:
0

Re: hideCategories

s_mack:

probably would have been easier to adjust hideCategories to apply to the "also purchased" module. I think I gave hints in the readme.

  • Steven

I may have missed it somehow when I read it again earlier this morning, but now anyone who reads this thread and missed the hints in the readme knows to disable the "also purchased" module if they wish to truly hide some items :D

I followed the readme step by step and missed this important step. I am not at all upset at your insructions or the mod, and hope no offense is taken. :down:

I apparently stretched the mod uses in ways which were not forseen, and despite my disabling all of my sideboxes, all products, and search functions items appeared. :lookaroun
oops. it happens. no biggie!

I post my journey here in order to help anyone else who may get the <not so> bright idea to use this as a membership moderator. Since if I had read notes like this it would have saved me a few minutes today -- LOL. :blush:

Overall I am hoping to tweak the mod to work as I need it, as it still has the most useful set of tweaks I have found so far. :thumbsup:

Thank you for your work on this, I really do appreciate the time you have invested, and the fact that you shared it with us. :smile:

Lori

24 Feb 2007, 2:53 AM
#45
boggled avatar

boggled

Zen Follower

Join Date:
Mar 2006
Location:
Tennessee
Posts:
286
Plugin Contributions:
0

Re: hideCategories

Lori,

I don't know if this will help in your situation at all, but I'll mention it here just in case it might help someone else. :smile:

I sell on eBay and direct my customers to my website to pay via credit card.
I enter the auction item in a completely hidden category using the eBay item # as the model #. They can only put it in their cart by typing in the eBay item # on our eBay Auction Checkout page (quick order mod).

I was running into the problem of non-eBayers still finding these items and buying them since the 'add to cart' button was showing and active.

I discovered I could mark these items 'call for price' (but still enter a price) and no Add to Cart button would show. I replaced the 'call for price' button with a 'sold on eBay' button and the text to say 'already sold, etc.'

This has completely done away with 'accidental' purchases. The item still shows up in 'Others who purchased this' and my 'What's New' box, but even if they click on it, they can't buy it.

If anyone wants to see how it works, just go to my **Driftwood site**, enter **1234 ** for the item # and add to cart.

The cart is live, so please don't actually buy it! :laugh:

HTH

I'll finish that project tomorrow, I've made enough mistakes today!

24 Feb 2007, 4:19 AM
#46
redheads avatar

redheads

Zen Follower

Join Date:
May 2006
Posts:
119
Plugin Contributions:
0

Re: hideCategories

Boggled:

Lori,

I discovered I could mark these items 'call for price' (but still enter a price) and no Add to Cart button would show. I replaced the 'call for price' button with a 'sold on eBay' button and the text to say 'already sold, etc.'

hey, I like this idea, thanks for posting it -- it might just work... I add the link and item number in the forum and they can quick-order the items to their cart from there. I will play with it a bit and see where it leads! :smile:

Thanks! You Zenners are awesome! :yes:

Lori

24 Feb 2007, 3:11 PM
#47
boggled avatar

boggled

Zen Follower

Join Date:
Mar 2006
Location:
Tennessee
Posts:
286
Plugin Contributions:
0

Re: hideCategories

redheads:

hey, I like this idea, thanks for posting it -- it might just work... I add the link and item number in the forum and they can quick-order the items to their cart from there. I will play with it a bit and see where it leads! :smile:

Thanks! You Zenners are awesome! :yes:

Lori

I'm glad to finally get to help someone else instead of being the one begging for help all the time. :laugh:

Hope it works for you!

I'll finish that project tomorrow, I've made enough mistakes today!

28 Feb 2007, 10:11 PM
#48
lukemcr avatar

lukemcr

New Zenner

Join Date:
Feb 2007
Location:
Sacramento, CA
Posts:
64
Plugin Contributions:
0

Re: hideCategories

Quick question, S-mack: by the way, this mod is great.

I've installed hideCategories, but hidden categories are still showing up in the upper category listing, underneath the logo. Everything's fine in the category navigation on the left - hidden categories are staying properly hidden.

During the installation, I only manually modified one file, tpl_advanced_search.php. (I merged the changed hideCategories code with my custom tpl_advanced_search.php.) What files control the upper category navigation hidden settings?

Thanks a lot for the help!

28 Feb 2007, 10:32 PM
#49
s_mack avatar

s_mack

Totally Zenned

Join Date:
Jun 2005
Location:
Kelowna, BC Canada
Posts:
1,033
Plugin Contributions:
4

Re: hideCategories

Yeah... that's why this isn't really a clean mod :) There are potentially dozens of places that one would have to account for in order to hide the categories completely... as mentioned in the ReadMe, I just did the ones we were using - which didn't include the upper links.

I don't know what file controls that upper menu as I've never used it. See if you can find that out (by asking in a general forum or something) and report it here and someone (maybe me) should be able to figure out what code to change.

Ultimately, when I'm less busy, I'd like to re-release this contrib with an as-exhaustive-as-possible set of files... but even then, there will be 3rd-party contribs and such that will need to be modified. In other words... this was destined from the beginning to be a nightmare to support :)

It would be dead easy if the core code made thier population calls differently. If every file in the system called some common function to get the list of categories/items then we'd only have to modify that one function rather than dozens or even hundreds of files.

Oh well.

  • Steven
5 Mar 2007, 10:16 PM
#50
motas avatar

motas

New Zenner

Join Date:
Mar 2007
Posts:
9
Plugin Contributions:
0

Re: hideCategories

I use the table prefixes in my client's cart, because there are other things going on in the database, and had a problem getting this contrib to run out of the box. I found out there is a simple code fix to two files:
./includes/templates/YOUR_TEMPLATE/templates/tpl_products_all_default.php
LINE 24

	$products_all_query_raw = preg_replace('/, ' . TABLE_PRODUCTS_DESCRIPTION . ' pd(\s*)WHERE/', ' LEFT JOIN ' . TABLE_HIDE_CATEGORIES . ' h ON (p.master_categories_id = h.categories_id), ' . TABLE_PRODUCTS_DESCRIPTION . ' pd WHERE (h.visibility_status < 2 OR h.visibility_status IS NULL) AND', $products_all_query_raw);

./includes/templates/YOUR_TEMPLATE/templates/tpl_products_new_default.php
LINE 24

	$products_new_query_raw = preg_replace('/, ' . TABLE_PRODUCTS_DESCRIPTION . ' pd(\s*)WHERE/', ' LEFT JOIN ' . TABLE_HIDE_CATEGORIES . ' h ON (p.master_categories_id = h.categories_id), ' . TABLE_PRODUCTS_DESCRIPTION . ' pd WHERE (h.visibility_status < 2 OR h.visibility_status IS NULL) AND', $products_new_query_raw);

I added the second TABLE_PRODUCTS_DESCRIPTION, which was previously set to 'products_description'. In other words, it was looking for the table named products_description and not DB_PREFIX . products_description.

It was likely just a missed statement. I know someone else in this thread had posted having a problem with this.

hope that helps...
marc...

5 Mar 2007, 11:40 PM
#51
s_mack avatar

s_mack

Totally Zenned

Join Date:
Jun 2005
Location:
Kelowna, BC Canada
Posts:
1,033
Plugin Contributions:
4

Re: hideCategories

Thanks! Missed that one :)

  • Steven
7 Mar 2007, 1:03 AM
#52
motas avatar

motas

New Zenner

Join Date:
Mar 2007
Posts:
9
Plugin Contributions:
0

Re: hideCategories

No problem. I caught something else too. Is it fair to assume that FILENAME_STOCK_MANAGER and FILENAME_IMAGE_HANDLER are constants from installed modules? I am not running these modules and it appears to have messed something up in my store's admin. I changed the file:
admin/includes/modules/category_product_listing.php

I attached the file to this thread. The changes are from line 367-376. Minor, but could help someone else down the road.

cheers,
marc...

7 Mar 2007, 1:18 AM
#53
s_mack avatar

s_mack

Totally Zenned

Join Date:
Jun 2005
Location:
Kelowna, BC Canada
Posts:
1,033
Plugin Contributions:
4

Re: hideCategories

yeah, those were already covered above.

7 Mar 2007, 1:19 AM
#54
motas avatar

motas

New Zenner

Join Date:
Mar 2007
Posts:
9
Plugin Contributions:
0

Re: hideCategories

excellent. sorry about that, didn't read the full thread. my bad.

as a side note, the file I uploaded is no good. there was something else I added that I shouldn't have. please ignore it.

9 Mar 2007, 7:46 PM
#55
jvoce avatar

jvoce

New Zenner

Join Date:
Jul 2006
Location:
Toronto, ON
Posts:
87
Plugin Contributions:
0

Re: hideCategories

s_mack:

You know what... that wouldn't be a hard modification of this at all I don't think. You'd just have another table in the db that lists all the "members" by customers_id and then add one or two lines to this contrib checking to see if the current user is on the list.

I'm trying to follow up on this idea of allowing a select group members to view these hidden categories as if they were normally visable. Follow my train of thought and let me know what you think.

  1. The select group of members are placed into a "pricing group" with no discount.

  2. The functions_hideCategories.php file is edited to "//show based on status" to allow viewing based on "customers_group_pricing"

Am I out to lunch, or does anyone else think this might work?

12 Mar 2007, 12:32 PM
#56
jvoce avatar

jvoce

New Zenner

Join Date:
Jul 2006
Location:
Toronto, ON
Posts:
87
Plugin Contributions:
0

Re: hideCategories

I'm not that experienced with MySQL or PHP but would it be possible to make an exception clause in this file to compare both customer_id and customer_group_pricing?

21 Apr 2007, 4:01 PM
#58
jettrue avatar

jettrue

Totally Zenned

Join Date:
Jan 2005
Location:
USA, St. Louis
Posts:
3,651
Plugin Contributions:
5

Re: hideCategories

jettrue:

Any tips for where I should look, if a product in a completely Hidden category still shows up in the searches?

I figured out my issue, i hadn't properly uploaded includes/modules/YOUR_TEMPLATE/product_listing.php.

Another issue:

I like many others, are trying to get this to work where only certain people within a group_pricing group can see the products.

I'm testing with the includes/modules/YOUR_TEMPLATE/product_listing.php

First I tested things out by searching. With this code executed:

$listing_sql = str_replace('WHERE', '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', $listing_sql);

The item does NOT show up in the product search (as expected).

Without the above code, the item DOES show up in the product search (as expected).

So, I wrapped the above code in a conditional, like this:

$group_query = $db->Execute("select customers_group_pricing from " . TABLE_CUSTOMERS . " where customers_id = '" . (int)$_SESSION['customer_id'] . "'");
if ($group_query->fields['customers_group_pricing'] != '3') {
$listing_sql = str_replace('WHERE', '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', $listing_sql);
}

What I thought my above code is saying is: IF this customer, is not a part of group 3 (my wholesale group), then execute this code. I'm still kind of a SQL newbie, but does my above code mean that if they ARE in group 3, they WON'T see the code?

Anyway, my above code isn't working, because even when I'm logged in as a group 3 customer, when I search for the product, it isn't showing up in the search.

Any ideas of a mistake I'm making?

26 Apr 2007, 2:18 PM
#59
powah avatar

powah

New Zenner

Join Date:
Apr 2007
Posts:
11
Plugin Contributions:
0

Re: hideCategories

hi everyone..

Recently i use HideCategories contribution but now i need modify it. My goal is visible category only for certain customers. One category would be visible to one customer(s) another category visible to others certain customers and so on.
I think that I need 1 additional table in db, lets say called "hide_categories_users" wich would look something like this (with 2 columns):

hide_categories_id (int11) show_to_customers (text)

show_to_customers would be a list of customers to whom NOT to hide the category and for all other customers this category would be hidden.

Maybe **s_mack **or other people would help me by explaining how this could be done. I need to know wich files should be modified and maybe some guidelines how.

Thanx.

1 May 2007, 2:14 AM
#60
samadhi avatar

samadhi

New Zenner

Join Date:
Apr 2007
Posts:
14
Plugin Contributions:
0

Re: hideCategories

Anyone know how to resolve this? SQL query added via MySQL.

1146 Table '___.TABLE_HIDE_CATEGORIES' doesn't exist
in:
[select visibility_status FROM TABLE_HIDE_CATEGORIES WHERE categories_id = 65 LIMIT 1]

TIA!