A couple of of my clients are confirming that they're getting "500" Internal Server errors recently. In my opinion it may be triggered by various plug ins they're using but every time, the webhost (multiple hosts) say the htaccess file needed to be changed to repair the problem.

I am posting the code below from the custom theme because it is the only place where I trigger an htaccess write. And That I want to be certain that you will find no problems here that may cause an problem that may lead towards the 500 errors...

The code first inspections to make certain taxonomy.php exists, because the wordpress_create_category calls want it. Additionally, it inspections the present permalink configurations and when they aren't set based on my anticipated parameters, I execute the permalink rewrite code the thing is there. Its this code that, I am fairly certain, produces an htaccess edit. I would like to be certain that this can be a seem little bit of programming and never prone to cause sporadic internal server errors...

EDIT: In A Single Situation, the consumer has got the following plug ins in most his sites...

The mkdir call will certainly fail if wordpress-submissions are not writable, you have to the permalink edit - if .htaccess isn't writable it will fail and can result in a 500 error (for the way Wordpress implements this). Another possible problem might be that the .htaccess changes corrupt another establishing .htaccess that's required by among the other plug ins.

Regardless : searching in the Apache error log and logging PHP errors ought to be enough to obtain the actual supply of the issue.