Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2007
    Location
    Pennsylvania
    Posts
    806
    Plugin Contributions
    0

    Default Categories Name Never Set ( $current_categories_name )

    Hi All,
    Working on 1.5.6 on PHP7.2. I noticed that the category name <h1> is empty. I then noticed that $current_categories_name is never set. At least not that I can find. Doing a print_r on $categories_description_lookup I was expecting to find a $categories_description_lookup->fields['categories_name'], but it doesn't exist. Is there a new admin switch I haven't found to enable category headings?

    For now I have added categories_name to the sql on line 328 of includes/modules/pages/index/main_template_vars.php

    $sql = "SELECT categories_description, categories_name
    FROM " . TABLE_CATEGORIES_DESCRIPTION . "
    WHERE categories_id= :categoriesID
    AND language_id = :languagesID";

    Thank You,
    John
    Last edited by bumba000; 1 Mar 2019 at 07:35 AM.

  2. #2
    Join Date
    Feb 2007
    Location
    Pennsylvania
    Posts
    806
    Plugin Contributions
    0

    Default Re: Categories Name Never Set ( $current_categories_name )

    EDIT** Just a minute late for changing post... lol

    I of course also had to change
    includes/templates/custom/templates/tpl_index_product_list.php
    from <h1 id="productListHeading"><?php echo $current_categories_name ; ?></h1>
    to <h1 id="productListHeading"><?php echo $categories_description_lookup->fields['categories_name']; ?></h1>

  3. #3
    Join Date
    Feb 2007
    Location
    Pennsylvania
    Posts
    806
    Plugin Contributions
    0

    Default Re: Categories Name Never Set ( $current_categories_name )

    My Fault!! I had accidentally overwritten the original main_template_vars.php. I just extracted a fresh fileset and it's good. I replace the file and we're all set now. ;)

    John

 

 

Similar Threads

  1. Store categories and sub categories name in Array
    By fawad123 in forum General Questions
    Replies: 0
    Last Post: 18 May 2011, 09:08 AM
  2. Set a limited number of categories to be displayed in categories side box
    By NickPCs in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 3 Nov 2009, 02:50 AM
  3. How do I set up categories inside of categories?
    By RocketFoot in forum Setting Up Categories, Products, Attributes
    Replies: 3
    Last Post: 26 Mar 2009, 02:14 PM
  4. Categories page item name wrong (name-)
    By shoulders in forum General Questions
    Replies: 3
    Last Post: 12 Jul 2008, 01:31 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR