Skip to content
WP Intense Q & ACategory: External ImagesExternal Variation Images & WP All Import
Kyle Iverson asked 1 year ago

Hi Dave,

1) I created a custom field called 'external_image_url' in WP All Import and images are importing. Most are under the same met_key that was created, but some are added under '_external_image_url'.

2) Variation images aren't importing. I manually added an external image url to a variation and can see in the database that it used the met_key '_external_image_url', but variation images don't seem to be working with WP All Import.

Everything else is setup correctly, as I was using an alternative plugin to import external images.

3 Answers
Kyle Iverson answered 1 year ago

Please ignore. Everything seems to be working fine now.

Dave Hilditch Staff answered 1 year ago

To clarify on the meta fields:

external_image_url is the field you import to. This is ideally pipe | separated list of image URLs, but it can also be comma separated. Preferably pipe though because some images on some CDNs will include commas.

The first of those images is loaded into the _external_image_url field as an image array.

The gallery images (everything after the first image from external_image_url) are loaded into the _ei_wcgallery field as an array of arrays. This approach makes it fast to pull those arrays in the correct format needed for WordPress.

If you later update the external_image_url field, there is an action hook added to update_post_meta and delete_post_meta which will rebuild the hidden _external_image_url and _ei_wcgallery fields.

So – basically, don’t import to the hidden fields – just import to the external_image_url field with pipe separation between image URLs and the plugin will handle the rest. That’s the same for everything – products, product variations, posts, custom posts etc.

If you are using custom posts, the custom posts need to declare gallery support in order for the gallery to work in custom posts.

Also – there is a bug in the currently live version when editing an existing custom post gallery – it won’t apply the changes currently – this is fixed in beta which is in your downloads area in My Accounts.

Kyle I. replied 1 year ago

Hi Dave, I have separate imports for featured and gallery images. I’ve imported all featured images to external_image_url. If I import all gallery images to external_image_url, will the featured image be replaced or will it just add additional images to the product gallery?

Dave H. Staff replied 1 year ago

They will be replaced. When the external_image_url field gets updated, it causes a function to run to update the hidden _external_image_url to be an array image version of whatever list of images is in external_image_url. The first image will be the featured image, all others will be gallery images. I did in the past have a separate field for gallery images and I could reintroduce this if you wish – this would mean that you could, optionally, keep 1 featured image in the external_image_url field and then your gallery images into a different meta field.

Mark Taylor replied 1 year ago

I second the option of being able to specify a main product image in one field, and gallery images in another field.. as an option but it would be great if but could work both ways

viales.matavz answered 7 months ago


Can images of product versions be imported with the WP All Import plug-in?

And how?

I am attaching a picture

Come chat to me on our Discord server to ask questions - Dave Hilditch, WP Intense

We use cookies

We use cookies for various things on our site, including our on-site chat bubble (if you use it), our comment forms (if you use them) and for session handling (if you log in).

Other than that, we use cookies to identify where traffic came from to help us understand which traffic turns into sales, we use a cookie for Google Analytics traffic analysis and we use a cookie to customise adverts for our own products we think you'll be interested in.

You can read more detail in our privacy policy page. Please click 'Accept' or 'Decline' to continue.