I’m surprised get_current_blog_id()
didn’t work, since that’s probably the best way to approach it. Always try doing a var_dump( $current_blog )
to make sure you’re testing for what you need. Edit (19 Aug 2015): Also, triple check that you know which header you’re expecting to see and that you’re making the change you want in the right header file.
Alternately, consider making a child theme and replacing the header that way. That may be more maintainable over the long run, particularly if you plan on using unique headers for other sites.
Also, you can use get_header( 'blog2' )
instead of get_template_part( 'header', 'blog2' )
. Same result but the first way’s a bit cleaner.
Related Posts:
- Shared Content but “Updatable” Through the Main Site
- How to make wp-signup.php a 1-step process [closed]
- Use another author.php if different multisite subsite?
- Can is_page and is_front_page both be true?
- How to convert multi-site to single site
- Create a page for a theme only
- Programmatically create blogs with dummy content on a WPMU site
- How to individually set WP_DEBUG on a sub-directory multisite?
- Create multiple subdomains for multi-site from a database
- How to map a specific multi-site blog to a folder?
- 4 single sites VS multisite wordpress
- Outputting Canonical Resource URLs Across a Multisite Network?
- multisite htaccess 301 redirects
- Two-level multisites in WordPress
- using 1 form shortcode (si or cf7) for all multisite sites [closed]
- How to manage multiple domain with different languages on each domain with single wordpress installation?
- Is there any fundamental difference in developing a wordpress multi-network site?
- merging two multisites
- Is there an advantage of using multisite if I have multiple WordPress websites for myself?
- Redirect loop (only for multisite network admin)
- favicon and multi site
- current_user_can(‘Administrator’) does not return true in multisite if user is Administrator but NOT Super Admin
- cant enable theme in multisite
- Deleting a user in multisite
- Recover from failed multisite conversion
- On WordPress Network(multisite), Sub Blogs in Subdirectories or Subdomains? What’s better?
- How to know if a site is using Multisite?
- Cookie nonce is invalid – Multisite
- Multisite setup on VVV with bedrock
- How can I delete a user from entire multisite nework
- Using A Shared/Common Theme Across Multiple Sites
- Activate Child Theme with Codex
- Multisite Network Localisation
- Can set_transient() be used in multi-site?
- Why does my multisite blog doesn’t show users?
- What would you recommend for hosting 10+ individual wordpress websites?
- ERR_TOO_MANY_REDIRECTS IN MULTISITE NETWORK DASHBOARD
- Redirect only posts to New Domain
- Image problem – Multisite image upload broken
- WordPress Multisite new sites in directory
- add_rewrite_rule on multisite doesn’t work
- web.config breaks the themes for sub-directory multisite
- Add a user to a specific blog when they register?
- Different use for WordPress Multisite
- Multisite: How to get a list of installed languages
- “You must be logged in to comment” but I am already logged in
- Multisite User Sync Question about blog authorship
- WordPress multisite .htaccess causes 500 error on old *.php URLs
- WP-CLI cron on multisite using WP-Toolkit “succeded”, but callback not executed
- WordPress multisite suddenly malfunctioning
- Site redirecting to http://example.com/wp-signup.php?new=example.com
- Cannot use pre_set_site_transient_update_themes from within a theme in multisite
- Login problems on multisite installation with different domains
- Multisite wordpress config on multidomain
- Is this a job for WP MultiSite with domain mapping plugin?
- Move wp-content htacess
- FeedWordPress duplicated posts problem
- WordPress MU subdomain vhost
- Domain mapping with Multisite links are wrong
- Making a Multisite Dashboard Widget
- wp_get_attachment_image_src returns incorrect URL on multisite
- Locking one blog of many in a multi user/blog WordPress installation
- How do I disable XML-RPC in WordPress Multisite?
- Multisite – One Site with multiple URLs
- Include www prefix in site URL
- Delete all user’s meta without knowing all the ‘key’
- Is this possible? A multisite with “www.example.com/en/blog/” and “www.example.com/cn/blog/” (two directories deep)
- How to modify wp_config file for set up subdirectory?
- Sharing users across multiple sites, each on their own database
- Activation Account Email
- Stylesheet and JS linking error in WP multisite nested path
- How to automatically translate plugin using translate.wordpress.org
- May I do multiple micro-sites with different themes in a single wordpress without subdirectory nor subdomain separation?
- Multisite htaccess file causing segfault (Segmentation fault 11)
- How do I export a single site in a multisite content without using a plugin? The default WP export does not catch all
- Multisite Smtp Server
- Images uploaded after adding multisite do not get loaded in any domain of the multisite network
- Migrating from domain mapping plugin to native domain mapping
- Media library links broken WordPress Multisite after SSL update
- When hooking wp-cron to system
- WordPress network, add extra directory to subsite urls
- Register a user only to the root blog – WP Multisite
- Update Same Contents on every Page
- WooCommerce API Returns 401
- Define default settings for new sites on multisite network with mu-plugin
- Multisite + wp_mail – Route Via Site Conditionally
- WordPress automatic Login on other page?
- Use a single WP installation instead of three
- MU domain mapping without using a plugin
- Multisite authorization error 401
- How create a multisite setup with “phantom” accounts and passwords?
- is there a if multisite have posts function?
- Multisite – mix sites that use subdomains with sites that use paths
- WordPress Multisite — Have same navigation, sidebar and footer across all sites.
- Primary site file uploads failing, subdirectory subsites upload fine
- Subdomain Wp-Admin Not Found
- Run “get_the_post_thumbnail” with a different table prefix?
- Pick your brain on wp-config.php if statement for multisite
- WordPress Multisite restict user access
- Change a subsite Admin role of a WordPress Multisite after 24 hours registering