Page 2 of 2 FirstFirst 12
Results 11 to 13 of 13
  1. #11
    Join Date
    May 2010
    Location
    Athens, Greece
    Posts
    292
    Plugin Contributions
    0

    Default Re: How to remove breadcrumbs from non-store pages?

    I call it "trial and error" but it's similar. And I read a lot of posts in the forums trying to get ideas and gain experience.

  2. #12
    Join Date
    Sep 2005
    Location
    Waikato, New Zealand
    Posts
    1,539
    Plugin Contributions
    3

    Default Re: How to remove breadcrumbs from non-store pages?

    Quote Originally Posted by Athens Collectibles View Post
    No idea how it works, but it does!

    What I do is go to each page I want to remove breadcrumbs from and look at the URL in the browser. For example:

    http://athenscollectibles.info/index..._page=about_us

    I use the last part (about_us) without the underscore to form the CSS line:

    #aboutusBody #navBreadCrumb{ display: none; }

    It doesn't work if I leave the underscore but don't ask me why. I don't use Easy Pages but, as you discovered, it works on the same principle (page2Body rather than page_2Body). A Zen Cart guru could provide an explanation. Although it works as described, it would still be good to learn what's behind it.
    #aboutusBody -- if you look at the source of your "about us" page you will see that that is the body id

    HTML Code:
    <body id="aboutusBody">
    so your rule will only work on specific that page.

    each page has a different body ID

    obviously all the category pages have the same body ID "indexBody"
    and all the product info page have the same id "productinfoBody"

    infact if you wanted to only show breadcrumbs on products and categories, you could possibly reverse your thinking
    and do something like this
    HTML Code:
    #navBreadCrumb{ display: none; }
    
    #indexBody #navBreadCrumb{ display: block; }
    #productinfoBody #navBreadCrumb{ display: block; }
    Which has a lot fewer rules

    --------------------------
    seems to work on test site, but haven't fully tested it
    Webzings Design
    Semi retired from Web Design

  3. #13
    Join Date
    May 2010
    Location
    Athens, Greece
    Posts
    292
    Plugin Contributions
    0

    Default Re: How to remove breadcrumbs from non-store pages?

    Many thanks for the explanation Nigel. I had never thought of looking into the source and see the <body id=...>. I can easily create html pages with the use of FrontPage even though this is an antiquated application. The difficulty with Zen Cart is that the html code is created by various php files and it's not easy to follow the logic, unless you are a php programmer. Unfortunately I'm not, although I would like to and I consider to do some reading if I ever find the time. Even at 63, it's never too late.

    What I still can not understand is how the php code decides on the body id name. It seems to be the page name but...

    ...the standard Zen Cart name for the Contact us page is contact_us (with an underscore). I needed my own page with captcha and upload links and I'm using an external form processing company where the form is sent without my email address being revealed. There are a lot more advantages to this approach but this is another story. Having created a new page I entered the html in the editor and it works perfectly. However, I had to give the page another name and I named it contactus (without an underscore).

    If I look at the source code of each of the two pages, they both have <body id="contactusBody">, which seems funny. I don't really mind because I only use one of them but it could be an issue for someone else.

    Finally, your idea of removing breadcrumbs for all pages and enabling them on categories and products is excellent. It would reduce the size of my stylesheet.css considerably and I shall try it as soon as possible on my local XAMPP installation. It looks perfectly correct at a first glance and I don't anticipate any problems.

    Thank you again for your contribution and for the tip with breadcrumbs. Kind regards from Athens, Greece.

 

 
Page 2 of 2 FirstFirst 12

Similar Threads

  1. v139h how to remove breadcrumb from ez-pages and defined pages
    By snk060 in forum General Questions
    Replies: 3
    Last Post: 11 Nov 2013, 04:40 PM
  2. Removing breadcrumbs from certain pages...
    By Alex Clarke in forum General Questions
    Replies: 11
    Last Post: 5 Oct 2010, 11:06 AM
  3. Remove Header Links & Breadcrumbs From Checkout
    By games4gamers in forum General Questions
    Replies: 10
    Last Post: 1 Apr 2010, 08:42 PM
  4. Remove Breadcrumbs from Login, Shopping Cart and Checkout Pages
    By limelites in forum Templates, Stylesheets, Page Layout
    Replies: 0
    Last Post: 25 Apr 2009, 07:17 PM
  5. How To Remove Heading from pages that EZ Pages creates
    By madkaw9 in forum Customization from the Admin
    Replies: 5
    Last Post: 24 Feb 2009, 02:12 AM

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