Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Header Width


barakas

Recommended Posts

Posted

I have the standard fluid width page layout, but I would like to make it so that the header is the same size as the main category, and scales in size to fit with it.

 

I can imagine that all i would need to do is insert 2 end blocks the same size as my side bars to create this effect, but I am unsure how I would go about inserting them with both at either end.

 

any help?

Posted

The first <table> in includes/header.php holds the header image and links. If you add an extra cell to the start and end of that table, I think it will do what you want. This is how it would look in MS2 code:

 

<table border="0" width="100%" cellspacing="0" cellpadding="0">
 <tr class="header">
<td width="<?php echo BOX_WIDTH; ?>"></td>
<td valign="middle"><?php echo '<a href="' . tep_href_link(FILENAME_DEFAULT) . '">' . tep_image(DIR_WS_IMAGES . 'oscommerce.gif', 'osCommerce') . '</a> ' . $current_category_id; ?></td>
<td align="right" valign="bottom"><?php echo '<a href="' . tep_href_link(FILENAME_ACCOUNT, '', 'SSL') . '">' . tep_image(DIR_WS_IMAGES . 'header_account.gif', HEADER_TITLE_MY_ACCOUNT) . '</a>  <a href="' . tep_href_link(FILENAME_SHOPPING_CART) . '">' . tep_image(DIR_WS_IMAGES . 'header_cart.gif', HEADER_TITLE_CART_CONTENTS) . '</a>  <a href="' . tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL') . '">' . tep_image(DIR_WS_IMAGES . 'header_checkout.gif', HEADER_TITLE_CHECKOUT) . '</a>'; ?>  </td>
<td width="<?php echo BOX_WIDTH; ?>"></td>
 </tr>
</table>

 

Use the BOX_WIDTH constant so you can alter size in one place.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...