How to Fix the “Are You Sure you want to do This” Error in WordPress (4 Methods)

Do you keep getting the “Are you sure you want to do this” error message while working on your WordPress site? You’re probably wondering what’s causing it and if there’s a way to get rid of it. This warning can be very unsatisfying because it doesn’t really tell you what the matter is. Plus, it prevents you from performing basic tasks on your site, like editing blog posts.

The “Are you sure you want to try this” error can happen for several reasons. You’ll have installed a faulty plugin or theme, otherwise, you could be experiencing a security issue. Luckily, you’ll determine the exact cause and fix the error in a few simple steps.

In this post, we’ll check out the main causes of the “Are you sure you want to do this” error in WordPress and show you ways to fix it using four methods. Let’s get started!


What the “Are You Sure you want to do This” Error Is


The “Are you sure you want to do this” issue usually crops up while you’re performing some tasks on your WordPress site. For example, you’ll be trying to publish a post or customize your theme when the error message appears, preventing you from completing the work.



WordPress uses security tokens, called nonces, to verify that you have the proper permissions to perform a specific action on the site. These nonces help protect your site against hacking attacks. Therefore, when the “Are you sure you want to do this” error message pops up on your screen, it means that WordPress was unable to know you as the rightful owner or user of your site.

Various factors can trigger this verification failure. Next, we’ll take a look at the leading causes.


Potential Causes of the “Are You Sure you want to do This” Error


The “Are you sure you want to do this” error message doesn’t pinpoint exactly what the matter is. However, we can narrow down the problem to a few causes.
Below are four common reasons you’ll be seeing this error:

1. You’ve selected an incorrect file when uploading a plugin or theme.
2. You’re using a plugin or theme with incorrect code.
3. You need to extend your PHP memory limit.
4. You’re facing a security problem due to corrupted files.

The most likely scenario is a faulty theme or plugin on your site. To figure out what’s causing the problem, however, you’ll need to do some troubleshooting.


How to Fix the “Are You Sure you want to do This” Error in WordPress (4 Methods)?


Now, let’s go through the four main methods for fixing this common WordPress error. Before proceeding, you’ll want to perform a backup of your site just in case something goes wrong and you need to restore an earlier version.


1. Check Your Plugins


As we mentioned earlier, the “Are you sure you want to do this” error might be caused by a faulty plugin on your site. To find out if this is the case, you’ll deactivate your plugins and reactivate them one by one.

Note that for this step, you’ll need to access your site’s root directory using a Secure File Transfer Protocol (SFTP) customer like FileZilla or by logging into your web hosting account and using the file manager.

If you have a Servers Gate account, you’ll navigate to WordPress > Managed WordPress in the sidebar, find your domain, and choose Manage.



On the next page, click on the Manage Files button in the Details section. In the file manager, open the folder with your domain name.

In your site’s root directory, locate and open the wp-content folder. To deactivate your plugins, you’ll find the plugins folder and rename it to “plugins test”.



Return to your WordPress site. If the error message doesn’t reappear, you know that a plugin caused the problem.

The next step is to find out which one is the culprit. First, navigate back to your site’s root directory and rename the plugins test folder back to “plugins”.

Next, go to the Plugins page in your WordPress dashboard. Activate the first plugin, then check to see if the error is still present. Continue activating them one by one and testing your site until you find the plugin causing the error. Then you’ll replace it, or reach out to its developer for help.


2. Switch to a Default WordPress Theme


If deactivating your plugins doesn’t resolve the problem, it’s time to see if your current theme may be to blame. We’ll do this by switching to the default WordPress theme.
Once again, you’ll need to access your site’s root directory. To switch to the default WordPress theme, you’ll open the wp-content folder, locate the themes folder, then rename it to “themes test”.



After renaming the folder, your site will automatically revert to the default WordPress theme. To see if this solves the matter, return to your site and carry out the same tasks that caused it before.

If the “Are you sure you want to do this” message doesn’t come up, your previous theme must have been at fault. As with your plugins, this means you may need to update or replace your theme (or get in touch with its developer for assistance).


3. Increase Your PHP Memory Limit


If disabling your plugins and switching themes didn’t do the trick, the problem could be your WordPress PHP memory limit. If your current limit is set too low, it can interrupt certain processes.

There are different ways to go about this. If you’re a Servers Gate user, you’ll increase your PHP memory limit by editing your per file. For other WordPress users, you’ll go through your php.ini or wp-config.php file.

By default, the limit is set to 256M. However, you’ll add a line of code to the file to extend the limit. For instance:

memory_limit = 300M

You can choose whatever value you want. Save the file, then reload the WordPress page displaying the error to see if this has resolved the issue.


4. Replace All Your Core WordPress Files with Fresh Copies


If the above three methods didn’t fix the error, it’s possible that a number of your WordPress files became corrupted due to recent malware or hacking attack. To confirm this, you’ll replace all of the WordPress core files with fresh copies.

Again, we recommend that you perform a backup of your site first. When you’re done, you’ll need to access your site via an FTP client. While you’ll also use the file manager in your web hosting account for this method, it’ll be quicker to replace your site’s files using an FTP customer.

In the root directory, locate and download the wp-config.php file.



Next, you’ll delete all WordPress files and folders in the root directory except for the wp-content folder, which contains your plugins, themes, and media. Then download the newest version of WordPress to your computer and extract the .zip file.

Locate and copy the wp-config.php file you downloaded, and paste it into the extracted WordPress file.



The final step is to upload the WordPress files on your computer to your site. These new files will replace those that we deleted in the root directory.

If you’re using FileZilla, choose every item in the WordPress file on your computer except the wp-content folder, then right-click and choose Upload.



The uploading process may take a few minutes. Once it’s complete, you can return to your WordPress site, and the error message should be gone.


Banish This WordPress Error Message


The “Are you sure you want to do this” error may prevent you from performing basic WordPress tasks. While a defective theme or plugin commonly causes it, it can also arise if you’ve reached your PHP memory limit or your site’s facing a security issue.

To resolve the “Are you sure you want to do this” error, you’ll try these four solutions:

1. Deactivate your plugins and reactivate them one at a time.
2. Revert to the default WordPress theme.
3. Increase your PHP memory limit.
4. Replace all WordPress core files with fresh copies.

Troubleshooting WordPress problems can be time-consuming. If you want to spend less time dealing with WordPress errors, you might want to think about switching to Servers Gate. Our managed WordPress hosting plans accompany full technical support for site owners, also as daily backups to assist keep your content safe.

 

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How to Change the WordPress Admin Username

This tutorial will explain the way to change the WordPress admin username with a simple-to-use...

How to Set Up Caching on a WordPress Website

In this article, we’ll explain the way to set up caching in WordPress using a popular plugin....

10 Ways to Optimize Your WordPress Website for Speed

You can’t afford to waste a second on the internet. Speed matters, particularly when it involves...

How to Fix the “Briefly Unavailable for Scheduled Maintenance” Error in WordPress

Is your website stuck in maintenance mode? During updates, WordPress displays a temporary notice...

How to protect WordPress website using Google ReCAPTCHA

What is ReCAPTCHA?ReCAPTCHA is a free Captcha service from Google. It assistances to protect...