problem with import directories for files to be imported

I have a custom made importer, that uses AvS_FastSimpleImport. Anyway, importing the products and every other attribute is fine. The problem comes with importing the images. If I have the directory hierarchy like that:

project_name/media/import/(the .xml file of the product + the images files)

the images are being imported all fine. But there's a new requirement the hierarchy to be done the following way:

project_name/media/Import/XML/(the .xml file of the product)
project_name/media/Import/Images/(the images files)

then the images are not being imported. All other configurations in config.xml files and in the back-end are set up correctly, according to the different hierarchy cases, so mis-setting of options is not the problem.

My suspicion is that there is some convention of directory hierarchy which therefore makes the importing not working if the hierarchy is some custom. Is that the case?

Additional info: in the second hierarchy case - there are no folders and files created in the /media/catalog/product where the pictures to be imported should be copied, as it should happen as follows project_name/media/catalog/product/X/Y/XYimagename.jpg

Solutions

Found out. Just for whoever will stumble upon similar problem, here's the answer:

Magento core code has a hard-coded line, that searches for images (to be imported) in `...media/import' directory. You can see this line in

app/code/core/Mage/ImportExport/Mode/Import/Entity/Product.php    -> line 1405

So, if you want the images (that are to be imported) to be taken from another folder, different from /media/import, then you'll have to override the upper mentioned model class. :)

Similar questions

Protect Magento Directories
I am just about to put a Magento site live and wondered what the best method is to protecting Magento's directories. At the moment I have simply stuck in the following into my htaccess This only protects the /var folder should I protect any others and is this the best way?
Magento2 Missing write permissions to the following directories: 'site/public_html/pub/static'
unfortunately i get this error when I try to do a magento2 setup upgrade I tried but I don't see any changes, what can I do? thanks
why there are block,controller, model directories in magento module?
Can anyone explain why should we write our code in different directories while creating module? Can't we just write our block code in controller? if we put our model,block files in controller .will module work?
Magento 2 product images not showing, 2 different directories
Magento2 is looking directly in the root folder for media and static files. It is not looking in pub/media folder. Product images are not showing in the front. I installed Magento 2 in a subdirectory and with the installation. I imported the products with Storemanager Emagicone, images were in import file (in root/media and pub/media because i did ...
understanding magento directories
I am new to magento and don't have a magento2 directory because I installed it into public_html. I ran bin indexer:reindex but got message -bash: bin: command not found Please tell me how to fix this error: "One or more indexers are invalid. Make sure your Magento cron job is running." This confuses me Magento Officially Doc Thanks for your attenti...
Explanation of app/code vs vendor directories please
I'm looking for an explanation of the app/code/[vendor] and vendor/[vendor] directories? (For M2.1) Some online sources (such as inchoo) say to put a new module in app/code/[vendor], yet in 2.1 there is no such directory, and modules are conspicuously in vendor/[vendor]. Meanwhile the official doc page on the Magento file system say "information wi...

Also ask

We use cookies to deliver the best possible experience on our website. By continuing to use this site, accepting or closing this box, you consent to our use of cookies. To learn more, visit our privacy policy.