Lazy Load
Spaces in image urls: thumbs not loaded (3 posts)

  1. Veerle Verbert
    Posted 3 years ago #


    I'm using Lazy Load and it works like a charm, only when my client uploaded an image with a space in the filename... it breaks (no image showed)

    I get:
    <img width="100" height="75" 002.jpg"="" src="[...]/<strong>thumbs_Poefff</strong>" style="display: block;" data-lazy-loaded="true">

    <img width="100" height="75" src="[...]/<strong>thumbs_Poefff 002.jpg</strong>" style="display: block;" data-lazy-loaded="true">

    any idea how to handle this?
    can I prevent users uploading images with spaces in the filenames?

    thx for any suggestion at all (except for educating clients, believe me: i try ;)


  2. Veerle Verbert
    Posted 3 years ago #

    OK, sorry: is a next gen gallery issue: images added through the media library get a nice hyphen for each space on upload, but next gen images keep their spaces..

  3. Veerle Verbert
    Posted 3 years ago #

    the plugin checks explicitly for a space as the end of the src attribute (src ends with ', ", space or closing img tag).

    i would suggest to change this: i think spaces in img url's appear more frequent than non-quoted attributes: the first is user dependent, the latter the responsability of the theme developer. OK, nextgen is a plugin, but a user can also embed an image from a different source than WordPress.

    but probably there are other arguments ;)

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Lazy Load
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic


No tags yet.