Changeset 938019
- Timestamp:
- 06/24/2014 07:32:20 PM (12 years ago)
- Location:
- multisite-cloner/trunk
- Files:
-
- 2 edited
-
multisite-cloner.php (modified) (4 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
multisite-cloner/trunk/multisite-cloner.php
r925411 r938019 5 5 * Plugin URI: https://wordpress.org/plugins/multisite-cloner 6 6 * Description: When creating a new blog on WordPress Multisite, copies all the posts, settings and files, from a selected blog into the new one. 7 * Version: 0.1. 47 * Version: 0.1.5 8 8 * Author: Manuel Razzari & Patricio Tarantino 9 9 * Author URI: http://tipit.net … … 143 143 144 144 function set_new_blog( $blog_id=false ) { 145 146 145 global $wpdb; 147 146 … … 193 192 } 194 193 195 $old_uploads = 'wp-content/uploads/sites/' . $id_default_blog; 196 $new_uploads = 'wp-content/uploads/sites/' . $blog_id; 194 $wp_uploads_dir = wp_upload_dir(); 195 $base_dir = $wp_uploads_dir['basedir']; 196 $relative_base_dir = str_ireplace(get_home_path(), '', $base_dir); 197 198 $old_uploads = str_ireplace($blog_id, $id_default_blog, $relative_base_dir);; 199 $new_uploads = $relative_base_dir; 197 200 198 201 // Replace URLs and paths in the DB … … 207 210 208 211 // Copy Files 209 $ new_uploads = '../../' . $new_uploads;210 $ old_uploads = '../../' . $old_uploads;212 $old_uploads = str_ireplace($blog_id, $id_default_blog, $base_dir);; 213 $new_uploads = $base_dir;; 211 214 212 215 cloner_recurse_copy($old_uploads, $new_uploads); -
multisite-cloner/trunk/readme.txt
r924028 r938019 62 62 == Changelog == 63 63 64 = 0.1.5 = 65 * Independence of the uploads directory structure. ([Issue: Gives warning after creating subdomain site](http://wordpress.org/support/topic/gives-warning-after-creating-subdomain-site)) 66 64 67 = 0.1.4 = 65 68 * First public release. … … 81 84 == Upgrade Notice == 82 85 83 = 0.1. 4=84 This is the first public release.86 = 0.1.5 = 87 * Independence of the uploads directory structure.
Note: See TracChangeset
for help on using the changeset viewer.