Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Recommended Posts

Posted

I've installed the newest version of CenterShop It works fine but it only centers the shop horizontally, can't it center it vertically?

Posted

I figured it out!

 

The original code in header.php:

///////////////////	
///////////////////		
// [0001] BOF: WebMakers.com Added: Center Shop
// This goes before any other table of the shop
//
// Is center Shop ON/OFF ?
///////////////////

if ( CENTER_SHOP_ON == 'on' ) {

///////////////////	  
// [0001] Background Color ON/OFF and CellPadding for around the shop?
///////////////////

  if ( CENTER_SHOP_BACKGROUND_ON == 'on' ) {
?>
<table width="100%" cellpadding="<?php echo CENTER_SHOP_PADDING; ?>" cellspacing="0" border="0" bgcolor="<?php echo CENTER_SHOP_BACKGROUND_COLOR_OUT; ?>">
  <tr><td>
<?php
  }


///////////////////	
// [0001] Shop Width Size and Shop Background Color
///////////////////
?>

<table width="<?php echo CENTER_SHOP_WIDTH; ?>" align="center" valign="middle" BGCOLOR="<?php echo CENTER_SHOP_BACKGROUND_COLOR; ?>" BORDER="<?php echo CENTER_SHOP_BORDER; ?>" bordercolor="<?php echo CENTER_SHOP_BORDERCOLOR; ?>" CELLSPACING="<?php echo CENTER_SHOP_CELLSPACING; ?>" CELLPADDING="<?php echo CENTER_SHOP_CELLPADDING; ?>" >
  <tr><td BGColor="#99cdff">
<?php

///////////////////
// [0001] The rest of this <td> statement is located at the end of footer.php
///////////////////
}
?>

 

...is changed to:

 

///////////////////	
///////////////////		
// [0001] BOF: WebMakers.com Added: Center Shop
// This goes before any other table of the shop
//
// Is center Shop ON/OFF ?
///////////////////

if ( CENTER_SHOP_ON == 'on' ) {

///////////////////	  
// [0001] Background Color ON/OFF and CellPadding for around the shop?
///////////////////

  if ( CENTER_SHOP_BACKGROUND_ON == 'on' ) {
?>
<table width="100%" height="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td align="center" valign="middle">
<table width="100%" cellpadding="<?php echo CENTER_SHOP_PADDING; ?>" cellspacing="0" border="0" bgcolor="<?php echo CENTER_SHOP_BACKGROUND_COLOR_OUT; ?>">
  <tr><td>
<?php
  }


///////////////////	
// [0001] Shop Width Size and Shop Background Color
///////////////////
?>

<table width="<?php echo CENTER_SHOP_WIDTH; ?>" align="center" valign="middle" BGCOLOR="<?php echo CENTER_SHOP_BACKGROUND_COLOR; ?>" BORDER="<?php echo CENTER_SHOP_BORDER; ?>" bordercolor="<?php echo CENTER_SHOP_BORDERCOLOR; ?>" CELLSPACING="<?php echo CENTER_SHOP_CELLSPACING; ?>" CELLPADDING="<?php echo CENTER_SHOP_CELLPADDING; ?>" >
  <tr><td BGColor="#99cdff">
<?php

///////////////////
// [0001] The rest of this <td> statement is located at the end of footer.php
///////////////////
}
?>

 

And in footer.php:

 

The original code

<?php
///////////////////
// [0001] WebMakers.com Added: Center Shop
// This goes at the very end of the footer after all the tables
///////////////////

 if ( CENTER_SHOP_ON == 'on' ) {

///////////////////
// [0001] close table used to center
///////////////////
?>
  </td></tr>
</table
<?php
if ( CENTER_SHOP_BACKGROUND_ON == 'on' ) {

///////////////////
// [0001] Add color to bottom of screen for large displays - needed especially on notebooks that run at 1600x1200
// close table used for outer bgcolor around the shop
///////////////////
?>

<!-- deleting the Spacer in the footer without the default background-color -->
 <!--  </td></tr>
  <tr><td height="150">?</td></tr>
</table> -->

<?php
}
 }
///////////////////
// [0001] EOF: WebMakers.com Added: Center Shop
///////////////////
///////////////////
?>

 

... is canged to:

<?php
///////////////////
// [0001] WebMakers.com Added: Center Shop
// This goes at the very end of the footer after all the tables
///////////////////

 if ( CENTER_SHOP_ON == 'on' ) {

///////////////////
// [0001] close table used to center
///////////////////
?>
  </td></tr>
</table></td>
 </tr>
</table>
<?php
if ( CENTER_SHOP_BACKGROUND_ON == 'on' ) {

///////////////////
// [0001] Add color to bottom of screen for large displays - needed especially on notebooks that run at 1600x1200
// close table used for outer bgcolor around the shop
///////////////////
?>

<!-- deleting the Spacer in the footer without the default background-color -->
 <!--  </td></tr>
  <tr><td height="150">?</td></tr>
</table> -->

<?php
}
 }
///////////////////
// [0001] EOF: WebMakers.com Added: Center Shop
///////////////////
///////////////////
?>

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...