Wordpress File permission issue all of a sudden - wordpress

My website had been working well. But recently I started to see some abnormalities.
When I upload a media file, it says the file can't be moved to upload/2022/08; When I create a new post, the featured image choice section on the backend are gone; On frontend, plugin WP-SCSS is reporting file permission issue on the cache folder;
I had to manually change the related folder from 0755 to 0777 to solve these issues. But why all of a sudden it requires 0777 while it never had? The only change I made recently to the server is doing some package upgrade for my linux server. It was a one-click-go and I didn't take a closer look to what had been upgraded but I do remember seeing most items are related to PHP8.0 or PHP8.1. Could this be the reason the file permission issue is acting up?

Related

Getting critical error when installing Wordpress

My hoster forced me to upgrade my Wordpress site because it was fairly old. I decided to upgrade to PHP 8.1. It caused issues with the website, so I figured I'd rebuild the whole website since it's a simple website. I deleted all the existing files and uploaded the 5.8.2 WordPress install files. Then I changed all the permissions to 0755. I created a fresh database for the install.
At first, the setup would appear. I would go through the install, but when I clicked install after entering all the database info, I got "There has been a critical error on this website." I recreated the .htaccess file to the default and tried again. Now I get this error just hitting the domain, no more setup screens. The site does redirect to the /wp-admin/setup-config.php file. I don't have a wp-config.php file in the directory, just the sample one. I tried creating a wp-config.php with the correct info, but same error. I also tried adding the debug options, increasing PHP memory, etc. Same error. I don't get any error logs.
Does anyone now how to get an error log or can help with ideas on how to create a fresh WordPress site? I did change the PHP versions to older ones, but that didn't work either.
You need to take a backup of your file ,then fallow the fallowing instruction.
Rename your plugin one by one and refresh the website.
this issue due to the unsupported plugin ,that is installed in your wordpress website.
1- Make a backup copy of the files and from the old database
2- After that, download these files on your PC
3- Install WordPress again
4- Replace the wp-content file with the old one
5- Clean the new database and import the old database through phpMyAdmin
I solved that problem installing an older version of Xampp, with previous version of php, MySQL and Apache. I give up version 8.1.1
XAMPP 7.4.27 / PHP 7.4.27
https://www.apachefriends.org/download.html
There was something wrong on the hosting side. The source of the issue was indeed that WordPress could not write to the config file. Even the hoster was unable to delete the files. We ended up deleting the entire root directory and starting from scratch. Now it's all good.
The lesson learned is that one of the sources of the "There has been a critical error on this website." error is that WordPress is unable to write/edit files. It's also why it could not write an error log. WordPress could have been more descriptive here.

"mycreatedwpsite.example.com is currently unable to handle this request. 500."

I have developed a site on WordPress.org locally on my computer.
And I wanted to launch the site online.
SO.
I purchased a GoDaddy Domain. I purchased Bluehost hosting.
And wanted to transfer the site from local server to hosting service.
I found a video: https://www.youtube.com/watch?v=cM9Z8aQTCvQ At 2:27 the tutor shows, "Before we export the database we need to change our URL.".
I did it. And I hit the "save changes" button. After that I have been trying solution after solution all over the internet.
Bluehost's ftp manager. Filezilla file transfer. Bluehost's WordPress installation (I imported my theme, didn't work.)
Tried different videos of move WordPress from localhost to server.
I found lots of articles about this problem on Internet. Even Codex WordPress Changing Site URL article.
But nothing from suggested solutions works for me.
And nothing works.
My local site by WAMP server and WordPress.org still looks amazing.
And after typing domain URL web browser still shows "isn't working."
Edit
PHP logs show:
[24-Mar-2016 16:10:50] PHP Fatal error: Call to undefined function
array_replace_recursive() in
/home2/hotelpo5/public_html/wp-content/themes/ta-pluton/inc/post-types/CPT.php
on line 512
One reason that causes this issue is suppressed fatal error. Try enabling error_reporting and display_errors.
If you need to test the settings without modifying php.ini you can use something as below.
ini_set("display_errors", 1);
ini_set("track_errors", 1);
ini_set("html_errors", 1);
error_reporting(E_ALL);
For the future googlers.. for me this was a permission issue which got messed up after I had checked a tag out using Git. So all I had to do was run the following command inside the website root to reset the permissions back to Directories:755 & Files:644.
chmod -R u+rwX,go+rX,go-w ./
Further more the checkout had also messed up the file ownership. So I ran the following command inside the website root to set it back to the specific user:usergroup.
chown -R web1:client0 ./
Note:- Your username:usergroup would vary, so you shall have to adjust the above command to fit your environment.

Fresh Wordpress install on Amazon Linux EC2...can't delete and reinstall

I just recently started by creating a EC2 instance on AWS. I used the Amazon Linux package. I changed the PHP settings to include the ability to upload files larger than 200MB. Got phpinfo.php working. Installed phpMyAdmin. Everything looked good.
Next, I installed Wordpress. It worked great. Then I tried installing a theme. Worked great. Then I started installing some plugins for that theme. Something made the site crash. I tried a few things, but since I couldn't go to the sites Wordpress Admin panel, it seemed hopeless. So I decided to start from scratch. I deleted the html directory (including wp-content) and dropped all the wordpress tables. I moved a fresh copy of Wordpress into the html directory, reconfigured the config.php file, and it recreated the Wordpress tables in the database. Seems to work great. When I try to upload a theme, it says:
Connection Information
To perform the requested action, WordPress needs to access your web server. Please enter your FTP credentials to proceed. If you do not remember your credentials, you should contact your web host.
I noticed that wp-content didn't have a uploads directory, so I created one. That seemed to let me upload the theme, but it showed up as a media file. I moved it to the theme directory and that worked. But when I tried to upload a plugin, I got the same message as a above.
What happened when I deleted everything? Or rather, where was information stored that when I reinstalled Wordpress, it didn't create a uploads directory? I am fine with reinstalling Wordpress from scratch, but I don't want to reinstall the whole LAMP stack or redo the AWS instance. Any thoughts?
The issue is that your web server doesn't have the proper permissions to write to your content directory.
The WordPress Codex has some good info for proper file and directory permissions. Ideally, all files should have 644 permissions, and all directories should be 755 (no higher).
If you're still running into issues adding plugins and updating WordPress, you should heed the advice of the following (so that you don't have to enter FTP details into WordPress each time):
Any file that needs write access from WordPress should be writable by the web server. If your hosting set up requires it, that may mean those files need to be group-owned by the user account used by the web server process.

