src/Data/File.php
public static function write($pFile, $pContent, $pAppend = false)
    {
        if (! is_writable($pFile)) {
            self::create($pFile);
        }

        if ($pAppend) {
            return (file_put_contents($pFile, $pContent, FILE_APPEND | LOCK_EX));
        }

        return (file_put_contents($pFile, $pContent, LOCK_EX));
    }
public static function write($pFile, $pContent, $pAppend = false)
    {
        if (! is_writable($pFile)) {
            self::create($pFile);
        }

        if ($pAppend) {
            return (file_put_contents($pFile, $pContent, FILE_APPEND | LOCK_EX));
        }

        return (file_put_contents($pFile, $pContent, LOCK_EX));
    }
public static function write ( $ pFile , $ pContent , $ pAppend = false ) { if ( ! is_writable ( $ pFile ) ) { self :: create ( $ pFile ) ; } if ( $ pAppend ) { return ( file_put_contents ( $ pFile , $ pContent , FILE_APPEND | LOCK_EX ) ) ; } return ( file_put_contents ( $ pFile , $ pContent , LOCK_EX ) ) ; }
Write content to a file.

@param string $pFile
@param string $pContent
@param bool $pAppend Append data to file (erase content before write by
default)
@return mixed
Write content to a file .