Finally see the hide option after I reupload all the files again.
:)
Printable View
Finally see the hide option after I reupload all the files again.
:)
Hi Steven,
I installed this add-on and works well. (zen cart v1.3.7, hideCategories v1.00) Thanks!
Just minor thing that in
admin\includes\modules\category_product_listing.php
there're
Code:<?php echo '<a href="' . zen_href_link(FILENAME_STOCK_MANAGER, 'cPath=' . $cPath . '&product_type=' . $products->fields['products_type'] . '&pID=' . $products->fields['products_id'] .'&action=stock_manager' ) . '">' . zen_image(DIR_WS_IMAGES . 'icon_stock_manager.gif', ICON_STOCK_MANAGER) . '</a>'; ?>
<?php echo '<a href="' . zen_href_link(FILENAME_IMAGE_HANDLER, 'products_filter=' . $products->fields['products_id'] . '¤t_category_id=' . $current_category_id) . '">' . zen_image(DIR_WS_IMAGES . 'icon_image_handler.gif', ICON_IMAGE_HANDLER) . '</a>'; ?>
I don't use stock manager and image handler so I guess it's safe to remove these lines.
Cheers
That is correct!
I'll remove those lines in the future. They shouldn't be there.
- Steven
Nice contribution.. thanks. I was actually looking for a "members only" type of hidden category, so not exactly what I'm looking for.. Someday I'll learn enough to do this myself.
Thanks for the efforts.
Figster
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.
- Steven
Thanks S-mack, I think I even see where you would do the check.. in functions_hidecategories.php under the comment "// show based on status" a query for the customer id after log on show hidden categories. Just like that, once the log in they will be able to see the category. That's exactly what I am looking for... many others are too.
Cool! I will see if I can FIGure out how to get this added onto your contribution.. Thanks for the point in a direction!
Figster
Thanks S-mack, I think I even see where you would do the check.. in functions_hidecategories.php under the comment "// show based on status" a query for the customer id after log on show hidden categories. Just like that, once the log in they will be able to see the category. That's exactly what I am looking for... many others are too.
Cool! I will see if I can FIGure out how to get this added onto your contribution.. Thanks for the point in a direction!
Figster
Actually, I was just looking at this. Could we just add a query to the customer data base to check if logged in, if so, show hidden categories? Then we don't need the new table, and when they create the account, they are able to see the "members only" categories.. or is there something in the hidden categories that would stop this?
Thanks.
This Is a great Mod, thank you for your contribution!
Everything works great!
I was wondering if it was possible to alter a line of code somewhere to allow products to be searchable yet not listed in the "All Products link" when using "Hidden from main menus"
But, still leave the "Hidden" (Direct-link only) as it is (unsearchable/unlisted)
Figster - that's even easier! I thought you wanted only certain members to see it... not just anyone with an account.
But its not quiet as easy as you think. You'll need to make a few more changes.
Basically, you'll probably have to change every file listed in the readme (or most any of them) so that the HideCategories code is only executed if $_SESSION['customer_id'] is set. Something likehope that helps!Code:if (!$_SESSION['customer_id']) {
Dharma - Possible, yes! I'm not sure that I fully follow what you want though.
i'm sorry folks, but I don't have the time right now to customize this contrib at all. it is what it is! Code-wise, its a very simple contrib once you can wrap your head around the logic... so it should be fairly simple to customize to your needs!
Good luck! I'll poke my head in here when I can and try to lend a hand.
- Steven