Tag Info

New answers tagged

2

I am not calling it inside of a hook but just straight away as the first thing in a MU plugin. At that point all the info you are requesting won't be available. That's running before any hook and before WP is fully loaded. Use a hook like wp_loaded, admin_init, after_setup_theme ... whatever serves your purpose best.


-1

The right solution is checking the server TIME. If it is wrong SSL doesn't work fine.


1

Thanks to diggy from StackOverflow I've foudn that in the WordPress cycle, the file vars.php (containing my needed functions) is included after muplugins_loaded executes. Including wp_is_mobile() and current_user_can() in wrapper functions fixed my problem. CORRECT function my_epic_function() { if(current_user_can( 'edit_posts' )) { ...


1

try and add your location as a parameter. <?php if ( has_nav_menu( $location ) ) { //Do something } ?>


0

Here's a workaround you can put in a plugin or your theme's functions.php file. So far no problems. /* * Workaround Bug 30123 * Affects WP 4.0+, should be fixed in WP 4.1 * https://core.trac.wordpress.org/ticket/30123 */ function bugfix30123__action__admin_init() { if ( isset( $_GET['attachment-filter'] ) && is_string( $_GET['attachment-filter'] ...


0

I just wanted to say thank you for this article because I've been searching for a solution to this problem for a long time. It was simply because I had used a plugin to clone my sites and it never updated the wp_##_user_roles properly. When the site copied over from wp_13... it was cloned over to a new site wp_81... but this entry was still stuck at wp_13.


0

Correct me if I'm wrong, but I believe you are mixing up the terms of CNAMES and subdomains a bit. In case you are looking for a subdomain setup for WordPress Multisite: Yes this is possible: The sites in a network have different URLs. You can choose one of two ways for the URL to specify the site: -Each site has a different subdomain. For ...


0

I found a solution in this article I had the wrong SUBDOMAIN_INSTALL setting value in my config file.


0

Could you use the admin bar at the top instead? To me short messages look better up there. add_action( 'admin_bar_menu', 'toolbar_link_to_mypage', 999 ); function toolbar_link_to_mypage( $wp_admin_bar ) { $args = array( 'id' => 'my_admin_bar_text', 'title' => 'WELCOME TO SYDNEY', 'meta' => array( 'class' => ...


0

Dylan has the correct answer but to elaborate. Add a filter that fires after the default one using a higher priority then 10: add_filter( 'wpmu_signup_user_notification_email', 'wp_new_user_notification', 11 ); The function for the content: function wp_new_user_notification( $user_id, $plaintext_pass = '' ) { $user = new WP_User( $user_id ...


0

Try this procedure: 1) Go in to Network Admin -> Sites and edit the site you want to BE the new 'main' domain so it's url is http://example.com (remove the subdomain or subfolder path totally). There's a checkbox to change site and home URL. Make sure that's checked before you hit save. 2) Change the define('BLOG_ID_CURRENT_SITE', 1); to whatever you want. ...


0

I had issues with this as well. What I wanted was to give one user Admin but remove certain menus from the backend admin side bar. I removed AAM because it was giving permission problems and used Menu Editor Pro instead. Everything works perfectly. Of course, this is not the most secure way to go about it, it still allows access to the hidden admin pages ...


0

YES you can install wordpress to every diectory where you want to run as site. Like you run site on www.domain.com , Now you want to run 1 more wordpress site to www.domain.com/test1 then you need to install wordpress in test1 folder/directory and configure new database. Site default content and theme will display with new wordpress.


1

Well, WordPress.com it's the largest deployment of WordPress Multisite and they're basically using the same setup (multiple tables for each site), so you could say that it's a good strategy. This kind of setup would let you to, for instance, keep your VIP users on a dedicated box, or add multiple DB servers as the network grows. I've had experience with ...


2

Turns out .htaccess was missing the following lines # uploaded files RewriteRule ^([_0-9a-zA-Z-]+/)?files/(.+) wp-includes/ms-files.php?file=$2 [L]


2

Assumption: you're running on an Apache web server. If not, you'll have to translate the relevant portions of this answer into the nginx or IIS or whatever server-ese. Per the Codex page on setting up Multisite, you should have Pretty Permalinks enabled and working on your site prior to setting up Multisite. (See Step 1.) Pretty Permalinks require you to ...


2

The 404 is coming from your http server and not making it to WP. htaccess is not configured on your server.



Top 50 recent answers are included