replace '__DIR__' to 'dirname(__FILE__)' for PHP5.2 support