Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

new code moving manufacturers box problem


Guest

Recommended Posts

Hi,

 

I am updating this store:

http://www.blessedbaby.biz/catalog/default.php with the new code and cannot get the background and box outline out of the manufacturer's box.

 

I have made a new class like I did before called plainBox and commented out the <tr><td> tags but the outline and colors are still there.

 

At http://www.blessedbaby.biz/ you will see the manufacturer's box at the top has no border or background to it.

 

Thanks!

Link to comment
Share on other sites

So you have something like this in boxes.php :

  class plainBox extends tableBox { 



   function plainBox($contents) { 



     $this->table_data_parameters = 'class="plainBox"'; 



     $this->tableBox($contents, true); 



   } 



 }

??

 

Also are you using a Thema mod?

If you are remember you dont make the change to boxes.php you make it to thema_boxes.php

 

As long as you have a class reflecting the plainBox in stylesheet (again if you are using thema, it aint the stylesheet in /catalog/) then it should be ok.

 

CC.

Link to comment
Share on other sites

Hi,

 

No thema mod...this is today's snapshot.

 

This is the code I have in the header from the manufacturer's box:

 

<!-- manufacturers //-->

<?php

$manufacturers_query = tep_db_query("select manufacturers_id, manufacturers_name from " . TABLE_MANUFACTURERS . " order by manufacturers_name");

if (tep_db_num_rows($manufacturers_query) <= MAX_DISPLAY_MANUFACTURERS_IN_A_LIST) {

// Display a list

$manufacturers_list = '';

while ($manufacturers = tep_db_fetch_array($manufacturers_query)) {

$manufacturers_name = ((strlen($manufacturers['manufacturers_name']) > MAX_DISPLAY_MANUFACTURER_NAME_LEN) ? substr($manufacturers['manufacturers_name'], 0, MAX_DISPLAY_MANUFACTURER_NAME_LEN) . '..' : $manufacturers['manufacturers_name']);

if (isset($HTTP_GET_VARS['manufacturers_id']) && ($HTTP_GET_VARS['manufacturers_id'] == $manufacturers['manufacturers_id'])) $manufacturers_name = '<b>' . $manufacturers_name .'</b>';

$manufacturers_list .= '<a href="' . tep_href_link(FILENAME_DEFAULT, 'manufacturers_id=' . $manufacturers['manufacturers_id']) . '">' . $manufacturers_name . '</a><br>';

}

 

$info_box_contents = array();

$info_box_contents[] = array('text' => substr($manufacturers_list, 0, -4));

} else {

// Display a drop-down

$manufacturers_array = array();

if (MAX_MANUFACTURERS_LIST < 2) {

$manufacturers_array[] = array('id' => '', 'text' => PULL_DOWN_DEFAULT);

}

 

while ($manufacturers = tep_db_fetch_array($manufacturers_query)) {

$manufacturers_name = ((strlen($manufacturers['manufacturers_name']) > MAX_DISPLAY_MANUFACTURER_NAME_LEN) ? substr($manufacturers['manufacturers_name'], 0, MAX_DISPLAY_MANUFACTURER_NAME_LEN) . '..' : $manufacturers['manufacturers_name']);

$manufacturers_array[] = array('id' => $manufacturers['manufacturers_id'],

'text' => $manufacturers_name);

}

 

$info_box_contents = array();

$info_box_contents[] = array('form' => tep_draw_form('manufacturers', tep_href_link(FILENAME_DEFAULT, '', 'NONSSL', false), 'get'),

'text' => tep_draw_pull_down_menu('manufacturers_id', $manufacturers_array, $HTTP_GET_VARS['manufacturers_id'], 'onChange="this.form.submit();" size="' . MAX_MANUFACTURERS_LIST . '" style="width: 120"') . tep_hide_session_id());

}

 

new infoBox($info_box_contents);

?>

<!-- manufacturers_eof //-->

 

duh...while copying and pasting this to you I see my error...

new infoBox($info_box_contents);

should be

new plainBox($info_box_contents);

 

Time to take a rest I think!

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...