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.
Could not extract width/height from image: http://www.mysite.tld/sites/default/files/styles/galleria_thumb/public/2.... Traced measures: width:0px, height: 0px.
Works fine in Chrome and Safari.
Comment | File | Size | Author |
---|---|---|---|
#24 | galleria-1.2.6_try_catch_patch.js_.txt | 150.76 KB | pivica |
Comments
Comment #1
miro_dietikerThere are also other issues about that.
Note that the galleria (JS source) plugin itself has also some limitations and (i really hope) they work on this.
You can set some width / height manually in your css for the container and it will work. But since we don't know your params, we cannot set them in our theme.
Comment #2
gumdrop CreditAttribution: gumdrop commentedWhat would be the best example to set them in your theme? Wading through this css is somewhat a nightmare at this time.
This seems to work setting them up with views jqfx galleria. Not a problem there. Thanks for your help.
Comment #3
kroimon CreditAttribution: kroimon commentedHave you tried setting an explicit width and height in your option set?
Comment #4
gumdrop CreditAttribution: gumdrop commentedIf you are referring to the Galleria configuration option settings yes. I am using the default option set which has the height and width specified for example 300 x 400.
As I said above the gallery renders fine under Chrome & Safari browsers. But not under IE or Firefox.
Comment #5
kroimon CreditAttribution: kroimon commentedHm, although I suspect it's a bug in the library and not in the module, would it be possible for you to give us a link to your page where the problem occurs?
If you don't want to post it to the public, you can also send it to me by mail.
Comment #6
kroimon CreditAttribution: kroimon commentedThanks for sending me the link.
I don't know what causes Galleria to fail, I just suspect some unfortunate CSS, but found an issue at GetSatisfaction with a workaround that you can try.
I close this issue here as it's not a bug with the Drupal module.
Comment #7
gumdrop CreditAttribution: gumdrop commented@kroiman ~ Thanks for the link at GetSatisfaction.
I applied:
to galleria-1.2.5.js and this solved my problem.
Comment #8
sdk CreditAttribution: sdk commentedI tried changing the snippet in the .js but it didn't work for me. It workes fine on Safari but not in Firefox.
Comment #9
sdk CreditAttribution: sdk commentedProblem seems to be theme (CSS) related. Works fine in e.g. Bartik. Could you maybe elaborate on your CSS solution?
Comment #10
gumdrop CreditAttribution: gumdrop commentedThe module also pulls in galleria-1.2.5.min.js. So unless you make changes in both the files it may not work.
Comment #11
sdk CreditAttribution: sdk commentedI have applied the change to galleria-1.2.5.min.js as well but no change...
For the problem occurs in connection with the Corolla theme, I opened an issue there
http://drupal.org/node/1313054
I posted the issue also here and got the reply that it could be related to slow servers and / or the div order.
Could still find no solution though.
Comment #12
gumdrop CreditAttribution: gumdrop commentedI am using Corolla as well but with Footheme.
Comment #13
sdk CreditAttribution: sdk commentedWould you be so kind and upload the changed .js files somewhere? eventually I made a mistake in placing the snippet. I tried it twice though...
Comment #14
kroimon CreditAttribution: kroimon commented@sdk: You don't have to change it in both .js files. You can just change it in the non-minified version and delete the minified version. The module will then use the non-minified version, which is way easier to modify.
@all: Can you somehow try setting the Galleria width&height using CSS? If that fixes your problems, I could add an option to the module to set the size via CSS, not the default way of just giving these values to the Galleria javascript.
Comment #15
gumdrop CreditAttribution: gumdrop commented@kroimon, I would of done that in the beginning but Adaptivethemes is a monster to get your head around...especially if you are adding the sub-themes. Also I think Views jQFX Galleria has that option and I experienced no issues with it.
Comment #16
Minotaur Wrangler CreditAttribution: Minotaur Wrangler commentedI'm having this exact same problem RIGHT NOW and I'm using adaptive themes. It hasn't been a fun evening, that's for sure. All the CSS changes I'm seeing floating on the web? Not working. This .js change? Didn't work. When I pulled the plug on the party with minified .js ALL of them stopped working.
I need an answer to this now. How do I get galleria's module to actually work in IE7+ in Drupal? (works fine in Chrome)
Comment #17
kroimon CreditAttribution: kroimon commented@Craigotron: Not the best start to enter a discussion, hm? I understand you're angry, but we're all doing this in our spare time, and we're not the ones who develop the Galleria library, just the Drupal module to embed it into a Drupal site. So if you need an answer "now", then start debugging yourself, which is the same we would have to do otherwise.
To help you a little: I think, the problem somehow depends on the site's CSS. To verify this assumption, please check if it works when you switch to the default Drupal 7 theme (Bartik).
Then, try to temporarily delete/disable one half of your CSS statements of you real theme. If it still errors out, try to disable the other half and reenable the first half. I think you get it. Try to narrow it down to the CSS rule(s) that cause the problem and report it back! :-)
Comment #18
cat-topanga CreditAttribution: cat-topanga commentedI had a similar problem to this...
If you have this line in your css somewhere possibly in a reset or normalize.
img {max-width: 100%;}
Then qualify it or get rid of it...
Worked for me...
Comment #19
kroimon CreditAttribution: kroimon commented@Craigotron:
Would be great if you could check what cat-topanga proposed and report back again!
Otherwise I'll close this issue again in a few days as being fixed...
Comment #20
kroimon CreditAttribution: kroimon commentedComment #22
pivica CreditAttribution: pivica commentedHad the same problem for IE7/8/9. Tried different solutions + updating to galleria 1.2.6 like suggested in http://getsatisfaction.com/galleria/topics/could_not_extract_width_heigh... - this didn't helped also.
On the end the only thing that worked was wrapping that Galleria.raise error with try/catch block like suggested in http://getsatisfaction.com/galleria/topics/could_not_extract_width_heigh...
Comment #23
amirtaiar CreditAttribution: amirtaiar commented@pivica I didnt understand what is the final sintax.
Can you upload the full one?
Thank you
Comment #24
pivica CreditAttribution: pivica commentedHere it is. Changes are on line 4796 and 4797. That two lines are changed with this
Comment #25
amirtaiar CreditAttribution: amirtaiar commentedThank you.
Unfortunately I am still getting the same error..
Comment #26
vb CreditAttribution: vb commentedRun in the same issue. The thread helps to find a solution.
No need to patch the js file, just add to your css
.galleria-content img {
max-width: none !important;
}
Comment #27
alexberendei CreditAttribution: alexberendei commentedthat worked for me, thx
Comment #28
ergophobe CreditAttribution: ergophobe commentedUnfortunately, I've tried both the try/catch fix (#24) and the max-width:none fix (#26) (see my previous thread in #1402952). I've also tried running galleria 1.2.7a2 with and without the try/catch fix.
Firefox, Chrome, Opera all work okay, but no version of IE works at all. At this point, I think I just have to give up on Galleria. Too bad, it's a nice script when it works.
It may help someone to note related/dupes of this here (all mentioned already I think, but just to have them conveniently together)
#1402952
#1313054
https://getsatisfaction.com/galleria/topics/could_not_extract_width_heig...
At this point, I'm just looking for a Galleria alternative.
Comment #29
bryancasler CreditAttribution: bryancasler commentedIE9 Works
Comment #30
rogerex CreditAttribution: rogerex commentedArigato!
Thanks for your help, it work on ie8
Comment #31
ispboy CreditAttribution: ispboy commentedupgraded to the latest galleria (1.2.8), it works fine.
Comment #32
Omar Alahmed#18 worked for me. I'm using zen theme, and it added in its normalize.css
after removing the width and height, it worked.
Comment #33
Minotaur Wrangler CreditAttribution: Minotaur Wrangler commentedI was fairly new to the Drupal community when I posted this. Following up a few things. Shortly after this post I gave up on Galleria - even though I paid for it - and moved on to something else.
Comment #34
fehin CreditAttribution: fehin commentedDownloaded 1.2.9 and it fixed the problem for me.
Comment #35
nathan.bolin CreditAttribution: nathan.bolin commented#26 worked for me, though my galleria content was wrapped in different HTML so:
.galleria-container img {
max-width: none !important;
}
Fixed broken image gallery with multiple error messages:
Could not extract width/height from image: http://www.mysite.tld/sites/default/files/styles/galleria_thumb/public/2.... Traced measures: width:0px, height: 0px.
Comment #36
jwilson3Using Zen theme, but dont want to qualify the img { max-width: 100% }, the fix in #7, also mentioned in this comment here, worked perfectly:
https://getsatisfaction.com/galleria/topics/could_not_extract_width_heig...