Jump to content

Recommended Posts

Posted

Username:suriya

website:suriya.me

 

So my problem is that my error_log file gets VERY big , and I have to delete it at least once a day.Any way you can turn off that feature for me,or limit the size of the file at /public_html and at /public_html/wp-admin/

 

I also get 500 errors frequently . Can I know the reason ?

Posted

I am working on that :) .Thing is I have lots of people visiting from their mobile devices which look up for files that don't exist (Like:http://suriya.me/app...precomposed.png),and that is what I suspect is giving me errors.and sometimes Mysql does not work cause of too much traffic , can you in increase the number of user connects pls ? :)

Posted

If you can't figure out how to fix the errors, make a file and name it something like "delete.php", then add this code to it:

 

<?php
unlink("error_log");
?>

 

Then use an include on the page where the errors are generated from like this:

 

<?php
include("delete.php");
?>

 

Now the error_log file will be deleted anytime somebody views your page.

 

 

EDIT: Try this first before you try my other suggestion. Add this to the top of your php page:

 

<?php
error_reporting(0);
?>

  • Like 1
Posted

The best way to do this is with the PHP configuration.

 


<?php
ini_set('log_errors','off');
ini_set('log_errors_max_len','0');
phpinfo();

Those two directive tell php not to log the errors, and to only log 0kb of errors.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...