Here is the code of my config.xml file for my module. Take a look at the code and suggest me where I am wrong. I am new to magento and does not know much about the declarations used in the config file. Any help will be appreciated.
<?xml version="1.0"?>
<config>
<global>
<models>
<xyz_xyzshipping>
<class>Xyz_Xyzshipping_Model</class>
<resourceModel>xyz_xyzshipping_resource</resourceModel>
</xyz_xyzshipping>
<xyz_xyzshipping_resource>
<class>Xyz_xyzshipping_Model_Resource</class>
<entities>
<custom>
<table>xyz_xyzshipping_custom</table>
</custom>
</entities>
</xyz_xyzshipping_resource>
</models>
<resources>
<xyz_xyzshipping_setup>
<setup>
<module>Xyz_Xyzshipping</module>
</setup>
</xyz_xyzshipping_setup>
</resources>
<blocks>
<xyz_xyzshipping>
<class>Xyz_Xyzshipping_Block</class>
</xyz_xyzshipping>
</blocks>
<helpers>
<xyz_xyzshipping>
<class>Xyz_Xyzshipping_Helper</class>
</xyz_xyzshipping>
</helpers>
</global>
<default>
<carriers>
<xyz_xyzshipping>
<active>1</active>
<sort_order>10</sort_order>
<model>xyz_xyzshipping/carrier</model>
<title>Xyz Shipping</title>
<sort_order>10</sort_order>
</xyz_xyzshipping>
</carriers>
</default>
</config>
You need to use installer script that consists sql code.
You can refer following link
http://www.amitbera.com/create-an-magento-extension-with-custom-database-table/
This is tutorial for creating basic extension with custom table.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With