Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
7.x-1.2 and 7.x-1xdev
Fatal error: [] operator not supported for strings in /homez.194/ikino/www/sites/all/modules/panopoly_images/panopoly_images.module on line 89
line 89 in file "panopoly_images.module" :
-------------------------------------
$variables['attributes']['class'][] = str_replace('_', '-', $variables['style_name']);
i removed this "[]" saved, uploaded file to server and now it's ok, site working.
can u fixe this for other pople, same bug in thx.
Comments
Comment #1
dsnopekMoving to main issue queue.
Comment #2
lsolesen CreditAttribution: lsolesen commentedCould you supply the exact steps to reproduce on a clean install and which version of PHP are you using?
Comment #3
lsolesen CreditAttribution: lsolesen commentedComment #4
lsolesen CreditAttribution: lsolesen commentedComment #5
lsolesen CreditAttribution: lsolesen commentedDuplicate of #2181263: HP Fatal error: [] operator not supported for strings in panopoly_images/panopoly_images.module on line 90
Comment #6
stephenls CreditAttribution: stephenls commentedIn my case, this happened because I was rendering a image using theme_image_style(), but did not contain the class for the image in an array:
So, this:
rather than this:
Perhaps something similar has occurred here?