srhoden
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: 'Unable to create directory /wp-content/uploads.'resolved
Forum: Fixing WordPress
In reply to: 'Unable to create directory /wp-content/uploads.'Alright so I finally fixed it by changing the uploads path in wp-config.php from
define( ‘UPLOADS’, ‘/wp-content/uploads’ );
to
define( ‘UPLOADS’, ‘../wp-content/uploads’ );
I’m not quite sure why this worked and I thought I had already tried it, but I’m glad I can finally upload images. Thanks Ross for helping me out with this issue.
Forum: Fixing WordPress
In reply to: 'Unable to create directory /wp-content/uploads.'Thanks for working with me on this so far. My wp-config.php file had this:
/* Set debug mode based on current ENV */
if ( WP_LOCAL_SERVER || WP_DEV_SERVER ) {define( ‘WP_DEBUG’, true );
define( ‘WP_DEBUG_LOG’, true ); // Stored in wp-content/debug.log
define( ‘WP_DEBUG_DISPLAY’, true );define( ‘SCRIPT_DEBUG’, true );
define( ‘SAVEQUERIES’, true );} else if ( WP_STAGING_SERVER ) {
define( ‘WP_DEBUG’, true );
define( ‘WP_DEBUG_LOG’, true ); // Stored in wp-content/debug.log
define( ‘WP_DEBUG_DISPLAY’, false );} else {
define( ‘WP_DEBUG’, true );
}I looked for a debug.log file in wp-content but found nothing. Then I commented all that out and added the code you posted. I deliberately changed a function name to get an error, and it did show the error directly on the page in the browser, so I think I set it up correctly. When trying to upload the images it still just shows the same error as before though.
I’m not sure exactly where the error logs are located, but I think I found the apache logs that we want. Inside the directory
/var/log/apache2
are a lot of access.log and error.log files. I opened the first error log called error.log but there doesn’t seem to be anything related to the problem in there. It goes all the way up to error.log.52.gz so I checked a few more logs out and still didn’t see anything that seemed relevant.
Forum: Fixing WordPress
In reply to: 'Unable to create directory /wp-content/uploads.'I just did that and then tried uploading a few different images and still no luck. I went ahead and looked into
/etc/apache2/envvars
and it says `export APACHE_RUN_USER=www-data
export APACHE_RUN_GROUP=www-data`I right clicked on the uploads folder to double-check who owns it and right now the owner says Me and the group is www-data. I tried changing the owner to www-data as well but that didn’t work either.
Forum: Fixing WordPress
In reply to: 'Unable to create directory /wp-content/uploads.'Alright I tried doing what you suggested but it still isn’t working. I did all of the following from the terminal. First I went into the wp-content directory and removed the uploads folder. Then I recreated the uploads folder and entered
sudo chgrp www-data uploads/
Next I did
chmod g+w uploads/
and then finished by doing
chmod 775 uploads/
I tried uploading a couple of different images and get the same error each time.
Any other ideas as to what might be going on?