Hi all,

im using feed import to import my node from D7 to D8, but I'm facing some issue to do mapping for image caption & photo credit, I'm not able to find them under Target section, any help?

Thanks
Yong Ceih LEE

Comments

lyceih created an issue. See original summary.

megachriz’s picture

Status: Active » Postponed (maintainer needs more info)
StatusFileSize
new159.33 KB

For images, you can map to the following:

  • File
  • Alt
  • Title

Where in Drupal's UI can you configure the caption and photo credit for an image field?

This is how my admin screen for editing an image field looks like. I don't see 'caption' or 'photo credit' mentioned here:

vlooi vlerke’s picture

Title: Trying to map Image Caption & Photo Credit » Core Media module: Trying to map Image Alt, Caption & Photo Credit
Status: Postponed (maintainer needs more info) » Active
StatusFileSize
new12.53 KB
new18.86 KB

With Drupal core media module you can add fields to images.

You can add a Caption field and a Photo credit field for example.

With the patch found over here: https://www.drupal.org/project/feeds/issues/2928904
You can import images via feeds into a core media image field.

This is how the feed mapping looks for a media image field
media feed

Currently there are no other image feed mappers available like Alt and Title.

This is how a normal image mapping looks like.

media feed

These existing image field mappers should be available to the media image field.

Secondly all extra fields that gets added to an image field should also show up as image feed mappers.
Example: Caption and Photo credit fields.

Users that used the D7 media module and have extra fields in the media image will need these feature to upgrade to D8/9

vlooi vlerke’s picture

Priority: Critical » Normal

Setting this to normal. It cant be that critical.

vlooi vlerke’s picture

Status: Active » Needs review

This feature exists already, but not on the Feeds Node processor but the Feeds Media processor.

Create a new image import feed.
Select the Feeds Media processor and select Media type image.
Under mapping you will find all the image targets like Alt, Title and your own custom fields like Caption.
Add Name mapper and set it to use your image file name.
Add your media image field and set it to use your image file name.
Use feeds tamper to point your image file name to its correct path in your files directory.
Import your images as media.

Create a new content import feed.
Select the feeds content processor and a content type like articles.
Under mapping add your media image reference field and select Name as reference
Import your articles.

Your articles will now contain images that reference media images.

irinaz’s picture

Issue tags: +GlobalSprint2022
irinaz’s picture

Issue tags: -GlobalSprint2022 +ContributionWeekend2022
kristen pol’s picture

Category: Feature request » Support request

Switching to support request based on #5.

@lyceih Please try the approach from #5 and let us know if that works or doesn't work for you. Thanks!

kristen pol’s picture

Issue tags: -Feeds, -Image Caption, -Photo Credit

Cleaning up unnecessary tags.

sportch’s picture

Category: Support request » Feature request
Issue tags: +Feeds, +Image Caption, +Photo Credit

@Vlooi Vlerke Any chance you know of a video or documents to set this up? Not sure which tamper I need to use to set file dir.

kristen pol’s picture

Category: Feature request » Support request
Issue tags: -Feeds, -Image Caption, -Photo Credit

@sportch Did you mean to revert the changes I did in #8 and #9? Maybe you hadn't refreshed your page. If you have a reason for reverting these, please comment. Thanks.

socialnicheguru’s picture

I setup a separate feed to import images using media core.
I do not see the alt or media title fields

mapping import targets
mapping media image feeds
mapping media image imports

socialnicheguru’s picture

deleted comment - wrong issue

dennis cohn’s picture

StatusFileSize
new86.18 KB

@SocialNicheGuru, I don't see the "media processor"
Did you install an extra module for it?

EDIT: Never mind... enabled the media module, duh! :)

dennis cohn’s picture

@Vlooi Vlerke

Add Name mapper and set it to use your image file name.
Add your media image field and set it to use your image file name.
Use feeds tamper to point your image file name to its correct path in your files directory.
Import your images as media.

Is it possible to explain this part a bit more?
I can't get this part to work...

dennis cohn’s picture

I've added some screenshots. I keep getting errors while importing my images.
Anyone who managed to upload media succesfully from the public folder?

bkosborne’s picture

lyceih never responded, but I suspect #5 would not be helpful to them, as they're likely trying to import to a node that has a media reference field on it, and want to create the media at the same time.

ptmkenny’s picture

Status: Needs review » Active