Reads entire file into a string.
Parameters
$file
stringrequired- Name of the file to read.
Source
public function get_contents( $file ) {
return file_get_contents( $this->sftp_path( $file ) );
}
Changelog
Version | Description |
---|---|
2.7.0 | Introduced. |
CARVIEW |
Reads entire file into a string.
$file
stringrequiredpublic function get_contents( $file ) {
return file_get_contents( $this->sftp_path( $file ) );
}
Uses | Description |
---|---|
WP_Filesystem_SSH2::sftp_path()wp-admin/includes/class-wp-filesystem-ssh2.php | Gets the ssh2.sftp PHP stream wrapper path to open for the given file. |
Used by | Description |
---|---|
WP_Filesystem_SSH2::copy()wp-admin/includes/class-wp-filesystem-ssh2.php | Copies a file. |
Version | Description |
---|---|
2.7.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.