How i can log this error to a text file or database ?
Fatal error: Call to undefined method PROJECTS::ssss()
It is not possible to handle fatal errors using a custom error handler.
The best solution is simply enabling error logging (e.g. to syslog) in your php.ini and then using a tool like logcheck/logsentry to receive regular emails about unusual syslog entries.
Instead of syslog PHP can also log errors to a file - simply have a look at the error logging options of php.ini.
log_errors = On
error_log = syslog
error_log = /path/to/some/folder/phperrors.log
Obviously you only want to use one of the error_log
lines.