Lost password?    Lost username?    Create an account
OverviewDownloadsForumSupport
CSV Improved

CSV Improved

Override import/export routines

Requirements

  • CSVI 4.0+ / CSVI Pro 4.0+

Background information

An override is where you create your own routine and place it in a specific folder for CSVI to use. This way you can add or modify the behavior of CSVI when importing or exporting to suit your own needs. The override system allows for great flexibility so you can write your own import/export routines and not having to worry that by updating CSVI your changes are lost.

Creating an override routine

The default location for import routines is administrator/components/com_csvi/models/<component>/import and for export routines administrator/components/com_csvi/models/<component>/export

The problem with having your modification in the CSVI folder is, when you update CSVI your modification is lost. Instead of putting your modification directly in the CSVI folder you can put it in your template folder.

1. Location

The import routine overrides are located in the folder:
administrator/templates/<template>/html/com_csvi/models/<component>/import/


The export routine overrides are located in the folder:
administrator/templates/<template>/html/com_csvi/models/<component>/export/

  • <template>
    This refers to the administrator template e.g. khepri
  • <component>
    This refers to the component you are doing the import or export for e.g. com_virtuemart

The default administrator template in Joomla is khepri, so the location of the import routines for VirtueMart becomes:
administrator/templates/khepri/html/com_csvi/models/virtuemart/import/

The default administrator template in Joomla is khepri, so the location of the export routines for VirtueMart becomes:
administrator/templates/khepri/html/com_csvi/models/virtuemart/export/

2. Procedure

To use the override feature take the following steps:

  1. Copy the import routine you want to modify to the override folder e.g. You can copy the administrator/components/com_csvi/models/com_virtuemart/import/productimport.php to administrator/templates/khepri/html/com_csvi/models/com_virtuemart/import/productimport.php
  2. Modify the productimport.php file that has been copied to the override folder to your needs
  3. Perform the import

You can follow the same steps for export by changing the folder import to export.

TESTIMONIAL

A reliable component with excellent support.
5 stars
2014-08-20
I had to purchase CSVI to perform massive product imports to Virtuemart, including multiple image files for each product. I was amazed of the ease of use and the full customization of the templates. The support is truly awesome, making this component's purchase totally worth it!

STAY INFORMED


Stay informed with the CSVI newsletter.