1

After searching the internet, I found people with the same problem, but that could not be solved in a good way. The problem is as follows, a Wordpress (I've also had the problem with Joomla) + IIS 8 + PHP 7. Normally the system works correctly, but one day arbitrarily the server returns error 500. When I activate the debug a message like the following appears Failed opening required './wp-default-header.php' (include_path = '.; C: \ php \ pear') in C: \ inetpub \ site \ blog \ index.php on line 17

Ok, the solution is very simple. On line 17 there is this require_once (ABSPATH .WPINC. '\ Widgets \ class-wp-widget-search.php') command; And to solve the problem I just have to change \ --> / Require_once (ABSPATH .WPINC. '/widgets/lass-wp-widget-search.php');

The problem is solved (only for today), but both WP and Joomla have thousands of lines with this instruction and the problem continues happend arbitrarily in time. Anyone know if you can fix this in an elegant way, either changing all the WP lines or an IIS configuration?

As a curious note, in line 16 of the same file there is the following instruction that works correctly!! require_once( ABSPATH . WPINC . '/widgets/class-wp-widget-links.php' );

I am sure that this is not a problem of the version of WP or the used pluguins. As I say, this problem happens in several versions of WP in several pluguins and even with Joomla.

Thanks in advance !

  • Sorry theres a mistake the initial command is line 17 is with / to solve is change / for \ – Angel Apr 19 '17 at 9:11
  • Ahhm, just sayin' - but fiddling in the core-code is the worst idea. On first sight, this seems like a performance issue to me, just speculation. – user3135691 Apr 19 '17 at 10:32
  • After continuing searching, I have seen a comment (I can not remember where) that mentioned the possibility of permissions in lower subdirectories. Yes that can be solved by adding permissions to the IUSR user to the lower folder. If the wp is in c: \ inetpub \ site \ wordpres \ add permissions in c: \ inetpub \ site.As it is an arbitrary problem I can not say if it is the correct solution. We will wait for a time. – Angel Apr 20 '17 at 11:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.