Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Remove Long Category List from META_DATA

Remove Long Category List from META_DATA

Locked

Views: 982

Results 1 to 5 of 5
This thread is locked. New replies are disabled.
30 Mar 2008, 8:22 AM
#1
willandjenny avatar

willandjenny

New Zenner

Join Date:
Nov 2007
Posts:
25
Plugin Contributions:
0

Remove Long Category List from META_DATA

I need to get rid of the auto add list of categories becaue it is incompatible with the content on all my pages. I.E. that is reason WHY different categories exist. I have been working for 4 hours and have been unable to remove the categories without screwing up something else.

Would someone with more experience than I please, please, please assist me in commenting out the correct lines and/or modifying the correct file(s).

Thank you,

William

30 Mar 2008, 8:23 AM
#2
willandjenny avatar

willandjenny

New Zenner

Join Date:
Nov 2007
Posts:
25
Plugin Contributions:
0

Re: Remove Long Category List from META_DATA

If you need to see it, my site is https://www.Custom-BuiltPC.com

Thanks,

William

30 Mar 2008, 12:22 PM
#3
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Remove Long Category List from META_DATA

If you want Zen Cart to never include your categories in any of its generated metatags on any page in Zen Cart, comment out the following code in /includes/modules/your_template/meta_tags.php:```
// Get all top category names for use with web site keywords
$sql = "select cd.categories_name from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = 0 and c.categories_id = cd.categories_id and cd.language_id='" . (int)$_SESSION['languages_id'] . "' and c.categories_status=1";
$keywords_metatags = $db->Execute($sql);
while (!$keywords_metatags->EOF) {
$keywords_string_metatags .= zen_clean_html($keywords_metatags->fields['categories_name']) . METATAGS_DIVIDER;
$keywords_metatags->MoveNext();
}

30 Mar 2008, 2:40 PM
#4
willandjenny avatar

willandjenny

New Zenner

Join Date:
Nov 2007
Posts:
25
Plugin Contributions:
0

Re: Remove Long Category List from META_DATA

DrByte,

I should have clarified that I earlier identified the code, but I was unable to comment it out without some text the same or similar to the following: NAVBAR_TITLE_1 . SECONDARY_SECTION

showing up in my meta tags in place of the text I would like omitted. I just need to know which lines, specifically, to comment out.

Thank you very much for your response and your willingness to assist me.

Sincerely,

William

30 Mar 2008, 8:08 PM
#5
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Remove Long Category List from META_DATA

The specific lines I posted are the ones to comment out if you want the effect I described.