Page 1 of 2 12 LastLast
Results 1 to 10 of 13
  1. #1
    Join Date
    Dec 2005
    Posts
    142
    Plugin Contributions
    0

    Default Adding An Extra Border

    Is it possible to add an extra border around the main wrapper? So we can do 2 colors of border?

  2. #2
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    just add a new div and border that........hmmmm where to do that.....runs off to look
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

  3. #3
    Join Date
    Apr 2006
    Location
    West Salem, IL
    Posts
    2,888
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    includes/templates/template_default/common/tpl_main_page.php

    copy tpl_main_page.php to your custom template and edit to add the extra div
    Mike
    AEIIA - Zen Cart Certified & PCI Compliant Hosting
    The Zen Cart Forum...Better than a monitor covered with post-it notes!

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

    Default Re: Adding An Extra Border

    Check here (post 9) http://www.zen-cart.com/forum/showthread.php?t=53863

    While this involves adding a "shadow image" the principal is the same.

  5. #5
    Join Date
    Dec 2005
    Posts
    142
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    OK I am lost! LOL What do you mean add a new DIV?

    I tried to addess the link below and get a black page every time I try.

    You can see what I would like to do by looking at http://www.hotslings.com/s.nl/sc.2/.f

    You will see they have a border around the main page and then a thick white border around that

  6. #6
    Join Date
    Jun 2003
    Posts
    33,721
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    Actually that is more than a "border", that is the background of the farthest back layer extended beyond the edges of the inner part of the page, but can still be acomplished with an extra <div> container or two.
    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.

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

    Default Re: Adding An Extra Border

    In tpl_main_page.php just above:

    <div id="mainWrapper">

    add something like <div id="borderarea">

    now find the following:

    <!--bof- parse time display -->

    and just above this add </div>

    If you don't want to create an image for the border then in your stylesheet add the following declaration:

    #borderarea {
    border: 5px solid #000;
    }
    The highlighted areas can be changed for your needs.

  8. #8
    Join Date
    Jun 2003
    Posts
    33,721
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    Open you tpl_main_page.php (the one you have in your override directory)

    find:

    HTML Code:
    <div id="mainWrapper">
    <?php
     /**
      * prepares and displays header output
      *
      */
      require($template->get_template_dir('tpl_header.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_header.php');?>
    Change to:

    HTML Code:
    <div id="outerBorder">
    <div id="mainWrapper">
    <?php
     /**
      * prepares and displays header output
      *
      */
      require($template->get_template_dir('tpl_header.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_header.php');?>
    Then find:

    HTML Code:
    <?php
     /**
      * prepares and displays footer output
      *
      */
      require($template->get_template_dir('tpl_footer.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_footer.php');?>
    </div>
    <!--bof- parse time display -->
    <?php
      if (DISPLAY_PAGE_PARSE_TIME == 'true') {
    ?>
    <div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div>
    <?php
      }
    ?>
    change to:

    HTML Code:
    <?php
     /**
      * prepares and displays footer output
      *
      */
      require($template->get_template_dir('tpl_footer.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_footer.php');?>
    </div>
    </div>
    <!--bof- parse time display -->
    <?php
      if (DISPLAY_PAGE_PARSE_TIME == 'true') {
    ?>
    <div class="smallText center">Parse Time: <?php echo $parse_time; ?> - Number of Queries: <?php echo $db->queryCount(); ?> - Query Time: <?php echo $db->queryTime(); ?></div>
    <?php
      }
    ?>
    The CSS for your new container would be:

    #outerBorder {
    margin: 20px 0px; /*gives spacing at top and bottom*/
    padding: 15px; /*spacing between this and the mainWrapper*/
    background-color: #ffffff; /*white background*/
    border: 1px solid #000000; /*1px black edge*/
    }

    Adjust as needed.
    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.

  9. #9
    Join Date
    Dec 2005
    Posts
    142
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    Hi Kim,
    It seems to work for the most part, with the exception that it is not around the center of the main wrapper. It extends way to much and I can not seem to figure out what I am missing. Here is a screen shot.
    Attached Images Attached Images  

  10. #10
    Join Date
    Jun 2003
    Posts
    33,721
    Plugin Contributions
    0

    Default Re: Adding An Extra Border

    Doh! Apply the width settings you have for the #mainWrapper to the #outerBorder.
    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.

 

 
Page 1 of 2 12 LastLast

Similar Threads

  1. adding a border
    By Nyx1961 in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 12 Oct 2010, 04:50 AM
  2. Extra Whitespace on Border in IE
    By Twinge in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 5 May 2009, 10:46 AM
  3. adding a border to my product listing?
    By touchclothing in forum Templates, Stylesheets, Page Layout
    Replies: 10
    Last Post: 17 Aug 2008, 03:52 AM
  4. Adding a border line to Products
    By firestalker in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 5 Jun 2007, 09:35 PM

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