Vote to Improve PrestaShop

PrestaShop Forum: Build a free online shop. Count on the Community!

The best place in the world to ask questions about PrestaShop and get advice from our passionate community!

PrestaShop Forum: Build a free online shop. Count on the Community!

Jump to content

 
Photo

Prestashop 1.5 CSV import problem

CSV import import problem v. 1.5

  • Please log in to reply
24 replies to this topic
constantina

    PrestaShop Apprentice

  • Members
  • PipPip
  • 73 posts

Posted 16 January 2013 - 02:06 PM

Hi,

I installed a clean new version of prestashop 1.5. Everything was almost alright until i try to import my old 1.4 CSV files. I've updated files according to 1.5 columns. But i still had issues with importing products properly.

1- All products go under home. I tried both writing category IDs and category names. No way, everything's under home.

2- No product images. I gave img URL both as http://domain.com/folder/imaj.jpg and ../folder/imaj.jpg and my imgfolder and custom imgfolder permissions are 777.

So, at last, i have products without images under home category instead of under custom category when i import my product CSV file.

Is there anyone experienced a problem like this, or anyone has to say anything?

Server information

Server information: Linux #1 SMP Tue Nov 9 13:34:42 EST 2010 i686
Server software version: Apache/2.2.3 (CentOS)
PHP version: 5.2.16
Memory limit: 48M
Max execution time: 30

Database information

MySQL version: 5.1.54
MySQL engine: InnoDB

Store information

Prestashop version: 1.5.3.1
Current theme in use: default

eadi

    PrestaShop Newbie

  • Members
  • Pip
  • 8 posts

Posted 16 January 2013 - 05:03 PM

I have exactly the same problem. Didn't find any solution, working for hours.

eadi

    PrestaShop Newbie

  • Members
  • Pip
  • 8 posts

Posted 16 January 2013 - 06:58 PM

I found the solution:
1.for category : in csv type Categories (x,y,z...) instead of Categories (x,y,z,...)
2. I found a fix for images: replace content of controllers/admin/AdminImportController.php
with https://github.com/P...e3ebe473233d07.

This works for me.


Find the github link here:
http://www.prestasho..._1#entry1060749

Edited by eadi, 16 January 2013 - 07:01 PM.


constantina

    PrestaShop Apprentice

  • Members
  • PipPip
  • 73 posts

Posted 17 January 2013 - 04:24 PM

Hello eadi,

Thanks for sharing your solution.

Can you please explain "1.for category : in csv type Categories (x,y,z...) instead of Categories (x,y,z,...)". I don't understand it.

Thanks

constantina

    PrestaShop Apprentice

  • Members
  • PipPip
  • 73 posts

Posted 17 January 2013 - 05:35 PM

Yeah, editing AdminImportController.php also worked for me. Thank you very much!

piemant@yahoo.it

    PrestaShop Newbie

  • Members
  • Pip
  • 8 posts

Posted 18 January 2013 - 12:46 PM

Hello eadi,

please explain "in csv type Categories (x,y,z...) instead of Categories (x,y,z,...)"
Is it just a matter of a comma in the field?

Thanks

Edited by piemant@yahoo.it, 18 January 2013 - 12:53 PM.


piemant@yahoo.it

    PrestaShop Newbie

  • Members
  • Pip
  • 8 posts

Posted 18 January 2013 - 02:57 PM

I've found this solution:

The problem is that the $temp var isn't being assigned, so no file is opened.
To solve it, change this line:

$fd = fopen($temp, 'r');
By
$fd = fopen(_PS_UPLOAD_DIR_.$uniqid, 'r');

in AdminImportController.php file

Has worked for me on Prestashop 1.5.3.

Edited by piemant@yahoo.it, 25 January 2013 - 11:19 AM.


ricky11

    PrestaShop Apprentice

  • Members
  • PipPip
  • 277 posts

Posted 25 January 2013 - 10:22 AM

Still not understand how this was solved... is this a import bug?

