Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
Node is saved as draft in My Content >> Draft
  • Magento shipping module configuration

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    Comment on it

    To create new magento shipping module need to know all the useful functions to be used inside the shipping method class to put in various configuration options.

    When looking for available shipping methods, Magento first gathers all available carriers. A Carrier represents a shipping carrier, just like in real world (ex. FedEx). Each carrier is represented with the class that extends Mage_Shipping_Model_Carrier_Abstract.

    Following are required steps to create custom shipping module or configure the module as per our requirement.

    1. Register the module:- It is necessary to register new module as below.

    app/etc/modules/namespace_customShipping.xml

    local true

    2. Create the config.xml to set default values in app/local/Namespace/Module/etc/config.xml

    0.1.5 Default name value for the module Default title for the module Namespace/carrier_Customshipping

    3. Create the shipping method class app/code/local/Model/Carrier/Customshipping.php

    getConfigFlag('active')) { return false; } $result = Mage::getModel('shipping/rate_result'); $method = Mage::getModel('shipping/rate_result_method'); $method->setCarrier('customshipping'); $method->setCarrierTitle($this->getConfigData('title')); $method->setMethod('custom_shipping'); $method->setMethodTitle($this->getConfigData('name')); $method->setPrice($this->getConfigData('price')); $method->setCost($this->getConfigData('price')); $result->append($method); return $result; } public function getAllowedMethods() { return array('custom_shipping'=>$this->getConfigData('name')); } }

    4. Create required admin system config fields in app/code/local/Namespace/CustomShipping/etc/system.xml

    text 2 1 1 1 select adminhtml/system_config_source_yesno 1 1 1 0 text 3 1 1 1 text validate-number validate-zero-or-greater 5 1 1 0 text 100 1 1 0 <label>Title</label> <frontend_type>text</frontend_type> <sort_order>2</sort_order> <show_in_default>1</show_in_default> <show_in_website>1</show_in_website> <show_in_store>1</show_in_store>

    shipping payment

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: