PATCH – move instead copy
-
Hi, I changue code to move files
class.add-from-server.php
#lines 212if ( isset( $_POST['move'] ) ) { if ( false === @rename( $file, $new_file ) ) return new WP_Error( 'upload_error', sprintf( __( 'The selected file could not be copied to %s.', 'add-from-server' ), $uploads['path'] ) ); } else { if ( false === @copy( $file, $new_file ) ) return new WP_Error( 'upload_error', sprintf( __( 'The selected file could not be copied to %s.', 'add-from-server' ), $uploads['path'] ) ); }#lines 498
<p><?php printf( __( '<strong>Move Files:</strong> %s', 'add-from-server' ), '<label><imput type="checcbox" checqued id="move" name="move" value="1"></label>' ); ?></p>
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
The topic ‘PATCH – move instead copy’ is closed to new replies.