ricky11

    PrestaShop Apprentice

  • Members
  • PipPip
  • 277 posts

Posted 25 January 2013 - 10:34 AM

Can't seem to import products to certain categories, its always going to HOME category!

Any way out?

piemant@yahoo.it

    PrestaShop Newbie

  • Members
  • Pip
  • 8 posts

Posted 25 January 2013 - 11:19 AM

Can't seem to import products to certain categories, its always going to HOME category!

Any way out?

I think it's a bug. Try the solution I've suggested: you have to change the code in AdminImportController.php file.

ricky11

    PrestaShop Apprentice

  • Members
  • PipPip
  • 277 posts

Posted 26 January 2013 - 08:00 PM

Thanks solution worked. hope they resolve it in future releases.

netwide

    PrestaShop Newbie

  • Members
  • Pip
  • 1 posts

Posted 31 January 2013 - 02:22 AM

this works. You need to apply both fixes in this thread for it to work properly.

e.negrobov

    PrestaShop Newbie

  • Members
  • Pip
  • 2 posts

Posted 14 February 2013 - 10:24 PM


Piemant, thank you for the solution. I spent 3 days trying to upload images and one day on cateories without any results. You are the hero :mellow:


Maury Markowitz

    PrestaShop Apprentice

  • Members
  • PipPip
  • 259 posts

Posted 15 February 2013 - 03:31 PM

People in this thread: are you saying that *no* images were uploading?

I do get *most* images, but *some* do not appear. I cannot see a pattern.

eadi

    PrestaShop Newbie

  • Members
  • Pip
  • 8 posts

Posted 15 February 2013 - 04:12 PM

Hello eadi,

Thanks for sharing your solution.

Can you please explain "1.for category : in csv type Categories (x,y,z...) instead of Categories (x,y,z,...)". I don't understand it.

Thanks


First line in csv. Take a look to at provided example in prestashop admin

deejay3

    PrestaShop Newbie

  • Members
  • Pip
  • 19 posts

Posted 21 February 2013 - 01:34 PM

thx, it's working on 1.5 but how to fix categories in 1.4.9.0?

rasegan

    PrestaShop Newbie

  • Members
  • Pip
  • 3 posts

Posted 21 February 2013 - 03:47 PM

I found the solution:
1.for category : in csv type Categories (x,y,z...) instead of Categories (x,y,z,...)
2. I found a fix for images: replace content of controllers/admin/AdminImportController.php
with https://github.com/P...e3ebe473233d07.

This works for me.


Find the github link here:
http://www.prestasho..._1#entry1060749


The link is not working, can you please tell me how i can edit the "controllers/admin/AdminImportController.php" its not working for me also. Thank you waiting to hear from some one.

cutecat

    PrestaShop Apprentice

  • Members
  • PipPip
  • 237 posts

Posted 08 March 2013 - 06:58 PM

how can I upload more than 1 jpg file? I have more than 1 picture to upload.

I have already uploaded to my server and only one picture was shown on my product. the other files are not imported to the product.

Also I would need to import in the "Additional shipping cost (per quantity):". it does not have this too.

For those who are having issue to upload their CSV, you need to go into controllers/admin/AdminImportController.php

$fd = fopen($temp, 'r');
By
$fd = fopen(_PS_UPLOAD_DIR_.$uniqid, 'r');

in AdminImportController.php file

Which was stated by piemant@yahoo.it

Thanks piemant for that. :)

cutecat

    PrestaShop Apprentice

  • Members
  • PipPip
  • 237 posts

Posted 13 March 2013 - 11:33 AM

any updates for Additional shipping cost (per quantity): to be added into CSV import?

Dmit

    PrestaShop Apprentice

  • Members
  • PipPip
  • 204 posts

Posted 09 April 2013 - 04:42 AM

Import of products in the category with the same name - if you go knowing the product he is in the right category, but if you go through the menu in this category is writing that no items in this category?????

Prestashop 1.5.4





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users