Log4php is a PHP port of Log4j, the most popular Java logging framework. It supports configuration through XML and properties files (with the same structure as log4j) and custom Configurators. File, RollingFile, DailyFile, Echo, Console, Mail, PEAR::Db, PHP error, Syslog or NT events, and socket appenders are supported. Simple, TTCC, Pattern, Html, and Xml Layouts are supported. It also supports Filters, custom Levels, and Loggers. Internal debugging can be switched on and off. Log4php can be used inside a class or inside a main/sub function.