Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Where do I ???


Guest

Recommended Posts

Try includes/modules/products_new.php (the name is similar look closely, closely, :shock:

 

you are getting sleepy, you are getting sleepy, :oops:

 

you are feeling happy, happy with your osc, you like you osc,

 

:)

you dont want to change the box width, it makes you happy, look closely, sleepy, sleepy, happy. :D

Best Regards,

 

Salvatore Iozzia

 

Loaded Commerce - Oscommerce - All Loaded Up.

Link to comment
Share on other sites

Pierre;

 

In catalog/index.php (or default.php) around line 290 are the table calls for the middle of the default page:

  } else { // default page

?>

   <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="0">

     <tr>

       <td><table border="0" width="100%" cellspacing="0" cellpadding="0">

         <tr>

           <td class="pageHeading"><?php echo HEADING_TITLE; ?></td></tr>

           <tr><td class="pageHeading" align="center"><?php echo tep_image(DIR_WS_IMAGES . 'header.jpg', HEADING_TITLE, HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td>

         </tr>

       </table></td>

 

Other areas in that same file deal with the table widths for some of the other pages (maybe all of them?)

... if you want to REALLY see something that doesn't set up right out of the box without some tweaking,

try being a Foster Parent!

Link to comment
Share on other sites

Thank's stuart but i've tried this:

Changed at line 303

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">

         <tr>

           <td class="main"><?php echo tep_customer_greeting(); ?></td>

         </tr>

         <tr>

           <td class="main"><br><?php echo TEXT_MAIN; ?></td>

         </tr>

         <tr>

           <td><br><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

         </tr>

With this

<td><table border="0" width="400" cellspacing="0" cellpadding="0" align="center">

         <tr>

           <td class="main"><?php echo tep_customer_greeting(); ?></td>

         </tr>

         <tr>

           <td class="main"><br><?php echo TEXT_MAIN; ?></td>

         </tr>

         <tr>

           <td><br><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td>

         </tr>

But that put the whole page at 400 pixel but i only whant the "New products for January" to be 400 pixel

 

Regards

Link to comment
Share on other sites

Nest another table in to the table data cell that pulls up the new products.

 

 

          <tr> 

           <td><table border="0" width="400" cellspacing="0" cellpadding="0" align="center"><td><tr><br><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td></tr></table></td> 

         </tr>

 

And that should do the trick :) The "new products" is treated just like an infobox, and while the width of those is determined by application_top.php each box is coded to be "100%" of the width of the column it is in, new products is no exception, so short of changing the code for just that one box and creating a new constructor, adding a smaller table inside the cell it normally appears in is the easiest way to fix it.

Link to comment
Share on other sites

You'll need to make the <td> statement your nested table is inside of <td width="100%"> if you want a 400 width table to "center" inside of it.

Link to comment
Share on other sites

<tr> 

           <td width="100%" align="center"><table border="0" width="400" cellspacing="0" cellpadding="0"><td><tr><br><?php include(DIR_WS_MODULES . FILENAME_NEW_PRODUCTS); ?></td></tr></table></td> 

         </tr>

 

Should work, unless the parent table this <tr> is inside of isn't set to width="100%" as well.

Link to comment
Share on other sites

Didn't notice this until now...

 

whomever gave you the original code snippit put the <tr><td> statement in your nested table backwards so it won't work.

 

Needs to be <tr><td> not <td><tr>

 

Correct the above with this little change.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...