Results 1 to 3 of 3

infoBox headers

This is a discussion on infoBox headers within the osCMax v1.7 General Mods Discussion forums, part of the osCmax v1.7 Forums category; I need to change some but not all of the infobox (shopping cart) header background colours. Since the template system ...

      
  1. #1
    Member
    Join Date
    Jan 2004
    Posts
    71
    Rep Power
    9


    Default infoBox headers

    I need to change some but not all of the infobox (shopping cart) header background colours. Since the template system affects all the boxes how do I change 1 or 2.

    Also I need to add an image to the privacy page ( not a background image) how do I go about this.

  2. #2
    Active Member
    Join Date
    Jan 2003
    Location
    Surrey, UK
    Posts
    126
    Rep Power
    0


    Default

    easiest way would be to create a new box template. Copy the old one exactly, named (eg) box2.tpl.php in the same directory (catalog/templates/)

    In the new one, on lines 6-8:
    Code:
                    <tr>
                      <td height="14" class="infoBoxHeading"><img src="images/infobox/<?php switch ($corner_left) { case 'square': echo 'corner_right_left.gif';	break; case 'rounded': echo 'corner_left.gif'; break;} ?>" border="0" alt="" width="11" height="14"></td>
                      <td width="100%" height="14" class="infoBoxHeading"><?php echo $boxHeading; ?></td>
                      <td height="14" class="infoBoxHeading" nowrap><?php echo $boxLink; ?><img src="images/<?php switch ($corner_right) { case 'square': echo 'pixel_trans.gif';	break; case 'rounded': echo 'infobox/corner_right.gif'; break;} ?>" border="0" alt="" width="11" height="14"></td>
                    </tr>
    change the 'class="infoBoxHeading"' to 'class="infoBoxHeadingTwo"'

    then in catalog/stylesheet.css

    add the following item

    Code:
    TD.infoBoxHeadingTwo {
      font-family: Verdana, Arial, sans-serif;
      font-size: 10px;
      font-weight: bold;
      background: #{YOUR COLOUR IN HERE};
      color: #ffffff;
    }
    just after where you find the current infoBoxHeading style.

    Then, go to each of the boxes which need the special colour and change:

    Code:
      require(DIR_WS_TEMPLATES . TEMPLATENAME_BOX);
    to

    Code:
      require(DIR_WS_TEMPLATES . 'box2.tpl.php');
    strictly speaking you should define new entries in includes/filename.php and use that constant, but that would take more time and effort. This should work.

    jw

  3. #3
    Member
    Join Date
    Jan 2004
    Posts
    71
    Rep Power
    9


    Default

    It worked a treat. I had almost worked it all out. I was just calling the new template wrongly.

    Many thanks jw

    Glynn

Similar Threads

  1. removing extra TD's in the box or infobox headers
    By line47 in forum osCommerce 2.2 Modification Help
    Replies: 0
    Last Post: 09-30-2005, 08:16 AM
  2. 2 headers UGH!
    By AnnieChrist in forum osCommerce 2.2 Modification Help
    Replies: 1
    Last Post: 03-24-2005, 05:06 AM
  3. Headers
    By lem in forum osCmax v1.7 Discussion
    Replies: 0
    Last Post: 02-18-2005, 12:07 AM
  4. Remove box headers?
    By operadivamommy in forum osCmax v1.7 Discussion
    Replies: 3
    Last Post: 12-01-2004, 10:04 AM
  5. Replace InfoBox Headers with Graphics
    By xtech in forum osCMax v1.7 General Mods Discussion
    Replies: 2
    Last Post: 03-22-2004, 08:47 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
  •