Edit File by line

Deprecated: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in /home/sportsfever/public_html/filemanger/function.php on line 93

Warning: Undefined array key "page_file_edit_line" in /home/sportsfever/public_html/filemanger/edit_text_line.php on line 32
/home/sportsfe.../httpdocs/wp-conte.../plugins/custom-t.../inc/Admin
File: PluginSilentUpgrader.php
//$this->skin->feedback( 'remove_old' );
[500] Fix | Delete
[501] Fix | Delete
$removed = $this->clear_destination( $remote_destination );
[502] Fix | Delete
[503] Fix | Delete
/**
[504] Fix | Delete
* Filters whether the upgrader cleared the destination.
[505] Fix | Delete
*
[506] Fix | Delete
* @since 2.8.0
[507] Fix | Delete
*
[508] Fix | Delete
* @param mixed $removed Whether the destination was cleared. true on success, WP_Error on failure
[509] Fix | Delete
* @param string $local_destination The local package destination.
[510] Fix | Delete
* @param string $remote_destination The remote package destination.
[511] Fix | Delete
* @param array $hook_extra Extra arguments passed to hooked filters.
[512] Fix | Delete
*/
[513] Fix | Delete
$removed = apply_filters( 'upgrader_clear_destination', $removed, $local_destination, $remote_destination, $args['hook_extra'] );
[514] Fix | Delete
[515] Fix | Delete
if ( is_wp_error( $removed ) ) {
[516] Fix | Delete
return $removed;
[517] Fix | Delete
}
[518] Fix | Delete
} elseif ( $args['abort_if_destination_exists'] && $wp_filesystem->exists( $remote_destination ) ) {
[519] Fix | Delete
//If we're not clearing the destination folder and something exists there already, Bail.
[520] Fix | Delete
//But first check to see if there are actually any files in the folder.
[521] Fix | Delete
$_files = $wp_filesystem->dirlist( $remote_destination );
[522] Fix | Delete
if ( ! empty( $_files ) ) {
[523] Fix | Delete
$wp_filesystem->delete( $remote_source, true ); //Clear out the source files.
[524] Fix | Delete
return new WP_Error( 'folder_exists', $this->strings['folder_exists'], $remote_destination );
[525] Fix | Delete
}
[526] Fix | Delete
}
[527] Fix | Delete
[528] Fix | Delete
//Create destination if needed
[529] Fix | Delete
if ( ! $wp_filesystem->exists( $remote_destination ) ) {
[530] Fix | Delete
if ( ! $wp_filesystem->mkdir( $remote_destination, FS_CHMOD_DIR ) ) {
[531] Fix | Delete
return new WP_Error( 'mkdir_failed_destination', $this->strings['mkdir_failed'], $remote_destination );
[532] Fix | Delete
}
[533] Fix | Delete
}
[534] Fix | Delete
// Copy new version of item into place.
[535] Fix | Delete
$result = copy_dir( $source, $remote_destination );
[536] Fix | Delete
if ( is_wp_error( $result ) ) {
[537] Fix | Delete
if ( $args['clear_working'] ) {
[538] Fix | Delete
$wp_filesystem->delete( $remote_source, true );
[539] Fix | Delete
}
[540] Fix | Delete
return $result;
[541] Fix | Delete
}
[542] Fix | Delete
[543] Fix | Delete
//Clear the Working folder?
[544] Fix | Delete
if ( $args['clear_working'] ) {
[545] Fix | Delete
$wp_filesystem->delete( $remote_source, true );
[546] Fix | Delete
}
[547] Fix | Delete
[548] Fix | Delete
$destination_name = basename( str_replace( $local_destination, '', $destination ) );
[549] Fix | Delete
if ( '.' == $destination_name ) {
[550] Fix | Delete
$destination_name = '';
[551] Fix | Delete
}
[552] Fix | Delete
[553] Fix | Delete
$this->result = compact( 'source', 'source_files', 'destination', 'destination_name', 'local_destination', 'remote_destination', 'clear_destination' );
[554] Fix | Delete
[555] Fix | Delete
/**
[556] Fix | Delete
* Filters the installation response after the installation has finished.
[557] Fix | Delete
*
[558] Fix | Delete
* @since 2.8.0
[559] Fix | Delete
*
[560] Fix | Delete
* @param bool $response Installation response.
[561] Fix | Delete
* @param array $hook_extra Extra arguments passed to hooked filters.
[562] Fix | Delete
* @param array $result Installation result data.
[563] Fix | Delete
*/
[564] Fix | Delete
$res = apply_filters( 'upgrader_post_install', true, $args['hook_extra'], $this->result );
[565] Fix | Delete
[566] Fix | Delete
if ( is_wp_error( $res ) ) {
[567] Fix | Delete
$this->result = $res;
[568] Fix | Delete
return $res;
[569] Fix | Delete
}
[570] Fix | Delete
[571] Fix | Delete
//Bombard the calling function will all the info which we've just used.
[572] Fix | Delete
return $this->result;
[573] Fix | Delete
}
[574] Fix | Delete
}
[575] Fix | Delete
[576] Fix | Delete
12
It is recommended that you Edit text format, this type of Fix handles quite a lot in one request
Function