get_sites() for sites registered before given date

Here, this should permanently delete all sites older than 30 days (except the one with ID 1). I was not able to make it work with date_query. If you need to call get_sites() for these sites for some other reason, just instead of deleting them, add their IDs in an array, and then call get_sites() … Read more

Changing URL in multisite

Probably this due to the siteurl setting in db. But for multisite, how did you configure for mult UPDATE wp_options SET option_value=”YOUR_SITE_URL” WHERE option_name=”siteurl”

How do I set a default theme in multisite network

Have you tried enabling the theme from network admin? Visit /wp-admin/network/themes.php and “network enable” the themes you would like to allow access to. You can set a default theme for new / existing sites on your network in wp-config.php Put this in your config file and change the theme name as desired. define(‘WP_DEFAULT_THEME’, ‘classic’); Network_Admin_Themes_Screen#Default_Theme

WordPress 3.8.1 Multisite blog slug problem

I fixed this in the following way. Go to the “Network admin”. Then Sites → Edit → Settings → Permalink Structure. Remove blog from it. Then I removed blog from two lines in table which obtained as a result of the query: SELECT * FROM wp_options WHERE option_name = “permalink_structure” OR option_name = “rewrite_rules” Useful … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)