| 4.2. Shipping Modules |
| Prev | Chapter 4. Creating or modifying Extensions | Next |
|---|
Shipping modules are located in the directory
/administrator/components/com_virtuemart/classes/shipping/
and have three files: the class file, the information file and the configuration file.
Example: Module "myShipping"
You must have three files, called
myShipping.php (including the class
myShipping)
myShipping.ini (containing the Name
of the Module & the Author and the File Version..)
myShipping.cfg.php (containing all
necessary configuration constant definitions)
The shipping rate, a user has selected during checkout is passed from step to step by the parameter shipping_rate_id.
This parameter follows a strcit syntax and must be a string build like this:
ShippingClassName|carrier_name|rate_name|totalshippingcosts|rate_id
For our example the shipping rate id for one rate could be:
myShipping|My Carrier|My Rate Name|45.00
The last field (rate_id) can be left empty. The shipping_rate_id parameter is always passed as an urlencoded string.