Can't Upload Images or Plugins via Wordpress Admin - wordpress

I have a website that I just transferred from one server to another. I did this by copying all the files via FTP from the old server to my computer and then to the new server. I changed the URL in Settings to the new url and I downloaded a copy of the database. I then uploaded the database to the new server and changed all the database info in the wp-config file. Afterwards I used Velvet Blues Update URLs to make sure all the URLs have been changed in the database.
After doing all the the website is working fine. I could update my plugins and my WordPress core files that needed updated.
The problem is now I can't upload a plugin from my computer or any media files like images. When uploading an image, I get this message:
“image.jpg” has failed to upload.
Unable to create directory uploads/2017/03. Is its parent directory writable by the server?
I checked and this directory is already on the server. In FTP I changed the folder permissions to all be set to 775.
I then tried to change the folder structure for media files to not be broken into month/date folders and I get this message:
“image.jpg” has failed to upload.
Unable to create directory uploads. Is its parent directory writable by the server?
I know this directory exists and is set to 775. To double check I also change the wp-content directory to the same permissions.
What am I doing wrong here? Why can't I upload images and plugins via the WordPress backend?

I actually think I figured this out. I went into Settings -> Media and noticed there was a box that says Store Uploads to This Folder and had a folder for the old website. I deleted the information that was in that box and updated the settings and now it works!

I had this exact issue today. After much troubleshooting, I solved this images not uploading issue -- specifically, when I clicked the upload button, no dialog window appeared. As a new WordPress installation, the dashboard was displaying asking if this was going to be a business or personal site. When I clicked I DON'T NEED ANY HELP, then I saw the normal dashboard with WooCommerce module displayed and I was able to upload media files and images from my hard drive.
I'm posting in case this answer can help someone else having this very weird problem. Also, it is possible that a plugin like OpinMonster might be what generated that "business or personal" message.

Related

Wordpress Server unable to read htaccess file, denying access to be safe

I am running wordpress on my own managed server so I have complete access to the box. The issue I'm having is that users can upload images to my image library but any uploaded are not loading due to 403 errors.
When I go directly to one of the images I get the message "Server unable to read htaccess file, denying access to be safe"
I have set the permissions on the .htaccess file and all files to 775 but it made no difference.
I also tried nuking the file and uploading a new .htaccess from a fresh wordpress download in case it was corrupted but it made no difference.
The strange thing is the images do display in one context, when you use the wordpress image editor.
Not sure what to do about this, I'm a drupal developer and only have a passing familiarity with wordpress.
Example working legacy image:
http://www.bonnybridgeanglingclub.com/wp-content/uploads/2016/06/DSC_0671.jpg
Example broken recent image:
http://www.bonnybridgeanglingclub.com/wp-content/uploads/2017/02/652-1024x640.jpg
Any help would be greatly appreciated.
It turned out the problem was that for some reason when the 2017 directory was created inside the uploads folder it was created with the wrong permissions, very odd, I've fixed the permissions and all is well now.

Folder permissions for custom Wordpress uploads folder

I have created a new Wordpress website on my server and done everything as I normally would (nothing fancy or custom, just upload theme, a couple of plugins etc.) except I wanted a custom file path to my media folder.
I have created the folder '/public_html/i', updated my .htaccess file, updated the Setting > Media section in Wordpress with the file path and all is working fine.
My issue is that I do not want the uploads folder to be visible by navigating to the URL (www.site.com/i/).
If I change the folder permissions to execute only for group / world (711) the images become unavailable / unviewable and although I can still upload they show as broken images.
If I set to execute and read (755) the images and uploads work fine but the folder can be viewed by typing in the URL.
What are the correct permissions I should be using for a custom uploads folder to make images on the site viewable but the containing folder itself not?
Note that this is a site that will regularly have new images uploaded to it, so I would also need to be able to upload without having to change the permissions each time, which is one solution I have found online.
Thanks in advance for any help.
Add the following to your .htaccess file with the WordPress .htaccess instructions:
Options -Indexes

wordpress database not showing in PhpMyAdmin

I am new to wordpress and have bought udesign theme from themeforest. from my Plesk I have installed WP and then from the dashboard of WP tried to upload the theme, but failed. hence went directly to dedicated server and hosted on the root folder.
Theme started reflecting on the dashboard and I have started customization. Once site completes I need to move the site to production server. When I check PhpMyAdmin from the plesk, it shows there is no DB table. how do I copy/move the site without DB?
Can i manage site without PhpMyAdmin? like copying the entire assets to new server and it starts working automatically?
Please help me to find DB or Let me know how to work with the themes to make sure everything in right place.
Many Thanks,
Gururaj
If you’ve ever had the need to find the name of your WordPress database, then there’s an easy way to do that – simply look for it in your wp-config.php file located in the root folder of your WordPress install.
Accessing Your WP-Config.php File
If you are doing something where you need the name of your database, then I’m assuming you have access to your server.
Simply go to the main folder of your WordPress install and locate the file called wp-config.php.
Edit file and find name in:
define('db_name','your database here');

How to move Wordpress to another domain without the chance to make a proper backup first?

So my webhoster closed down, where I hosted my Wordpress blog. I was able to receive a zip file containing all my data. I now have a new webhoster and I extracted the zip file to its root directory.
Trying to open my website now gives me "Error establishing database connection". The web tells me it may be related to hardcoded urls in the Wordpress database, which I need to replace by the new url.
However the tutorials usually tell you to use the Wordpress interface to create a backup of my database first, which can then be edited in tools like phpmyadmin. I can not access the Wordpress interface anymore and so far did not manage to edit the database otherwise.
I tried placing a local copy of the blog in the "C:\xampp\htdocs" folder, hoping phpmyadmin would recognize the database and allow me to edit it. Not working, maybe I am doing something wrong?
Any ideas to revive my Wordpress blog?
Cheers
Okay I think I got it working. For people having the same issue:
I loaded the database locally by copying the *.myd, *.myi, *.frm files to a new folder in my local xampp installation (e.g. C:\xampp\mysql\data\myDatabase).
I then used phpmyadmin to export this database to a .sql file.
On my webserver I then installed a fresh wordpress blog. It might be enough to copy your existing wordpress stuff, without needing to do this step afterwards, not sure.
My webhost has phpmyadmin preinstalled, so I used that to delete the fresh wordpress databases and import the .sql file instead. Now everything is in place, but since I changed my domain I need to change the URL paths in the database.
I used this script (use it by placing it on your webserver in the wordpress root folder and calling it in the browser) to do a search&replace of my old url to the new url: https://interconnectit.com/products/search-and-replace-for-wordpress-databases/
After that I only had to manually fix the path to my header image that I had edited in the past in the theme's header.php file.
Phew. Thanks for your help f00644.

My wordpress isnt coming up after I put it into my ftp client

So i have uploaded my unzipped wordpress files onto my filezilla ftp client and put them in a folder. But when I check the domain.com/wordpressfolder I keep getting a 404 this url does not exist on the server. Not sure what im doing wrong because there were no failed transfer when uploading onto my ftp. Could I have done something wrong on the hosting server side(bluehost) or should that not matter?
Basically all you need to do is download WordPress zip. Unzip files and open wordpress folder. After that select all and transfer them into root directory. When all files will be uploaded, open Tutorial and go through it.
Please make sure that the file you are uploading is a theme file or a complete wordpress file. If it is a theme file, you need to activate it in the admin panel. If it is complete wordpress file, please make sure that you are uploading it to the right location.

Resources