No limit
Never grew up

How to modify WordPress theme through phpMyAdmin database

I bought a theme and want to try it on this WordPress blog. How can I add a new domain name to the other party without replying to the QQ message? Let's preview it first.

When previewing the results, an error is reported, prompting "The domain name is not authorized to use the theme!"

Because the theme is not enabled, I think it doesn't matter. I just close the browser and go to sleep. As a result, when I opened the website at noon today, I found that the whole site had this prompt, and the background of WordPress could not get in, and even the theme could not be changed back.

Later, when an inspiration came to me, I changed the subject directly after MySQL data. I found this method.

Open the phpMyAdmin management background, find the corresponding database, enter the following code in SQL and execute it:

 SELECT *  FROM wp_options  WHERE option_name = 'template'  OR option_name = 'stylesheet'  OR option_name = 'current_theme';

The following results are obtained:

From the picture, what I am using now is Cosy The theme, of course, is the result of the change.

There are two ways to modify a topic:

1、 Directly modify the value of database option_value. Double click to fill in the subject name you want to specify. Generally, the default is default and classic.


2、 Or execute the SQL statement:

 UPDATE wp_options SET option_value = 'default' WHERE option_name = 'template'; UPDATE wp_options SET option_value = 'default' WHERE option_name = 'stylesheet'; UPDATE wp_options SET option_value = 'default' WHERE option_name = 'current_theme';

You can also change "default" to the specified theme name.

Sometimes, for the sake of safety and simplicity, unused topics will be deleted. If they are deleted, they need to be uploaded to the WordPress/wp content/themes/folder now.

reference resources: https://www.jb51.net/cms/69651.html

Like( zero ) Reward
Do not reprint without permission: Zigen's blog » How to modify WordPress theme through phpMyAdmin database

comment six

  1. #-19

    Amazing, and this operation!

    Mr.Chou Three years ago (2021-07-09) reply
  2. #-18

    I haven't seen you for a few days, so I changed to robin. I can't comment yesterday, I can comment today~ 😉

    zlprime Three years ago (2021-07-11) reply

Reward the author of the article if you think it is useful

Thank you very much for your reward, we will continue to give more high-quality content, let's create a better online world together!

Scan Alipay and reward