RE: Removing infobox ronded corners
H2O <[email protected]> 10 Sep 2003 19:49:10 -0000
| Newsgroups | gmane.comp.web.oscommerce.tips |
|---|---|
| Message-ID | <5d982544c5f8b615266ca27a39c39ea1@osCommerce-Forums> |
This message was sent from: Tips and Tricks
http://forums.oscommerce.com/viewtopic.php?p=227553#227553
----------------------------------------------------------------
OSC uses an image even for all the squared corners (/images/infobox/corner_right_left.gif) in your infoboxes as well as the "New Products For..." box, probably for indenting the titles and arrows.
This prevents the text/arrows from showing right next to the border of the table as both cellspacing and cellpadding are set to 0.
But if you still want to get rid of ALL the cornered images (/images/infobox/corner_right_left.gif, /images/infobox/corner_left.gif, /images/infobox/corner_right.gif), you can try the following:
Modify the if/else statements in the
[b]class infoBoxHeading extends tableBox {[/b] block as follows:
[code]if ($left_corner == true) {
// $left_corner = tep_image(DIR_WS_IMAGES . 'infobox/corner_left.gif');
$left_corner = '';
} else {
// $left_corner = tep_image(DIR_WS_IMAGES . 'infobox/corner_right_left.gif');
$left_corner = '';
}
if ($right_arrow == true) {
$right_arrow = '<a href="' . $right_arrow . '">' . tep_image(DIR_WS_IMAGES . 'infobox/arrow_right.gif', ICON_ARROW_RIGHT) . '</a>';
} else {
$right_arrow = '';
}
if ($right_corner == true) {
// $right_corner = $right_arrow . tep_image(DIR_WS_IMAGES . 'infobox/corner_right.gif');
$right_corner = $right_arrow;
} else {
// $right_corner = $right_arrow . tep_draw_separator('pixel_trans.gif', '11', '14');
$right_corner = $right_arrow;
}[/code]
I have just commented out the values of $left_corner and $right_corner and set them to blank, so no image is assigned. It'd be wise to add a [i]space[/i] ( ) for indentation purposes, however.
-----
To remove images from the "New Products For..." box, we've to modify the block of code a little that you mentioned above:
Find:[code]$info_box_contents[] = array(array('params' => 'height="14" class="infoBoxHeading"',
'text' => tep_image(DIR_WS_IMAGES . 'infobox/corner_left.gif')),
array('params' => 'height="14" class="infoBoxHeading" width="100%"',
'text' => $contents[0]['text']),
array('params' => 'height="14" class="infoBoxHeading"',
'text' => tep_image(DIR_WS_IMAGES . 'infobox/corner_right_left.gif')));[/code]
Replace it with:[code]$info_box_contents[] = array(array('params' => 'height="14" class="infoBoxHeading"',
'text' => ''),
array('params' => 'height="14" class="infoBoxHeading" width="100%"',
'text' => $contents[0]['text']),
array('params' => 'height="14" class="infoBoxHeading"',
'text' => ''));[/code]
Again, you can add a [b] [/b] for indenting the title.
I hope this is helpful. :)