Hi to everyone,
Once again I'll try to custom my OSCMax with adding a box under (of before) the information one.
To do that, I took the modification guide in french who told how to proceed.
OK, I begin.
First step :
Adding New Boxes, Links and Pages
We will now look into adding our own custom boxes, as well as adding/changing links, pages and graphics to boxes. In addition, we will learn how to add items to the columns, outside of the actual boxes. All of these modifications are fairly easy to perform, but they are not entirely intuitive (understatement!). Making a New Box
Let’s jump right in. The files involved are: /catalog/includes :
1. column_left.php 2. column_right.php/catalog/includes/boxes : ALL files in this directory
Open /catalog/includes/boxes/information.php in a text editor and save it as /catalog/includes/boxes/test.php.
That's the easy way and it's done.
Now second step :
Then in column_left.php, add this line:
require(DIR_WS_BOXES . 'test.php');
directly below this line:
require(DIR_WS_BOXES . 'information.php');
Save column_left.php to your server, and reload the main catalog page in your browser. You will now see two information boxes on the left. The second one we just added with one line of code.
And there is the problem, can't find the require(DIR_WS_BOXES . 'information.php') other way as comment.
Here is what I finded out in the : includes\column_left.php file :
/*
$Id: column_left.php 3 2006-05-27 04:59:07Z user $
osCMax Power E-Commerce
osCommerce Documentation by OSCdox :: osCommerce and osCMax documentation
Copyright 2006 osCMax
Released under the GNU General Public License
*/
// BOF: MOD - INFO BOXES - now pulled dynamically as per setting in admin
/*
if ((USE_CACHE == 'true') && empty($SID)) {
echo tep_cache_categories_box();
} else {
include(DIR_WS_BOXES . 'categories.php');
}
if ((USE_CACHE == 'true') && empty($SID)) {
echo tep_cache_manufacturers_box();
} else {
include(DIR_WS_BOXES . 'manufacturers.php');
}
require(DIR_WS_BOXES . 'whats_new.php');
require(DIR_WS_BOXES . 'search.php');
require(DIR_WS_BOXES . 'information.php');
require(DIR_WS_BOXES . 'test.php');
*/
$column_query = tep_db_query('select configuration_column as cfgcol, configuration_title as cfgtitle, configuration_value as cfgvalue, configuration_key as cfgkey, box_heading from ' . TABLE_THEME_CONFIGURATION . ' order by location');
while ($column = tep_db_fetch_array($column_query)) {
$column['cfgtitle'] = str_replace(' ', '_', $column['cfgtitle']);
$column['cfgtitle'] = str_replace("'", '', $column['cfgtitle']);
if ( ($column[cfgvalue] == 'yes') && ($column[cfgcol] == 'left')) {
define($column['cfgkey'],$column['box_heading']);
if ( file_exists(DIR_WS_BOXES . $column['cfgtitle'] . '.php') ) {
require(DIR_WS_BOXES . $column['cfgtitle'] . '.php');
}
}
}
// EOF: MOD - INFO BOXES - now pulled dynamically as per setting in admin
Can someone give me an idee to find my way in the modification guide.
Thanks for all your help.





LinkBack URL
About LinkBacks










Bookmarks