Imagecache_external: Thumbnails of external URLs aren’t accessible

Modules:

Imagecache External, Media, Remote Stream Wrapper

Scenario:

I created a content type, in which I want to collect Movie Actors. My aim is to add images of those actors which arent hosted on my drupal site itself. They are being linked via Remote Stream Wrapper but RSW doesnt allow to use Image Styles on those external images (for example thumbnails). The solution is Imagecache External, which allow Image Styles even on external hosted images.

Problem:

  • Imagecache External returns Image-URLs which ends with a cryptic snippet, which resolves into an error message: Access denied

    localhost/drupal/sites/default/files/styles/cover/http/img4.picload.org/image/acdcwwi/imagestyle_examp.png%3Fitok%3DAyQfRnDQ

  • Thumbnails are being saved in a directory, which represents the URL of the external image:

    drupalsitesdefaultfilesstylescoverhttpimg4.picload.orgimageacdcwwiimagestyle_examp.png

Detailed Problem Description:

Imagecache External creates thumbnails with such URLs:

localhost/drupal/sites/default/files/styles/cover/http/img4.picload.org/image/acdcwwi/imagestyle_examp.png%3Fitok%3DAyQfRnDQ

If I open this URL directly, I get an “Access Denied” error because I dont have permission for that page (-> even as an admin!?). If I remove this cryptic snippet at the end of the URL (%3Fitok%3DAyQfRnDQ), the Thumbnail is accessible.

The other problem is that the thumbnails are saved in a directory, which is equal to the external URL:

drupalsitesdefaultfilesstylescoverhttpimg4.picload.orgimageacdcwwiimagestyle_examp.png

This will result in a not overviewable directory tree.

The external image I linked externally for example is this one:
http://img4.picload.org/image/acdcwwi/imagestyle_examp.png

I hope anybody has a solution to my problem. :-/

Greetings,
KG

This article was republished from its original source.
Call Us: 1(800)730-2416

Pixeldust is a 20-year-old web development agency specializing in Drupal and WordPress and working with clients all over the country. With our best in class capabilities, we work with small businesses and fortune 500 companies alike. Give us a call at 1(800)730-2416 and let’s talk about your project.

FREE Drupal SEO Audit

Test your site below to see which issues need to be fixed. We will fix them and optimize your Drupal site 100% for Google and Bing. (Allow 30-60 seconds to gather data.)

Powered by

Imagecache_external: Thumbnails of external URLs aren’t accessible

On-Site Drupal SEO Master Setup

We make sure your site is 100% optimized (and stays that way) for the best SEO results.

With Pixeldust On-site (or On-page) SEO we make changes to your site’s structure and performance to make it easier for search engines to see and understand your site’s content. Search engines use algorithms to rank sites by degrees of relevance. Our on-site optimization ensures your site is configured to provide information in a way that meets Google and Bing standards for optimal indexing.

This service includes:

  • Pathauto install and configuration for SEO-friendly URLs.
  • Meta Tags install and configuration with dynamic tokens for meta titles and descriptions for all content types.
  • Install and fix all issues on the SEO checklist module.
  • Install and configure XML sitemap module and submit sitemaps.
  • Install and configure Google Analytics Module.
  • Install and configure Yoast.
  • Install and configure the Advanced Aggregation module to improve performance by minifying and merging CSS and JS.
  • Install and configure Schema.org Metatag.
  • Configure robots.txt.
  • Google Search Console setup snd configuration.
  • Find & Fix H1 tags.
  • Find and fix duplicate/missing meta descriptions.
  • Find and fix duplicate title tags.
  • Improve title, meta tags, and site descriptions.
  • Optimize images for better search engine optimization. Automate where possible.
  • Find and fix the missing alt and title tag for all images. Automate where possible.
  • The project takes 1 week to complete.