Closed (fixed)
Project:
Insert
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
21 Sep 2010 at 11:29 UTC
Updated:
3 Feb 2011 at 22:20 UTC
Jump to comment: Most recent file
Hi,
In imagecache.inc, imagecache_create_url function should be used instead of insert_create_url, it doesn't make much difference but if there are any customisations for imagecache (cdn module for example) we get the correct CDN aware path for the image.
Cheers
Dom
| Comment | File | Size | Author |
|---|---|---|---|
| #5 | insert-918072.patch | 1.41 KB | DeeLay |
| #1 | 918072-imagecache-get-url.patch | 871 bytes | DeeLay |
Comments
Comment #1
DeeLay commentedAttached patch
Comment #2
DeeLay commentedComment #3
quicksketchHm, I'm not sure we can make this change because a bunch of whiners are always complaining about relative vs. absolute paths, which is configurable only when using insert_create_url() and not when using imagecache_create_url() (which will always be absolute I think). Are there changes we can make to insert_create_url() that would make it work for you instead?
Comment #4
DeeLay commentedYeah I saw that issue being raised, but figured they would use the $vars['filepath']. Is that not the case?
Comment #5
DeeLay commentedOK, given that we need to have options for relative and absolute URLs, so we can do that using imagecache_create_path and imagecache_create_url.
How about something like this?
Comment #6
quicksketchNice, that looks like it would work for me. I'll need to test and review it.
Comment #7
DeeLay commentedCurrently working fine on economist.com, if that helps ;-)
Using absolute paths.
Comment #8
Mark Theunissen commentedYup, we have been using this for a while.
Comment #9
quicksketchThanks, committed but only to 6.x branch. The 7.x branch doesn't yet support "relative" paths at all due to stream wrappers not generically supporting relative paths.