WordPress Local Install Error (XAMPP) - Page 2 is Blank

I'm trying to install WordPress for local use with XAMPP. I started off by installing and unzipping both the XAMPP and WordPress folders. I placed the XAMPP folder in my C:/ drive and my WordPress folder within the "htdocs" folder. After that, I made a new "config" file for my local server based on the "config-sample" file.
Here's where things get tricky: when I try to use the "install.php" file, I am brought to a screen that asks for credentials. I give it some generic credentials and then I submit it in order to install WordPress. However, when I submit the form, the loaded page is completely blank and the URL appears as "localhost/wordpress/wp-admin/install.php?step=2".
When I go into the database, it shows me that WordPress created all of the necessary tables, but didn't create any log-in credentials for me. I was doing some research and there were a couple pages that mentioned the need for increased PHP RAM, but I'm unsure of how to increase the RAM for local use or if it's even a problem. If anyone had an error like this happen to them, I would really appreciate some feedback as to what could be causing this problem.
I had the same exact problem, with an almost blank screen on step-2 passage.
Adding in wp-config.php these lines solved everything:
define('WP_MEMORY_LIMIT', '128M');
set_time_limit(60);
I've installed Wordpress 4.0 from a zip file on XAMPP 1.8.3 on my Win7-32bit PC.
Setting up the DB and all, I got the same "blank screen" at the step 2.
So, I went in to phpMyAdmin, and edited the "wp_users" table on my entry. I modified the user_login and the user_password (using an MD5 converter). Saved the entry and got into the localhost url for wordpress. Got into the log in, and everything seems to be working without any issues.
As a note: I installed a fresh/clean install so there were no custom themes nor plugins.
Hope that helps.

Cannot see changes in Wordpress in FTP client and vice versa

I am having some problems with Wordpress 3.7. I think they may be related and have something to do with a file ownership/rights issue but I am completely stuck.
I am using the default theme and I have uploaded a new header image
several times through the WP admin interface. Now that I am happy
with the image, I want to delete the old images. Firebug tells me
they are in [my wp root]/wp-content/uploads/2014/01. However, in my
FTP client, this directory is not visible. I only see [my wp
root]/wp-content/uploads/2013
.
When I log into the Wordpress admin interface, it tells me I should upgrade to 3.8. When I tell it to go ahead and give it my FTP credentials, it begins but gets stuck at "Verifying the unpacked files…". I get no error messages and when I give up and leave the page, there are no reports about a failed update. It just keeps showing me the "please update" message.
I am using the default theme and want to change style.css. I cannot do this in the theme editor, it tells me I have to make the file writable first, even after I give all the theme files 777 access in my FTP client (which probably is not a good idea). If I edit the file offline instead and then upload it via FTP, this doesn't have any effect. I can even delete the entire file and still nothing changes at the frontend.
I have tried to create a child theme through the FTP client but it does not show up in the WP backend.
The site is on a shared hosting platform. I can't find the details at the moment but it's a fairly regular setup (Linux, Apache, MySQL). I am testing in Firefox and caching is turned off. If I log out, and log back in again: same problems.
It is almost as if I am FTP-ing the wrong computer but I am really not. What am I missing?
Problem solved. I finally asked my hosting provider and as it turns out they had adjusted a few settings, making them too restrictive.

Resources