Support from Acquia helps fund testing for Drupal Acquia logo

Comments

merlinofchaos’s picture

Priority: Normal » Major
Status: Active » Needs review
FileSize
1.71 KB

This patch fixes it to support any entity type, using token.module's entity mapping. While I haven't rigorously tested this, it does work with an image field on a term entity.

It also has the beneficial side effect of fixing notices caused by blindly setting the image-field type on tokens for fields that aren't actually on the nodes (because they're only on other entity types).

silkogelman’s picture

it seems to work well.

Tested by checking if Taxonomy tokens show up in the Metatag Token list (they did, screenshots attached).

I haven't been able to actually make a og:image metatag with a image-token show up, but that could be a Metatag issue (or a 'me' issue)

Thanks for this patch!

seandunaway’s picture

Status: Needs review » Reviewed & tested by the community

Works great, let's get it in. :)

yannickoo’s picture

Works fine!

Pls’s picture

Works great, not sure why there's no official release with this patch. Let's do it! Would love to hear a word from module maintainer. Thanks.

askibinski’s picture

Patch works great, nice little module!

jwilson3’s picture

How about entities attached to entities (eg, field_collections)? This patch doesn't work for my specific case of wanting to grab the first image of a slideshow in a taxonomy term via a multiple-item field collection.

eg [term:field-slideshow-slides:1:field_slide_image:my_image_style_preset_name]

I guess this is sufficiently special-case that it should be a separate issue.

Bartezz’s picture

Works like a charm!

Hydra’s picture

Patch doesn't apply with the "latest" dev version. Rerolled it. Otherwise the Patch does what I would expect the module to do, thanks earl!
@maintainer: Please commit this! It's RTBC now for quit a lot of time.

Hydra’s picture

nevermind, ignore #9, I wasn't on the right branch >.< stupid!

Confirm that #1 is working!

Hydra’s picture

Status: Reviewed & tested by the community » Closed (fixed)

Commit 2a1a8ae on 7.x-1.x, Thanks!