$conf, $runtime; function_exists('chdir') AND chdir(APP_PATH); $r = 'mysql' == $conf['cache']['type'] ? website_set('runtime', $runtime) : cache_set('runtime', $runtime); } function runtime_truncate() { global $conf; 'mysql' == $conf['cache']['type'] ? website_set('runtime', '') : cache_delete('runtime'); } register_shutdown_function('runtime_save'); ?>php - HTTP ERROR 500 after installing child-theme [Wordpress]|Programmer puzzle solving
最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

php - HTTP ERROR 500 after installing child-theme [Wordpress]

matteradmin9PV0评论
Closed. This question is off-topic. It is not currently accepting answers.

Questions that are too localized (such as syntax errors, code with restricted access, hacked sites, hosting or support issues) are not in scope. See how do I ask a good question?

Closed 6 years ago.

Improve this question

I just created and activated a child theme and now I'm getting the HTTP ERROR 500. I've deleted the child theme through FTP and still getting the error.

Also tried changing wp-content/themes to wp-content/themestemp and that allows me to get back into the wp-admin panel but when I'm trying to install a new theme Wordpress can't create a new directory for the themes.

Is there a way to recover the primary theme?

Thanks in advance!

Closed. This question is off-topic. It is not currently accepting answers.

Questions that are too localized (such as syntax errors, code with restricted access, hacked sites, hosting or support issues) are not in scope. See how do I ask a good question?

Closed 6 years ago.

Improve this question

I just created and activated a child theme and now I'm getting the HTTP ERROR 500. I've deleted the child theme through FTP and still getting the error.

Also tried changing wp-content/themes to wp-content/themestemp and that allows me to get back into the wp-admin panel but when I'm trying to install a new theme Wordpress can't create a new directory for the themes.

Is there a way to recover the primary theme?

Thanks in advance!

Share Improve this question edited Feb 20, 2019 at 12:18 Fabrizio Mele 6875 silver badges16 bronze badges asked Feb 20, 2019 at 10:05 Tim van OostTim van Oost 32 bronze badges 2
  • Check /wp-content permissions. – Max Yudin Commented Feb 20, 2019 at 10:22
  • Thanks @MaxYudin. I've set all rights to read, write and execute but still getting the error. Is there an option to change the active theme through phpMyAdmin or ftp? – Tim van Oost Commented Feb 20, 2019 at 10:31
Add a comment  | 

1 Answer 1

Reset to default 1

In general a 500 Server Error can be solved (or at least be correctly identified) by looking at php logs. If you are on a shared hosting you should have something in your hosting's control panel to check the logs (look for Error messages), if you are self-hosting on your own vps you can usually find the logs in the /var/log directory.

This said, the current theme in WP is stored as two entries in wp_options, which are template and stylesheet. Name back the theme directory like the original one, write down the directory name of the original theme, and put it as the field value for wp_options.template and wp_options.stylesheet. At this point Wordpress is, if you haven't touched anything, be in the same state as before you child-theme'd.

Refer to the first paragraph of my answer and edit the answer with the php error so we can look at it.

Post a comment

comment list (0)

  1. No comments so far