Single-user registration to access all sites in WordPress MultiSite Network
There sure is: Multi Site user Management The plugin syncs your users across sites. I’ve used it extensively and it works really well.
There sure is: Multi Site user Management The plugin syncs your users across sites. I’ve used it extensively and it works really well.
Thans but I’ve found the solution, what it need to do is to edit the site (Network -> Sites -> Edit -> Settings ) and change the following parameters: Uploads Use Yearmonth Folders 0 Upload Path wp-content/blogs.dir/1/uploads Fileupload Url http://www.mydomain.com/myblog/uploads
Current site Id defines the primary network id. You can have more than one network if you use a multi-network plugin. Current blog id defines the primary blog within the primary network. To change the main blog to ‘2’ (if you only have one network) you want your defines like this: define( ‘SITE_ID_CURRENT_SITE’, 1 ); … Read more
You could use your list of blog ids in this way … $posts = array(); foreach ( $your_list_of_blog_ids as $blog_id ) { switch_to_blog( $blog_id ); $query = new WP_Query( array( ‘post_type’ => ‘any’, ‘posts_per_page’ => 10, ) ); while ( $query->have_posts() ) { $query->next_post(); $posts[] = $query->post; } restore_current_blog(); } Important are switch_to_blog and restore_current_blog. … Read more
Your .htaccess lines need to look like this: RewriteEngine On RewriteBase / RewriteRule ^index\.php$ – [L] # uploaded files RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) /wordpress/wp-includes/ms-files.php?file=$2 [L] # add a trailing slash to /wp-admin RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L] RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^ – [L] RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) /wordpress/$2 [L] RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ /wordpress/$2 [L] RewriteRule . … Read more
You have totally missed the naming convention when coming to the taxonomy archive pages, and most probably the same goes for your archive pages for your custom post types Here is how your taxonomy archive pages should look like taxonomy-{taxonomy}-{term}.php – If the taxonomy were sometax, and taxonomy’s term were someterm WordPress would look for … Read more
You can clearly see the way WordPress loads plugins if you inspect the source code of the file wp-settings.php. The function wp_get_active_and_valid_plugins() loads plugins for individual sites in the network and for non-Multi-Site installations, while wp_get_active_network_plugins() loads network activated plugins when Multi-Site is enabled. The former more or less just calls get_option() to get the … Read more
There is nothing in the core or in the rest API for this requirement. You can try this plugin, https://github.com/remkade/multisite-json-api Sorry, but I see no other chance and no more to say in this answer. The core function to create a new site in the network of the installation is wpmu_create_blog. But there is no … Read more
You can filter domain_exists, a check that runs before a site is registered. If you return a positive integer, WordPress will not create that site. Despite its name, that filter lets you check the path too. Sample code, not tested: add_filter( ‘domain_exists’, function( $result, $domain, $path ) { // Already taken, no need for further … Read more
From a user perspective there are two noticeable differences. First of all the GUI for creating new sites. Either it shows an input field for the first segment of the URL path (subdirectory) or an input field for the subdomain you want to use for the new site. (Setting the URL to a completely arbitrary … Read more