Following the discussion in #1358896: Flexible scheme and URI for image derivatives and the patch in #2610308: Flexible TokenQuery for image derivatives I'd like to integrate the hook_image_style_uri_token_query_alter() invocation also for the Picture module.
This patch allows third party modules to alter how the image style URL is generated, in particular the module I am working on provides external image delivery and on-the-fly manipulation behind a CDN.

The Picture module adds the ?timestamp= to images URLs, thus breaking the CDN and the image manipulation service.

The patch adds the hook and does not alter the standard URL creation if no modules implements it.

Comments

thePanz created an issue. See original summary.

thepanz’s picture

Status: Active » Needs review
StatusFileSize
new864 bytes

Patch attached.

jcnventura’s picture

Adding a related issue regarding the image_suppress_itok_output variable.

thepanz’s picture

StatusFileSize
new925 bytes

Updated patch, following review on #2610308: Flexible TokenQuery for image derivatives.

czigor’s picture

Status: Needs review » Reviewed & tested by the community

This should work even without the core patch in #2610308: Flexible TokenQuery for image derivatives so marking this RTBC. (The only thing is that hook_image_style_uri_token_query() won't be documented until the core patch gets committed.)

  • attiks committed 0600162 on 7.x-2.x authored by thePanz
    Issue #2610318 by thePanz: Flexible TokenQuery for image derivatives
    
attiks’s picture

Status: Reviewed & tested by the community » Fixed

Committed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.