Mapping domains to WordPress network installed on subdomain
Mapping domains to WordPress network installed on subdomain
Mapping domains to WordPress network installed on subdomain
Multisite User cannot access dashboard
Using the standard WordPress “New User” interface on a multisite
There are multiple ways to do this. One would be to change the values in the database directly (explained here). However, this easily introduces errors, so I don’t prefer it. The other method is to use grant_super_admin() with the user’s ID. The default admin’s ID is 1 and there are various methods to find other … Read more
get post id by $content (so by post content)
Try adding something like the following at the top of your .htaccess file: RewriteCond %{HTTP_HOST} ^(www\.)?oldone\.com RewriteCond ${REQUEST_URI} !^/wp-admin RewriteCond ${REQUEST_URI} !^/wp-login RewriteRule . http://newone.com%{REQUEST_URI} [R,L] Make sure the browser cache is clear. Change to 301 (if that is the intention) only when you are sure it’s working OK. Repeat for any other oldoneN.com / … Read more
Since you have multiple domains you can’t include the domain in the redirect itself to create a one-size-fits-all generic redirect (which is what I assume you are trying to do). You also need to ensure that the directives are in the correct order. Since all your sites use the www subdomain then try the following … Read more
How to add user to blog? You can use add_user_to_blog function to do that. After Codex, it: Grants the specified user permissions of the specified role on the specified blog. And you use it like so: add_user_to_blog($blog_id, $user_id, $role); How to do it automatically? You want to do this automatically, when new site is created, … Read more
So evidently, I was having jquery conflicts… I’m loading in a newer version of jquery and had the “load in footer” argument (in the wp_register_script) set to true. I also forgot that WordPress loads in a “default” type of jquery library but in the head. I first tried to “deregister” the jquery lib that was … Read more
Finally, I’ve found the solution by myself. There is a the_posts filter hook we have in the WordPress, which works after the system attempted to collect posts from a blog and, the most important, before defining the 404. Hooking it we can quickly update, or even modify, the array of posts, i.e. single post in … Read more