v2.1.x Fehler in "CategoryListingContentView.inc.php"

Thema wurde von Avenger, 12. Februar 2015 erstellt.

  1. Avenger

    Avenger G-WARD 2012/13/14/15

    Registriert seit:
    26. April 2011
    Beiträge:
    4.771
    Danke erhalten:
    1.478
    Danke vergeben:
    89
    In der "function get_html" werden die Kategorien-Infos (Bild, Beschreibung) nur dann angezeigt, wenn eine Kategorie Unterkategorien hat.

    Ursache ist die Abfrage "if(count($categories_content) > 0)" ("$categories_content" enthält die Unterkategorien-Info).

    Diese if-Abfrage muss entfallen.

    PHP:
                // BOF GM_MOD
                
    define('GM_CAT_COUNT'count($categories_content));

                if(
    count($categories_content) > 0)
                {
                    if(
    MAX_DISPLAY_CATEGORIES_PER_ROW count($categories_content))
                    {
                        
    $this->set_content_data('GM_LI_WIDTH'100/count($categories_content) - 2);
                    }
                    else
                    {
                        
    $this->set_content_data('GM_LI_WIDTH'100/MAX_DISPLAY_CATEGORIES_PER_ROW 2);
                    }
                    
    //include (DIR_WS_MODULES.FILENAME_NEW_PRODUCTS);
                    // EOF GM_MOD

                    
    $image '';
                    if(
    $category['categories_image'] != '')
                    {
                        
    $image DIR_WS_IMAGES.'categories/'.$category['categories_image'];
                    }
                    
    $this->set_content_data('CATEGORIES_NAME'$category['categories_name']);
                    
    $this->set_content_data('CATEGORIES_HEADING_TITLE'$category['categories_heading_title']);

                    
    $this->set_content_data('CATEGORIES_IMAGE'$image);
                    
    $this->set_content_data('CATEGORIES_ALT_TEXT'$category['gm_alt_text']);
                    
    $this->set_content_data('CATEGORIES_DESCRIPTION'$category['categories_description']);

                    
    $this->set_content_data('SHOW_SUB_CATEGORIES_IMAGES'$category['show_sub_categories_images']);
                    
    $this->set_content_data('SHOW_SUB_CATEGORIES_NAMES'$category['show_sub_categories_names']);
                    
                    if(isset(
    $t_filter_selection_array) && count($t_filter_selection_array) != 0)
                    {
                        
    $this->set_content_data('FILTER_SELECTION_ARRAY'$t_filter_selection_array);
                    }
                }