• Hi everybody,

    Since this morning, my images are inserted in my post (using the “insert into post”) with an empty src attribute. The upload of the images works perfectly fine and if I write the src by myself, the images are displayed…

    This is the kind of code the “Insert into post” give me :

    <img src=”” alt=”my-nice-picture” class=”aligncenter size-large wp-image-89943″ />

    My WP is installed on a dedicated server, and I uptated to 3.6.1 for a while now. The weird part is that EVERYTHING WAS WORKING FINE until this morning ! I did’nt make any change or update, and suddenly the “insert into post” was inserting images without a SRC…

    I already tried multiple browsers, deactivating all plugin, changing theme, clearing cache, and even reinstalling wordpress…

    Any idea ?

Viewing 5 replies - 1 through 5 (of 5 total)
  • Try checking your site’s error logs for clues. Your hosts should be able to help you accessing your site’s error logs.

    Thread Starter ufunk

    (@ufunk)

    Hi Esmi, thanks ?? I’m on a dedicated server with full access.
    While having the issue, my browser JS console stay clear, but in my server log I found this :

    Resource interpreted as Image but transferred with MIME type text/html: "https://mywebsite.com/wp-admin/". editimage.min.js?ver=358-20121205:1
    wpImage.getImageData editimage.min.js?ver=358-20121205:1
    wpImage.setup editimage.min.js?ver=358-20121205:1
    (anonymous function)

    Any idea ? (the weird part is that this was working yesterday !)

    Hmm – that looks like it might be a server issue. Uploaded images seem to be interpreted by the server as MIME type text/html! Have you spoken to your hosts about it?

    Thread Starter ufunk

    (@ufunk)

    As seen on the web :

    “The most common way to get the (Resource interpreted as Image but transferred with MIME type text/html) is with the following code: <img src=””/> . A blank url is a shortcut for the current page url, so a duplicate request is made which returns content type html. The browser is expecting an image, but instead gets html.”

    So the error I found in my log is created because the SRC is empty.
    So it is not “the SRC is empty because of this error”.

    But why this SRC is empty ? Can’t figure it out…

    Thread Starter ufunk

    (@ufunk)

    Ok, this is getting weirder and weirder…
    I just tried to upload a new picture, and to insert it : everything works fine !

    For an inexplicable reason, I can’t insert into a post images uploaded between yesterday and 10 minutes ago. The SRC stay empty (but if I write the src manually, the picture is displayed).

    But old pictures works fine, and now new pictures works fine too !
    I clearly understand nothing on what’s going on here… ??

    Well, for now at least I can upload and insert pictures again !
    (I just hope that this strange problem won’t occur again in the future…)

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Insert image to post is broken: inserted img has an empty SRC’ is closed to new replies.