Writes a string to a file.
Parameters
$file
stringrequired- Remote path to the file where to write the data.
$contents
stringrequired- The data to write.
$mode
int|falseoptional- The file permissions as octal number, usually 0644.
Default:
false
Source
public function put_contents( $file, $contents, $mode = false ) {
return false;
}
Changelog
Version | Description |
---|---|
2.5.0 | Introduced. |
include_once ABSPATH . 'wp-admin/includes/file.php'; WP_Filesystem(); global $wp_filesystem;