After WordPress updated, getting error - wordpress

After updating my client's WordPress site to 4.7 version, could not access the website and wp-admin. I got this error:
Fatal error: Class 'WP_Roles' not found in /webcorp1/www/corpusers/h/y/hyeinfotech.com/wp-settings.php on line 293

Before you update WordPress you should follow the WordPress guideline.
It looks some files are missing related to user_role class. Try updating plugins. If issue not solved try following solutions.
Solution 1: If you have backup then you can restore the website and try update WordPress once again along with all plugins.
Solution 2:
Create a demo/test location on the server/local computer.
Take backup of wp_content folder.
Take backup of Database.
Install a fresh wordpress on the test location.
Import the database backup on step 3 to test location wordpress database.
Replace the content folder on the test location.
Check, if everything works fine then you can move the code and database to current running server.
I hope this solution will work for you. If not you can hire any reliable WordPress Development Agency or Individual to make things done for you.

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.

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.

Folder permissions for Wordpress on Azure

I have recently created a new Wordpress site, on azurewebsites.net. After the initial instal, I updated the PHP version to 5.4 and then resarted the site.
I was having trouble creating new folders, and in paticular, a plugin wasn't working as I would have expected.
The plugin was the WPTouch plugin. I installed the plug, but each time I tried to upload a new image to the
/wp-content/uploads/wptouch/custom-icons
(via the plugin, this was the final destination) I was getting the error message:
There seems to have been an error.
Please try your upload again.
Within Web Matrix 2, I do not have the ability to create a new folder (I thought that I would create the folders myself, and see if that resolved the problem).
So my question is - is there an issue with the folder permissions, and if so, how can I get round this to make the Wordpress plugin work.
Thanks for your time.
I have had similar issues (upgrading WP plugins on Azure Website) and have found the only way to upgrade these is to restart the services, manually delete the remnants in the plugins folder, and re-install.
It's far from ideal but I'm persisting with it for now..
Some more in depth explanations here: http://social.msdn.microsoft.com/Forums/da-DK/windowsazurewebsitespreview/thread/8c4d17e9-520c-4d89-bc7d-efe923dd1a55

How to setup existing Wordpress project on XAMPP

I'm starting some work on an existing wordpress project on Github. Basically, the entire Wordpress install is on Github. I cloned it to my local XAMPP installation. What's the best way to get everything configured? I know I have to make a config file and get WP talking to my MYSQL database. I did that, and while I got the wp-admin stuff working fine, the front-side stuff isn't showing up.
In the database you need to update the links so that they point to your local host.
The way I do that is that I make a backup of the sql database and then replace everything like:
orig:
www.domain.com/site/...
with:
localhost/site/...
And then restore it
In 2020 it's perfect plugin to do this. It's called Duplicator. You need to install it and after it you have 4 steps to configure your installation on which machine it will be running. It's really easy to use, see this link:
https://wordpress.org/plugins/duplicator/

Resources