In WordPress Multisite, new sites get a boring default template, without any custom settings or starter content.
This plugin allows you to select a specific blog on your network, a “master” one, that will be cloned every time a new blog is created.
In this way, new blogs will contain all posts, uploads, theme settings and plugin options from the master blog.
How does it work?
- It uses MySQL
INSERT INTO ... SELECTto copy every table from the “master” blog into the new one. This is fast!
- Then it does a search and replace on the new blog’s tables, to replace the old URL with the new one.
This is done in a way that respects serialized arrays, so your plugin’s settings will be preserved.
(We used a heavily trimmed down version of Interconnect/IT’s Search and Replace tool for that, so go thank them for this!)
- It proceeds to copy all files from the
wp-content/uploadsdir of your master blog into the new one’s, so that all assets will work as expected.
- Finally it does some house clean-up, updating the new blog’s title, admin email, and user roles as needed.
Go check the screenshots, it’s really simple and does what it says.
Give it a try!
This plugin was handcrafted with love and ‘yerba mate’ by the team at Tipit.net.
- Network-activate the plugin through the ‘Plugins’ menu in your Network admin.
- In your Network admin, go to Settings > Multisite Cloner
You’ll probably want to create a “master” blog to clone from, if you don’t have one already.
ਅਕਸਰ ਪੁੱਛੇ ਜਾਂਦੇ ਸਵਾਲ
- Can I clone the main site?
No. The main site in your network (usually the one with ID = 1) contains many DB tables, assets and even sensitive information that shouldn’t be replicated to other blogs.
- Can I clone my blog in a single-site WP install?
No. The whole point of this plugin is to clone blogs within a Multisite network.
We couldn’t come up with more questions. Go ahead and ask us some questions and we’ll add the frequent ones here 🙂
ਯੋਗਦਾਨੀ ਤੇ ਵਿਕਾਸਕਾਰ
“Multisite Cloner” is open source software. The following people have contributed to this plugin.ਯੋਗਦਾਨੀ
- Fixed syntax error introduced in 0.2.2. (Props to @infotexsupport for reporting this.)
- Settings dropdown: include site path, set max-width.
- WP 4.6 compat: use get_sites and get_network. (Props to @dima-stefantsov for reporting this.)
- Fixed a bug with unserialized object cloning (Props to @icryptic, @techiechic, @t2m and @dberdal for reporting it, and thanks to @interconnectit for the actual fix!)
- Bug fix: when “Allow new registrations” is enabled and a user activates a new blog from the front-end, the wrong footer would be displayed on
wp-activate.php. Thanks to Schalk Joubert who insisted on this bug.
- Minor UI tweaks to Settings
- Tested and updated WP version support.
- New feature: optionally clone users from the master blog. As suggested by @wppower.
- Disable cloning of the Main blog from the All Sites network admin.
- This plugin now works on an install path that includes numbers (avoid collisions with blogs ids), and supports HTTPS blogs too.
- Fixes minor problem with the clone recursive copy function
- This version works with the latest WordPress release (WordPress 4.0.0)
- Bug fix: Images in post were linked to the original blog.
- Minor fix to avoid PHP warning if target directories already exist (Fixes warning when creating new site reported by mr.gengu and beda69).
- Minor typo fix (Fixes error on network activation reported by ammienoot)
- The plugin now works on directory-based installs (Fixes problem with duplicate file path reported by JigMedia)
- Handle case of new networks that still haven’t created any sites to clone from.
- Fixes user roles error on installs with a non-default db prefix. (Fixes problem with user roles after cloning reported by B_Dark)
- Independence of the uploads directory structure. (Fixes warning after creating subdomain site reported by Pradip Nichite)
- First public release.
- Disabled cloning of the main site in the network. Risky stuff.
- Added “Dolly The Cloner” graphic by rock-star designer Diana Stilinovic.
- Added settings page.
- Added shortcut to clone any blog in the network.
- Refactored into a plugin class.
- Refactored DB replacer to use wpdb functions instead of obsolete mysql_* calls.
- Replaced calls to functionality in the underlying OS (mysql, sed) with raw SQL, for greater portability.
- Initial version, on a client site.