I’m doing some work for a client who has an existing shopify website. They want to make some big changes to the site, so i have set up a new development site in shopify, exported all of the products/pages/blog posts to it and am now working on getting all the new functionality/design working on the dev site.
Once the new build is finished though, i want to transfer everything back over to their current site. Products/pages/blog posts will be fine (ive written a custom export/import thing using their api), but what about images?
I am uploading lots of images to the dev site and i am worried they will be deleted when development is finished and i shut down the dev site. Is it possible to transfer over images from one site to another?
Ideally, keeping the same urls on shopifys cdn when doing so, although if i have to change the urls, then i can probably do an automated replace on the csv files that will get uploaded.
There are going to be hundreds of images involved, and they will be used in various places throughout the site, including in the rich text area of pages/blogs, so it’s not going to be practical to do manually in any way, must be something I can automate.
Thanks for any help.
2
Answers
When you export products as a CSV, you get links to your images. You could write a script to download each of the images in the CSV. Just redirect the output of curl to save the image.
Have you tried transferring between the two sites using FTP? If you have SSH Access
ftp <name_or_IP_address_of_other_server>
and your login detailscd
to locate your location / desired destinationbinary
commandhash
if you want a progress barput <filename>
command, and if you want to pull the file from the other server to the one you are logged into useget <filename>
instead.