Issues with lazyload images not loading

+1
0
-1

Hello

I seem to run into this and then it magically fixes itself, and then it starts happening again and I have no clue as to why. If I look at my website, the images are not loading, at all. None of them. It's not an issue with S3 because if I select another theme as default, the images load fine.

What I see if I inspect the blank space where an image should be in html is:

<img data-src="http://MYAMAZONs3URL/s3/image.jpg?oh9AvHfSpR8EJEI2Dclt_yPt5zY.FYRN&amp;itok=-bwnCTtd" src="http://MY-DOMAIN.com/files/tb_wall_lazyload_images/620x410.png" width="620" height="410" alt="">

So, the img data-src is finding the correct image, but the img src is not!

This issue seems to come and go, and I am at a loss on what, exactly, fixes it.

+1
0
-1

Hi Rhino,

First off all, TB Wall theme rely on JavaScript to implement lazy loading images. Therefore, Please check your site's configuration. Are there any configuration or modification which could make the JavaScript code stop working? Which jQuery version is deployed for your site?

Kind regards,
Will

+1
0
-1

I have the latest "JQuery update" module installed, and since I suspected that as the culprit I've tried changing it to "Drupal default" to 1.10 and everything in between. I clear cache and reload theme registry each tme. but see no changes. Perhaps I can edit the important js to be loaded straight html.tpl.php ?

+1
0
-1

SOLVED: The issue has gone away again.

I set the JQuery to 1.10 last night, and have been using another theme for an entire day. Upon re-enabling the TB_wall theme I can now see the images.

Some sort of caching issue must have been in the way. Like I said, it's amystery issue that comes and goes - but I'm noting here that jquery 1.10 works if anyone else runs into it.

+1
0
-1

Another Issue I had, which I thought was related to Lazy load, was that I had blank images in Google Plus, Facebook and Twitter.

To remove that do this:

Find - template.php
Delete or comment the function tb_wall_process_image from line 272 to 287.

*function tb_wall_process_image(&$variables) {
if (isset($variables['width']) && isset($variables['height'])) {
$variables['attributes']['data-src'] = file_create_url($variables['path']);
$file_url = tb_wall_create_blank_image($variables['width'], $variables['height']);
$variables['path'] = $file_url;
}
else {
$size = tb_wall_get_image_size($variables['path']);
if(isset($size[0]) && isset($size[1])) {
$variables['attributes']['data-src'] = file_create_url($variables['path']);
$file_url = tb_wall_create_blank_image($size[0], $size[1]);
$variables['path'] = $file_url;
}
}
}
*