Yes, implementing this on multisite is going to be difficult. We have over 100 sites in the network.
@draphr Thanks for spotting this. It looks like we’re using $wpdb->base_prefix
instead of $wpdb->prefix
. We will look into this and get an update out to resolve.
Hello! We will be rolling out an update soon that loops through all sub-sites for you.
Awesome, thank you, @swb1192!
This fix will be in 1.4.1 as soon as we push it out. However, in investigating further, the CLI command will not run across all the sites on your multisite, but you can loop through each from the command line using a for
loop if you have lots of sites:
for site in $(wp site list --field=url);
do
wp pantheon session add-index --url=$site
done
We’re hiding the notice for multisites in 1.4.1 until we get that functionality built in, but in the meantime, the commands can still be run and will work once you pull down the update.
-
This reply was modified 1 year, 6 months ago by
Chris Reynolds. Reason: need to add the site url
-
This reply was modified 1 year, 6 months ago by
Chris Reynolds. Reason: fix bash
Thanks for the context, @jazzs3quence
1.4.1 is available which will hide the notice on multisite (for now), but also adds support for using --url=<your-subsite>
for use on multisites.
We’ll add the notice back in when the add-index
command can iterate over each site on a multisite natively, rather than requiring scripting to do it for you.