I have also now imported the sql with phpadmin still the same result. No change in store admin catagories when you go to edit.
If anyone has run across this please give me a clue as to what I need to do to make this work?
Thanks in advance,
Suzanne![]()
I have also now imported the sql with phpadmin still the same result. No change in store admin catagories when you go to edit.
If anyone has run across this please give me a clue as to what I need to do to make this work?
Thanks in advance,
Suzanne![]()
I'm going to stop posting, LOL. Every time I finally get to the point where I ask for help I find out what I have done wrong just a little while later.
It helps If you put the files where the directions tell you too.
Sorry for posting out of stupidness.
Suzanne![]()
I just installed this and it does work great! However it does overwrite product_listing.php which is also used for the Column Layout Grid mod. I love these both and have tried to winmerge them but it still messes with the Column Layout Grid.
Can anyone tell me how to fix the issue?
I just don't know enough to fix something like this. I would love to use both of these contributions but as it stands now i guess I'm going to have to make a choice between them.
Suzanne
This thread truly is not the place to troubleshoot what really amounts to something that is NOT an issue with this mod at all, but an issue with HOW to properly merge the files this mod and another mod have in common.. If you are unable to correctly make the changes, my suggestion is to give some thought to paying someone to help you with this file merge and be done with it.. Otherwise you will have to decide between the two mods..![]()
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.
Hi Im using Hide Categories 2.0 and I use it to hide all the category folders BUT I would still like to allow the normal zencart search option.
Would it be difficult to modify the code to allow the searching and where would I start :)
Great contribution by the way...
Hi Guys,
Hide Categories is just what we need to be able to manage the update of huge numbers of products from multiple vendors and hide new categories while they are being worked on. I see that several sideboxes have been fixed so that hide categories will work with them. I need to try to make it work with the CSS dropdown menu and the CSS flyout menu.
After looking the files up and down, I have determined that the file in classes called category_ul_generator.php (which is used by both mods) is where the hide categories code should be inserted, but I am having a hard time getting it to work.
The file appears to run through the list of categories from the database in a while loop. A series of conditionals determines whether it is a upper listing or a list item, then it builds a list with the ul and li tags programmatically inserted.
I guess I need to rewrite the existing query to the database:
function zen_categories_ul_generator() {
global $languages_id, $db, $request_type;
$this->server = ((ENABLE_SSL == true && $request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER);
$this->base_href = ((ENABLE_SSL == true && $request_type == 'SSL') ? DIR_WS_HTTPS_CATALOG : DIR_WS_CATALOG);
$this->data = array();
$categories_query = "select c.categories_id, cd.categories_name, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd " .
"where c.categories_id = cd.categories_id and c.categories_status=1 and cd.language_id = '" . (int)$_SESSION['languages_id'] . "'" .
"order by c.parent_id, c.sort_order, cd.categories_name";
$categories = $db->Execute($categories_query);
To indclude the info requested by the hide categories query:
list($nada, $mycpath)= split('=', $box_categories_array[$i]['path']);
$mycid = split('_', $mycpath);
$categories_id = array_pop($mycid);
$hide_status = $db->Execute("select visibility_status
FROM " . TABLE_HIDE_CATEGORIES . "
WHERE categories_id = " . $categories_id . "
LIMIT 1");
so it gets all the information for each category at one time.
Then insert a conditional in this while loop that causes it to skip any hidden category or category whose parent is hidden.
while (!$categories->EOF) {
$products_in_category = (SHOW_COUNTS == 'true' ? zen_count_products_in_category($categories->fields['categories_id']) : 0);
$this->data[$categories->fields['parent_id']][$categories->fields['categories_id']] = array('name' => $categories->fields['categories_name'], 'count' => $products_in_category);
$categories->MoveNext();
}
if ($hide_status->fields['visibility_status'] < 1) {
I've tried to do this but am not knowledgable enough to get it right. Please help.
Adowty
Here is what I got so far.
after some reading about sql query syntax, I tried this:
$categories_query = "select c.categories_id, cd.categories_name, c.parent_id, visibility_status
from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd, " . TABLE_HIDE_CATEGORIES . "
where c.categories_id = cd.categories_id
and visibility_status < 1 " .
" and c.categories_status=1 " .
" and cd.language_id = '" . (int)$_SESSION['languages_id'] . "' " .
" order by c.parent_id, c.sort_order, cd.categories_name";
Seems like the WHERE part of the query should filter out all hidden categories.
Doesn't work yet.
Any help?
...so for anyone else who needs to do this.
I found the correct syntax in the site map file.
$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";
Yee-Haw
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.
My Site - Zen Cart & WordPress integration specialist
I don't answer support questions via PM. Post add-on support questions in the support thread. The question & the answer will benefit others with similar issues.