osCommerce Knowledge Base
Add Text to the Model Number | Last Update: 24th July, 2005 Article ID: 254 |
- Introduction
- Solution
Introduction
A model number is usually listed as "DVD-DHWV" or something similar. It can be listed as "Item #DVD-DHWV" or a different prefix before each model number in the store.
Solution
The define for the text is added as "MODEL_PREFIX" and the product_info.php page is changed to carry that define.
First, add the MODEL_PREFIX define to the catalog/includes/languages/english.php file:
// model prefix
define('MODEL_PREFIX', 'Item #');
In the product_info.php about line 96 find this code:
$products_name = $Qproduct->value('products_name') . '<br><span class="smallText">[' . $Qproduct->value('products_model') . ']</span>';
Change To:
$products_name = $Qproduct->value('products_name') . '<br><span class="smallText">[' . MODEL_PREFIX . $Qproduct->value('products_model') . ']</span>';
