RO CSVI

Article Index

Import HikaShop Category Images

This article explains on how to import images of HikaShop Categories using CSVI. Before starting with import there are few preperations to be done. The default path for saving HikaShop images is the upload path set in HikaShop configuration page. You can check this path by going to Joomla administrator menu >> Components >> HikaShop >> System >> Configuration and under Files section. Make sure that you want to use the same folder for your images. 

csvi hikashop configuration

csvi hikashop files section

Next step is to upload all the images to this folder so CSVI will link these images to categories on import.

How does CSVI know where to locate your images? This is a combination of 2 settings:

  1. Path set in the HikaShop Configuration for Upload folder
  2. Name in the CSV file

On import CSVI combines these 2 settings to get the full path to the image. As an example the path in the configuration is set to images/com_hikashop/upload and the file_path field in the CSV file is set to example.jpg. This will create a full path of images/com_hikashop/upload/example.jpg. This is the correct path.

And using the category_path field in import file, CSVI will link the image to the category.


Preparing the template

Images are imported using HikaShop Category import template. You can have any number of fields for your category import but to import images make sure you also have file_path field as one of the import fields.

csvi hikashop category import template


Adding the fields

Your template might already have some fields, for the images we require two needed fields:

  • category_path
  • file_path

category_path
The full path of the category

file_path
The name of the image to link to the category. Multiple images seperated by |. Example image1.jpg|image2.jpg|image3.jpg


Setting the template image options

The Image tab has a lot of options for managing your images. For now we will look at the general options. The most important option here is the Process images. 

  • Yes
    This means that CSVI will perform all the image options set for example, create a thumbnail
  • No
    This means that CSVI will not do any image processing.

csvi hikashop image general options

We set the Process images to Yes and then configure the thumbnail settings because we want to let CSVI create a thumbnail.

To enable the thumbnail creation set the option Automatic thumbnail creation to Yes and if you want set the thumbnail size you would like.

 


Creating the import file

In your import file, you need to add column to import image

  • file_path
    Here you put the name of the main image for example hammer.png

Let's create our CSV file, extending the CSV file created in the HikaShop Category Import tutorial, we now get:

category_path,category_type,category_description,category_published,file_path
shoes/men-shoes,product,Category for organising men shoes,1,menshoes.jpg
shoes/women-shoes,product,Category for organising women shoes,1,womenshoes.jpg

Save these 2 lines in a file or download the file by clicking here.

This completes the second step of the image path, we now have a complete path of images/com_hikashop/upload/menshoes.jpg


Import time

With our template configured and our file created, we are ready to import.

  • Select the template from the CSVI import page.
  • Click on Select File.
  • On the source option we will load the file from our computer. Click on Choose File and select your import file. Then click on the Preview button in the top right hand corner.
  • The list of fields in CSV would be shown as preview. Now click on Start import in the top right hand corner.
  • Run the import

csvi hikashop category image import


What's next?

The next thing you can do is, experiment. There are a lot of more features in CSVI you can use for example:

  • Watermark images
  • Store remote images on your server
  • Resize large images

Watermark images

Watermarking images with CSVI is made easy. Set the Watermark image option to yes and upload the image you need to use as watermark and its done. CSVI will do the rest.

csvi hikashop water mark image

Store remote images on server

With CSVI it is possible to import images from remote server. On Image tab set Save images on server option to Yes and in file_path give the remote URL of the image. Thats it. CSVI will download the remote image to your local server and link it to the category.

csvi hikashop save image on server

Resize large images

While importing images if you want to resize the large images set Resize image option to Yes and set the required height and width.

csvi hikashop resize image

More articles on this subject