!!! This instruction will not work for CS-Cart and Multi-Vendor 4.4.1 and latest versions
Let's image that we should add the Royal Mail carrier. We will use royal_mail string as carrier identifier.
The tutorial is actual for CS-Cart and Multi-Vendor 4.x
1. Versions 4.0.x-4.2.x: Create the var/database/new_carrier.sql file with the following content:
Versions 4.3.x: Create the var/backups/new_carrier.sql file with the following content:
INSERT INTO ?:shipping_services (`status`, `module`, `code`, `sp_file`) VALUES ('A', 'royal_mail', '', '');
2. Versions 4.0.x-4.2.x: Log in the admin panel, go to Administration -> Database -> Restore page, select the
new_carrier.sql file and restore it.
Versions 4.3.x: Log in the admin panel, go to Administration -> Backup/Restore page, select the
new_carrier.sql file and restore it.
3. Go to Administration -> Languages -> Translations page and create new language variable:
Language variable: carrier_royal_mail ("carrier_" + carrier identifier)
Value: Royal Mail
4. Versions 4.3.5-4.3.x: Go to point #6
Versions 4.0.x-4.3.5: Edit the design/themes/THEME/templates/common/carriers.tpl file of your CS-Cart installation and replace this part of code:
{else}
with this one:
{elseif $carrier == "royal_mail"} {$url = "http://www.royalmail.com/portal/rm/track?trackNumber=`$tracking_number`"} {$carrier_name = __("royal_mail")} {else}
where $url means the URL which enables your customers to see carrier delivery tracking information without the need to link to the carrier website. If you do not know such URL, just leave it empty:
{$url = ""}
5. Edit the design/themes/THEME/mail/templates/common/carriers.tpl file and apply the same changes there
6. Versions 4.3.5-4.3.x only (!): Open the app/schemas/shippings/carriers.php file and add:
'royal_mail' => array( 'tracking_url_template' => 'http://www.royalmail.com/portal/rm/track?trackNumber=[tracking_number]', ),
after the following lines of code:
'usps' => array( 'tracking_url_template' => 'https://tools.usps.com/go/TrackConfirmAction_input?qtc_tLabels1=[tracking_number]', ),
7. Clear the cache ( Administration > Storage > Clear cache )
8. Check the result
See also:
- [url="http://forum.cs-cart.com/topic/37510-how-to-add-custom-css-with-my-changes-addon/"]How To Add Custom Css With My Changes Addon[/url]
- [url="http://forum.cs-cart.com/topic/37758-how-to-add-custom-javascript-with-my-changes-addon/"]How To Add Custom Javascript With My Changes Addon[/url]