Post by bg17aw » Thu Jul 13, 2017 7:25 pm

Hello, any idea how to figure out the correct link to images?
I am exporting products to a .csv file, but having issues exporting images.
I am using the image field in the product table, but there is a problem:

- in the product table, the image name is something like "catalog/products/1113/whatever.jpg"
- I am manually adding the prefix "http://example.com/image/cache/" so image URL becomes "http://example.com/image/cache/catalog/ ... atever.jpg"
- however, this is not working, as actual image links are changed to catalog/products/1113/whatever-600x451.jpg
- who/what is adding the "-600x451" part and how can I manage to export correctly?

PS: I know there are multiple images per product in the images table, but for now, I would like to solve the first issue.

Newbie

Posts

Joined
Thu Jan 19, 2017 2:44 am

Post by uksitebuilder » Thu Jul 13, 2017 10:59 pm

Original image URL is:

http://www.yourstore.com/image/ -- Then the image field value from the product table in your DB

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom

Post by bg17aw » Fri Jul 14, 2017 9:10 pm

uksitebuilder wrote:
Thu Jul 13, 2017 10:59 pm
Original image URL is:
http://www.yourstore.com/image/ -- Then the image field value from the product table in your DB
Thanks a lot for that.
Could you by any chance suggest a solution to export the additional images as well?
The ones from the images table, I need a query that would concatenate them in one long string, comma separated

Newbie

Posts

Joined
Thu Jan 19, 2017 2:44 am

Post by uksitebuilder » Fri Jul 14, 2017 9:54 pm

Is this a script you have created yourself ?

If so, simply joining the product_image table to the product table on product_id will give you all the images for a specific product. The URL for the additional images is the same format as the main image. Shouldn't be a problem then concatenating the fields together using a bit of logic/testing.

User avatar
Guru Member

Posts

Joined
Thu Jun 09, 2011 11:37 pm
Location - United Kindgom
Who is online

Users browsing this forum: Baidu [Spider], Semrush [Bot] and 16 guests