Page 1 of 2 12 LastLast
Results 1 to 10 of 17
  1. #1
    Join Date
    Sep 2004
    Posts
    2,420
    Plugin Contributions
    2

    Default [Done v1.3.7.1] #indexHomeBody - not working

    Quote Originally Posted by DrByte View Post
    No, that stylesheet entry is exactly as intended.
    Thank you for the info.

    Just finished updating 1.36 to 1.37. One related question. The 1.37 announcement stated that #indexHomeBody was added to identify the "home" page. However I cannot locate that style class anywhere in any of the 1.37 files including stylesheet.css.

    Woody

  2. #2
    Join Date
    Nov 2003
    Location
    Haarlem | Netherlands
    Posts
    1,989
    Plugin Contributions
    15

    Default Re: [not a bug] 1.37 stylesheet.css

    It looks like #indexHomeBody is being generated dynamicly in tpl_main_page.php :
    Code:
      $body_id = ($this_is_main_page) ? 'indexHome' : str_replace('_', '', $_GET['main_page']);
    ?>
    <body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
    doesn't it show when you look at the main_page HTML source?

  3. #3
    Join Date
    Jul 2006
    Posts
    24
    Plugin Contributions
    0

    Default Re: [not a bug] 1.37 stylesheet.css

    Quote Originally Posted by paulm View Post
    doesn't it show when you look at the main_page HTML source?
    Now, I'm no expert here and this is my very first upgrade (1.3.6 > 1.3.7) but I'm not seeing this id in the body tag of my main page either. Other new functionalities seem to be present (such as the Breadcrumb switch for the main page to turn it off there)

    I checked the tpl_main_page.php and it seems to have the code referenced above - I even put that file in my custom template folder under the common/ folder - but it does not seem to be adding the id attribute "indexHomeBody" to the source of the rendered main page.

    Is there another file that I may have missed that impacts this function?

  4. #4
    Join Date
    Sep 2004
    Posts
    2,420
    Plugin Contributions
    2

    Default Re: [not a bug] 1.37 stylesheet.css

    Quote Originally Posted by paulm View Post
    It looks like #indexHomeBody is being generated dynamicly in tpl_main_page.php :
    Code:
      $body_id = ($this_is_main_page) ? 'indexHome' : str_replace('_', '', $_GET['main_page']);
    ?>
    <body id="<?php echo $body_id . 'Body'; ?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'; ?>>
    doesn't it show when you look at the main_page HTML source?
    Oh I see <body id="indexBody">.

    I was looking for #indexHomeBody.

    So I'm still not sure about how all the above relates. I have more to learn about how CSS and Zen Cart work together. The more I think I know the more I find the less I know ;-)

    Woody

  5. #5
    Join Date
    Jun 2003
    Posts
    33,797
    Plugin Contributions
    0

    Default Re: [not a bug] 1.37 stylesheet.css

    Unless you have a style that you want only on the index, you don't need to worry about it.
    Please do not PM for support issues: a private solution doesn't benefit the community.

    Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

  6. #6
    Join Date
    Nov 2003
    Location
    Haarlem | Netherlands
    Posts
    1,989
    Plugin Contributions
    15

    Default Re: [not a bug] 1.37 stylesheet.css

    Kim is right of course.

    I only posted the piece of code to make clear that the tag is generated dynamicly, because I already suspected that that was the reason you could not find it in the files.

    But if you do need it, it should show in the HTML source of the index page (haven't had time to install 1.3.7 and take a look yet, I am afraid that will have to wait until next year ;-) )

  7. #7
    Join Date
    Sep 2004
    Posts
    2,420
    Plugin Contributions
    2

    Default Re: [not a bug] 1.37 stylesheet.css

    Quote Originally Posted by Kim View Post
    Unless you have a style that you want only on the index, you don't need to worry about it.
    Huh? I am certainly not "worrying" about it. The point is I am trying to learn how the functionality works so I can utilize it! I am not a CSS expert so I will go to my corner and experiment. ;-)

    And thanks Paul for posting that code. That was indeed helpful.

    Happy New Year!

    Woody

  8. #8
    Join Date
    Jul 2006
    Posts
    24
    Plugin Contributions
    0

    Default Re: [not a bug] 1.37 stylesheet.css

    Quote Originally Posted by Kim View Post
    Unless you have a style that you want only on the index, you don't need to worry about it.
    That's true, Kim, except my concern is to establish whether this is an error that I have made during the upgrade process or not. To clarify, I am aware that I will need to add the id #indexHomeBody to my stylesheet. The issue is that it should be generated dynamically into the source at the body element i.e. <body id="indexHomeBody">. Truth be told, in the not too distant future, I definitely see myself requiring this, so I would like to hear from others who have upgraded to 1.3.7 as to whether or not it works out of the box.

    Woodyman: you're seeing the same thing I am in your source, but in fact it seems to me that you should be seeing the <body id="indexHomeBody"> on the main page source. The code that was quoted from tpl_main_page.php...

    PHP Code:
     $body_id = ($this_is_main_page) ? 'indexHome' : str_replace('_', '', $_GET['main_page']);
    ?>
    <body id="<?php echo $body_id 'Body'?>"<?php if($zv_onload !='') echo ' onload="'.$zv_onload.'"'?>>
    ...seems to be providing that by first printing the variable form of "indexHome" and then in the second line it tacks on the "Body", making "indexHomeBody". I'm describing this poorly (I'm no php genius) but that seems to be what it's doing.

    Again, thanks for discussing this, folks. I'm in my first ZC upgrade and I really want to find the best way to perform it for the future, when the site is live. It's a bit of a dodgy process, I find, simply because of the range of the cart; I just need to get comfortable enough that I have done in correctly to rely on the process a little bit.

  9. #9
    Join Date
    Nov 2005
    Location
    Colorado Springs, CO USA
    Posts
    7,035
    Plugin Contributions
    31

    Default Re: [not a bug] 1.37 stylesheet.css

    Quote Originally Posted by paulm View Post
    Kim is right of course.

    I only posted the piece of code to make clear that the tag is generated dynamicly, because I already suspected that that was the reason you could not find it in the files.

    But if you do need it, it should show in the HTML source of the index page (haven't had time to install 1.3.7 and take a look yet, I am afraid that will have to wait until next year ;-) )
    It doesn't show <body id="indexHomeBody"> it only shows as <body id="indexBody">

  10. #10
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,474
    Plugin Contributions
    6

    Default Re: [not a bug] 1.37 stylesheet.css

    That statement would actually work better using:

    $this_is_home_page

    thanks for the update ...
    Linda McGrath
    If you have to think ... you haven't been zenned ...

    Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!

    Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
    Officially PayPal-Certified! Just click here

    Try our Zen Cart Recommended Services - Hosting, Payment and more ...
    Signup for our Announcements Forums to stay up to date on important changes and updates!

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. v155 [Done v155a] Admin, alt_nav not working
    By torvista in forum Bug Reports
    Replies: 13
    Last Post: 3 Nov 2016, 07:26 PM
  2. [Done 1.5.0] Hungarian Forint... not working
    By s_mack in forum Bug Reports
    Replies: 10
    Last Post: 20 Apr 2011, 04:18 AM
  3. Replies: 25
    Last Post: 7 Apr 2011, 05:41 AM
  4. [Done v1.3.8] Forgot your password link is not working!!
    By Boss Of The Bosses in forum Bug Reports
    Replies: 21
    Last Post: 3 Sep 2008, 09:52 PM
  5. Replies: 7
    Last Post: 27 Oct 2006, 10:10 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