Page 176 of 235 FirstFirst ... 76126166174175176177178186226 ... LastLast
Results 1,751 to 1,760 of 2345
  1. #1751
    Join Date
    Sep 2009
    Location
    Stuart, FL
    Posts
    12,478
    Plugin Contributions
    88

    Default Re: Css flyout menu 1.5 category ul generator

    It's here

  2. #1752
    Join Date
    Jul 2005
    Location
    Upstate NY
    Posts
    22,010
    Plugin Contributions
    25

    Default Re: Css flyout menu 1.5 category ul generator

    I've tried every combination I can think of that would be applicable to the location, and none of them affects it. I can't look at it any more tonight.

  3. #1753
    Join Date
    Dec 2009
    Posts
    204
    Plugin Contributions
    0

    Default Re: Css flyout menu 1.5 category ul generator

    Quote Originally Posted by gjh42 View Post
    I've tried every combination I can think of that would be applicable to the location, and none of them affects it. I can't look at it any more tonight.
    Thanks a lot for taking an interest. The Css drop-down menu and click-show-hide categories can be seen here: www.andila.co.uk

    This is the code that generates the categories for the Category sidebox:
    Code:
    class zen_categories_ul_generator {
      var $root_category_id = 0,
          $max_level = 6,
          $data = array(),
          $root_start_string = '',
          $root_end_string = '',
          $parent_start_string = '',
          $parent_end_string = '',
          $parent_group_start_string = '%s<ul>',
          $parent_group_end_string = '%s</ul>',
          $child_start_string = '%s<li>',
          $child_end_string = '%s</li>',
          $spacer_string = '',
          $spacer_multiplier = 1;
      var $document_types_list = ' (3) ';  // acceptable format example: ' (3, 4, 9, 22, 18) '
    
      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);
        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();
        }
    // DEBUG: These lines will dump out the array for display and troubleshooting:
    // foreach ($this->data as $pkey=>$pvalue) { 
    //   foreach ($this->data[$pkey] as $key=>$value) { echo '['.$pkey.']'.$key . '=>' . $value['name'] . '<br>'; }
    // }
      }
    
      function buildBranch($parent_id, $level = 0, $cpath = '') {
        global $cPath;
        $result = "\n".sprintf($this->parent_group_start_string, str_repeat(' ', $level*4))."\n";
        if (isset($this->data[$parent_id])) {
          foreach ($this->data[$parent_id] as $category_id => $category) {
            $result .= sprintf($this->child_start_string, str_repeat(' ', $level*4+2));
            if (isset($this->data[$category_id])) {
              $result .= $this->parent_start_string;
            }
            if ($level == 0) {
              $result .= $this->root_start_string;
              $new_cpath  = $category_id;
            } else {
              $new_cpath = $cpath."_".$category_id;
            }
            if ($cPath == $new_cpath) {
              $result .= '<a href="javascript:void(0)" class="on">'; // highlight current category & disable link
            } else {
              $result .= '<a href="' . zen_href_link(FILENAME_DEFAULT, 'cPath=' . $new_cpath) . '">';
            }
            $result .= $category['name'];
            if (SHOW_COUNTS == 'true' && ((CATEGORIES_COUNT_ZERO == '1' && $category['count'] == 0) || $category['count'] >= 1)) {
              $result .= CATEGORIES_COUNT_PREFIX . $category['count'] . CATEGORIES_COUNT_SUFFIX;
            }
            $result .= '</a>';
            if ($level == 0) {
              $result .= $this->root_end_string;
            }
            if (isset($this->data[$category_id])) {
              $result .= $this->parent_end_string;
            }
            if (isset($this->data[$category_id]) && (($this->max_level == '0') || ($this->max_level > $level+1))) {
              $result .= $this->buildBranch($category_id, $level+1, $new_cpath);
              $result .= sprintf($this->child_end_string, str_repeat(' ', $level*4+2))."\n";
            } else {
              $result .= sprintf($this->child_end_string, '')."\n";
            }
          }
        }
        $result .= sprintf($this->parent_group_end_string, str_repeat(' ', $level*4))."\n";
        return $result;
      }
    
      function buildTree() {
        return $this->buildBranch($this->root_category_id, 0);
      }
    }
    ?>
    and this is the code for the css flyout menu:
    Code:
    class zen_categories_ul_generator {
        var $root_category_id = 0,
        $max_level = 0,
        $data = array(),
        $parent_group_start_string = '<ul%s>',
        $parent_group_end_string = '</ul>',
        $child_start_string = '<li%s>',
        $child_end_string = '</li>',
        $spacer_string = '
    ',
        $spacer_multiplier = 1;
        
        var $document_types_list = ' (3) ';
        // acceptable format example: ' (3, 4, 9, 22, 18) '
        
        function zen_categories_ul_generator($load_from_database = true)
        {
            global $languages_id, $db;
            $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);
            while (!$categories->EOF) {
                $this->data[$categories->fields['parent_id']][$categories->fields['categories_id']] = array('name' => $categories->fields['categories_name'], 'count' => 0);
                $categories->MoveNext();
            }
        }
        
        function buildBranch($parent_id, $level, $submenu=true, $parent_link='')
        {
            $result = sprintf($this->parent_group_start_string, ($submenu==true) ? ' class="level'. ($level+1) . '"' : '' );
            
            if (($this->data[$parent_id])) {
                foreach($this->data[$parent_id] as $category_id => $category) {
                    $category_link = $parent_link . $category_id;
                    if (($this->data[$category_id])) {
                        $result .= sprintf($this->child_start_string, ($submenu==true) ? ' class="submenu"' : '');
                    } else {
                        $result .= sprintf($this->child_start_string, '');
                    }
                    $result .= str_repeat($this->spacer_string, $this->spacer_multiplier * 1) . '<a href="' . zen_href_link(FILENAME_DEFAULT, 'cPath=' . $category_link) . '">';
                    $result .= $category['name'];
                    $result .= '</a>';
    				  
                    if (($this->data[$category_id]) && (($this->max_level == '0') || ($this->max_level > $level+1))) {
                        $result .= $this->buildBranch($category_id, $level+1, $submenu, $category_link . '_');
                    }
                    $result .= $this->child_end_string;
                }
            }
            
            $result .= $this->parent_group_end_string;
            return $result;
        }
        
        function buildTree($submenu=false)
        {
            return $this->buildBranch($this->root_category_id, '', $submenu);
        }
    }
    ?>
    I tried to change the name of one of them to category_ul_generator1.php and it doesnt seem to work like that.

  4. #1754
    Join Date
    Jan 2010
    Posts
    16
    Plugin Contributions
    0

    Default Re: CSS Dropdown menu for your header- With Categories!

    Hey,

    I love this mod. Looks awesome. Gotta question though

    Found a solution .... So, instead of asking - I am just saying thanks :-P

    PS. Respect Jade! (this is coming from a Dad of a 10 month old)
    Last edited by kaskudoo; 10 Jan 2010 at 02:03 AM.

  5. #1755
    Join Date
    Dec 2009
    Posts
    55
    Plugin Contributions
    0

    Default Re: CSS Dropdown menu for your header- With Categories!

    Hey guys,

    In IE7 and lower, the nav is all sorts of screwed up. I tried putting in the .htaccess file that allows it to run the .htc file (this may be Paul's version that added that), but either doesn't show up, or shows up in the wrong areas.

    Anyone have any ideas?

    www.robomatter.net

  6. #1756
    Join Date
    Jun 2006
    Posts
    403
    Plugin Contributions
    0

    help question CSS Dropdown menu for your header Not working in IE 8

    After I upgraded my computer from IE7 to IE8, my websites drop down menu are broken. I have click on "compatibility view" each time to make it look right. How about my customers who don't know such thing as "compatibility view"?

    Did anybody have the same problem?

    What can I do fix this problem so that everybody can view my website right, no matter they are using IE7 or IE8?

    My sites are:
    http://www.roseforlove.com
    http://www.thesbeauty.com

  7. #1757
    Join Date
    Jun 2009
    Location
    Otorohanga, New Zealand
    Posts
    25
    Plugin Contributions
    0

    red flag Re: CSS Dropdown menu for your header Not working in IE 8

    Quote Originally Posted by lina0962 View Post
    After I upgraded my computer from IE7 to IE8, my websites drop down menu are broken. I have click on "compatibility view" each time to make it look right. How about my customers who don't know such thing as "compatibility view"?

    Did anybody have the same problem?

    What can I do fix this problem so that everybody can view my website right, no matter they are using IE7 or IE8?

    My sites are:
    http://www.roseforlove.com
    http://www.thesbeauty.com
    Can you break down the Jade with .... section so these will be a drop down instead all across the top, all the space for each cata, decrease this

    Richard Scott

  8. #1758
    Join Date
    Jun 2009
    Location
    Otorohanga, New Zealand
    Posts
    25
    Plugin Contributions
    0

    Default Re: CSS Dropdown menu for your header Not working in IE 8

    Quote Originally Posted by lina0962 View Post
    After I upgraded my computer from IE7 to IE8, my websites drop down menu are broken. I have click on "compatibility view" each time to make it look right. How about my customers who don't know such thing as "compatibility view"?

    Did anybody have the same problem?

    What can I do fix this problem so that everybody can view my website right, no matter they are using IE7 or IE8?

    My sites are:
    http://www.roseforlove.com
    http://www.thesbeauty.com
    Have you sorted this as it is working when I tested and with FireFox

    Richard

  9. #1759
    Join Date
    Jun 2006
    Posts
    403
    Plugin Contributions
    0

    customer issue Re: CSS Dropdown menu for your header- With Categories!

    Quote Originally Posted by scottwww1 View Post
    Have you sorted this as it is working when I tested and with FireFox

    Richard
    Quote Originally Posted by scottwww1 View Post
    Can you break down the Jade with .... section so these will be a drop down instead all across the top, all the space for each cata, decrease this

    Richard Scott
    hello, Richard:

    Not quite understanding your anwer... could you please specify it in more details? Thanks a lot!!!

  10. #1760
    Join Date
    Sep 2009
    Posts
    11
    Plugin Contributions
    0

    Default Re: CSS Dropdown menu for your header- With Categories!

    Hi I have a really complicate question regarding the conflict of drop down menu embeded in AppleZen and JGallery.

    I installed Jgallery first and found out when I go to Gallery page, there will be some error notice in drop down menu, which is like: Notice: Undefined offset: 2 in /mnt/w0911/d02/s16/b0316c3a/www/clipontogo.com/includes/classes/categories_ul_generator.php on line 63

    Notice: Undefined offset: 2 in /mnt/w0911/d02/s16/b0316c3a/www/clipontogo.com/includes/classes/categories_ul_generator.php on line 72
    you can see it live here: http://clipontogo.com//index.php?main_page=gallery
    the menu in the bottom of the page belongs to tpl_main_page.php

    After million times of trying I found if I move the drop down menu section from tpl_main_page.php to tpl_header.php, the problem will be automaticly solved, but only in FIREFOX! When I browse it in IE7, the drop down menu will not have level2,3...anymore...
    You can see it live in the same address: http://clipontogo.com//index.php?main_page=gallery
    the menu below the branding is belong to tpl_header.php

    So my question is:
    1, Is there anyway to use Jgallery normally in AppleZen without messing up the drop down menu?
    2, If move the drop menu section from tpl_main_page.php to tpl_header.php is a correct method, why it's not showing normal in IE7? Any way to fix it?

    Thanks a lot!!!!!!
    Vanessa

 

 

Similar Threads

  1. Categories dropdown menu/css
    By KenshiroU in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 5 Apr 2013, 01:04 PM
  2. HIde categories mod with css dropdown menu
    By adowty in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 9 Feb 2012, 01:05 AM
  3. How to use ezpages/categories as dropdown menu in the header?
    By mdivk in forum Templates, Stylesheets, Page Layout
    Replies: 12
    Last Post: 21 Dec 2011, 06:32 PM
  4. whats wrong with this css for my dropdown menu?
    By 1kell in forum Templates, Stylesheets, Page Layout
    Replies: 9
    Last Post: 28 May 2010, 02:47 AM
  5. Header Dropdown Menu (CSS) Without the Dropdown???
    By hcd888 in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 27 May 2009, 01:20 AM

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