Go Premium for a chance to win a PS4. Enter to Win


Weird Wordpress Media Library image preview problem

Posted on 2016-10-02
Medium Priority
Last Modified: 2016-10-11
For starters I moved the site from one server to another like I have done many times before but this is the first time I have seen this problem.

When I go to upload pics in the media library is seems to work fine:

After uploading
But when I go to refresh the page I get this:

After Refresh
If I go to the attachment details it also does not display the picture BUT the path does work and will display the picture in a browser.

Image Details
So really everything works except the preview which kinda makes things a pain in the butt to work with.

Any ideas? Thanks in advance for your help.
Question by:princeservice
  • 6
  • 3
LVL 35

Expert Comment

by:Terry Woods
ID: 41825679
Have you tried using the dev tools in your browser to "inspect" the elements having the problem? This will probably help you find some more information on why it's happening.

Which browser are you using? In Firefox or Chrome, hit F12 to open the dev tools then, right click on one of the image's that's not loading, and choose Inspect or Inspect Element.

Hopefully that will give you the URL of the image that it's trying to load.

Author Comment

ID: 41825701
I tried that but Wordpress is replacing the image for the thumbnail review with this:


and not even going to:


where are the files are. In fact, not that I look, Wordpress is not even generating thumbnails anymore for me.
LVL 35

Expert Comment

by:Terry Woods
ID: 41825780
Are you using cPanel for the server, or just Linux, or something else?
Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.


Author Comment

ID: 41830365

I am using cPanel on a VPS.
LVL 35

Expert Comment

by:Terry Woods
ID: 41831231
I think your PHP installation may be missing the php-gd package.

If you install the plugin "WordPress phpinfo" to your site, activate it, and go to Settings > WordPress phpinfo, then it should have something like included in the output:

Configure Command	'./configure' '--disable-fileinfo' '--enable-bcmath' '--enable-calendar' '--enable-ftp' '--enable-gd-native-ttf' '--enable-libxml' '--enable-mbstring' '--enable-pdo=shared' '--enable-soap' '--enable-sockets' '--enable-zip' '--prefix=/usr/local' '--with-curl=/opt/curlssl/' '--with-freetype-dir=/usr' '--with-gd' '--with-gettext' '--with-imap=/opt/php_with_imap_client/' '--with-imap-ssl=/usr' '--with-jpeg-dir=/usr' '--with-kerberos' '--with-libdir=lib64' '--with-libxml-dir=/opt/xml2' '--with-libxml-dir=/opt/xml2/' '--with-mcrypt=/opt/libmcrypt/' '--with-mysql' '--with-mysqli' '--with-openssl=/usr' '--with-openssl-dir=/usr' '--with-pcre-regex=/opt/pcre' '--with-pdo-mysql=shared' '--with-pdo-sqlite=shared' '--with-pic' '--with-png-dir=/usr' '--with-xpm-dir=/usr' '--with-zlib' '--with-zlib-dir=/usr' '--with-litespeed'

Open in new window

See how the option --with-gd is included. If yours is missing that option, then you need to figure out how to add it, whether it be by contacting the hosting company, or by enabling the option yourself on your own server.

Author Comment

ID: 41831828

Configure Command      './configure' '--disable-fileinfo' '--disable-opcache' '--enable-bcmath' '--enable-calendar' '--enable-exif' '--enable-ftp' '--enable-gd-native-ttf' '--enable-intl' '--enable-libxml' '--enable-mbstring' '--enable-pdo=shared' '--enable-soap' '--enable-sockets' '--enable-sqlite-utf8' '--enable-zip' '--prefix=/usr/local' '--with-bz2' '--with-curl=/opt/curlssl/' '--with-enchant=/usr' '--with-freetype-dir=/usr' '--with-gd' '--with-gettext' '--with-icu-dir=/usr' '--with-imap=/opt/php_with_imap_client/' '--with-imap-ssl=/usr' '--with-jpeg-dir=/usr' '--with-kerberos' '--with-libdir=lib64' '--with-libexpat-dir=/usr' '--with-libxml-dir=/opt/xml2' '--with-libxml-dir=/opt/xml2/' '--with-mcrypt=/opt/libmcrypt/' '--with-mysql' '--with-mysqli' '--with-openssl=/usr' '--with-openssl-dir=/usr' '--with-pcre-regex=/opt/pcre' '--with-pdo-mysql=shared' '--with-pdo-sqlite=shared' '--with-pic' '--with-png-dir=/usr' '--with-pspell' '--with-tidy=/opt/tidy/' '--with-xmlrpc' '--with-xpm-dir=/usr' '--with-xsl=/opt/xslt/' '--with-zlib' '--with-zlib-dir=/usr'

Author Comment

ID: 41831857
Two more things to consider:

When I upload an image the blue bar moves to 100% then it disappears. I get an HTTP error at the bottom of the page. I then refresh the page and I get the generic image placeholder like shown above.

The image does get uploaded
The link created by Wordpress does work if I manually go to it.
The image does not get duplicated and resized for thumbnails and medium size pics.
This is actually happening on the two sites I have moved over from GoDaddy VPS to InMotion VPS.
This is not happening on websites that were originally created on the new server.
I have tried using the default 2015 template vs the DIVI I am using but it still does not work.

It has something to do with the transfer of the site from one VPS to another.

Accepted Solution

princeservice earned 0 total points
ID: 41832339
I seemed to have found the solution:


Author Closing Comment

ID: 41838090
Found the solution myself

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Who says nothing in life is free? WordPress.com is a freebie. WordPress.org's downloadable publishing platform is free. Heck, even WordPressMU is free. WordPress is an open source project, which means it can be used on any personal or commerc…
I annotated my article on ransomware somewhat extensively, but I keep adding new references and wanted to put a link to the reference library.  Despite all the reference tools I have on hand, it was not easy to find a way to do this easily. I finall…
The purpose of this video is to demonstrate how to automatically show related posts at the bottom of a blog post in WordPress. This will be demonstrated using a Windows 8 PC. Plugin “Yet Another Related Posts Plugin” will be used. Go to your…
The purpose of this video is to demonstrate how to reset a WordPress password if you are locked out and cannot reset the password. A typical use would be if you cannot access the email to which WordPress would send the password recovery email to…

783 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question