You could use the switch_to_blog()
function
Switches the active blog until the user calls the
restore_current_blog() function. This function is useful if you need
to pull posts, or other information, from other blogs, you can then
switch back after using restore_current_blog(). Using this function
will not load plugins that only run on the blog you switch to.
So you can edit your theme to always pull some header and footer content from the main blog, but still keep the inner content of the sub blogs.
In you theme’s header.php and footer.php files ( and maybe some other template files** ), put switch_to_blog($id_of_main_blog)
before hooks/functions that grab the site navigation and place restore_current_blog()
after.
**You will need to tweak the exact placements depending on the theme.
Related Posts:
- multisite: global menu containing network site links?
- Converting a theme to a child theme in a network
- WooCommerce shop page to use my custom template [closed]
- Hide a div that is part of all pages on one specific page
- Best practices – Should I create a child theme vs. customizing a framework theme? (such as HTML5 reset)
- Child Theme not loading parent CSS
- add generated stylesheet from parent theme after child-themes style.css
- add_image_size is scaling, even though crop is set to true
- date_i18n() issue
- Change Genesis Tag from Page Template [closed]
- How do I get a parent theme modification from a child theme?
- Modifying JS files in Child-theme
- Should I update my _s theme?
- How to keep my custom theme changes after updating genesis child theme
- Where is the correct place(s) in twentysixteen’s header.php to add a Google webfont?
- Display site admin profile fields in header.php
- Can a child theme based on Starker theme be released as free to use theme for public use?
- Override Constants in Child theme
- Same footer on all multisites blogs
- Excluding a page with a certain name from wp_page_menu
- Changing order title and featured image in blog post (Astra theme)
- Loading files for theme and child theme (Require)
- How can I disable/hide certain themes in multisite?
- Child themes: disabling the parent
- Change the template of multiple multisite pages at the same time
- How to add theme support?
- Is it a bad practice to use switch_to_blog in the frontend?
- Divi Child Theme not appearing in “Themes” [closed]
- Theme Development for WordPress Multisite Installation
- Include Parent functions.php in Child Theme functions.php
- WordPress empty Nav Menu error
- How to create a custom template to admin dashboard
- Select full Image Size on widget “Genesis – Featured Posts”
- How to first edit in local WordPress editor on page and the add code?
- Custom Field created in add_meta_boxes reappearing itself again in the default Custom Metabox
- changing blog title to an image using filter function in child theme
- Can´t access child theme´s scripts dependencies found in parent
- How to override p2 breathe theme plugin in content template file?
- Acivate all themes multisite wide automatically
- Is it possible to make *.js and folders visible in theme-editor
- Question regarding WP multisite feature
- add_filter to parent theme helper class function from child theme
- How to properly create a child theme
- Renaming a theme so it aids SEO and the theme used is hidden
- Featured Image meta box not showing up
- Using a starter theme vs starter theme with child theme
- Will my site get messed up when the wordpress theme updates if I edited the html code in the editor to change footer?
- How to correctly enqueue the parent and child theme stylesheets in the creation of a child theme? [duplicate]
- Why would changing a child theme to a normal theme pass a Template is missing. error
- Simple child theme modification but links are broken
- Making a child theme for “Airi”
- How to change footer credit text in Twenty Twenty One theme with a hook?
- Hestia Child theme creation
- Alignment Problem [closed]
- Why is switching between themes breaking my child theme?
- What $handle does WordPress use for a theme’s implicit style.css?
- How to override template files in parent theme?
- Is There A WordPress Hook for Accessing Attachments for A Particular Page?
- Different text on different sites in a multisite setup
- Editing my theme to try to place the default header at the top of the page breaks the rest of the page content
- LESS not working in WordPress [closed]
- Different themes on one site
- How to make a theme unable to be used on a multisite network?
- Sample Theme Options page for Multisite – what to consider
- Get themes’s images path in WordPress Multisite
- Multi Site Setup, Child Themes, Getting Style Sheet Directory
- How to modify theme content in Thematic?
- Why front-page.php doesn’t show content of file instead shows loop
- Theme functions don’t work as expected in partial included via get_template_part() after custom query using Ajax [duplicate]
- Copying a modified theme from one wordpress site to another wordpress site [closed]
- fetch all post from wp multisite network and sort all the post in descending order on the basis of “Created by ” term
- What is an alternative to not using child theme to customize a WordPress theme?
- Block validation failed for `core/pullquote` after adding theme support for editor-color-palette
- Where i must put hooks in overridable functions?
- Is_single not working properly in genesis
- (Parent) theme Is Not Showing In Theme Selection Panel and Therefore Breaks Child Theme
- How to make menus, footer, sidebars multi language
- Why does the theme of secondary site load the primary one in WordPress Multisite? [closed]
- Debugging slow WordPress Theme Customizer (Any option similar to Query Monitor)?
- Child theme in separate WordPress Install
- Change header image on a particular page
- Update modified Shopify third-party theme [closed]
- how can I re-utilize and class on a child theme
- Providing updates to your WordPress theme
- How to show children pages as array
- Can I use WP Multi-site on a sub-domain with a different theme but use all the original site’s posts/pages?
- Hook in parent theme Menu function
- How do child themes work?
- Why WordPress gets old templates code instead of the last updated ones
- Mutlisite in wordpress is not working
- Theme Options Doesn’t Work On WP Multisite
- adding navigation to genesis themes
- Standard Way To Do Custom Work Within A Page?
- Subsite theme mystery man replacement with Buddypress on main site [closed]
- What to do when child theme is out of date with parent theme
- Extracting Distance from FacetWP Proximity Function to Display in WordPress Template
- Image Size wrong during upload
- Is there any way to show child theme in theme detectors?
- Twenty sixteen – full height
- ways to create customized theme (hard coded – no pagebuilder)