This sounds like a pretty strange idea. How often do you actually plan to change the header template once the design is completed? If you add a page to one site, do you want it to appear on the other one?
Hi Chrisber.
I said header, but I’m actually planning to do it also with the footer and sidebar and it’s not with 2 blogs, but 6, so if I want to change something in one of them, I have to do it in every one… It’s difficult to explain jeje.
I don’t want the posts to appear in all the blogs, just the sidebar, footer and header templates. How can that be done?
Cheers
From what you’re saying, all you want is to have to change Blog A’s header and Blogs B-F’s headers change too. If this is correct, try this.
<?PHP include("http://bloga.com/header.php");?>
Where “http://bloga.com/header.php” leads to your header in Blog A. Place that code in your Main Index Template so that it replaces:
<?php get_header(); ?>
See how that works..
Doesn’t work. When I refresh:
Warning: include() [function.include]: URL file-access is disabled in the server configuration in /home/foroatle/public_html/wp-content/themes/Wordpress_Magazine/index.php on line 1
Warning: include(http://www.foroatletismo.com/entrenamiento/wp-content/themes/acosminv2/header.php) [function.include]: failed to open stream: no suitable wrapper could be found in /home/foroatle/public_html/wp-content/themes/Wordpress_Magazine/index.php on line 1
Warning: include() [function.include]: Failed opening 'http://www.foroatletismo.com/entrenamiento/wp-content/themes/acosminv2/header.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/foroatle/public_html/wp-content/themes/Wordpress_Magazine/index.php on line 1
This sounds like a complicated solution to a simple problem. Why not just install one version of WP locally and do all of your theme updates on the local version. As long as all of your sites are hosted on the same account, it should not take more than one minute to update all 6 by FTP when necessary.
When you do an include, you don’t include the http path to the file, you include the real server path to the file.
So this include('http://whatever'); won’t work. You need to actually give it the real path. Like /var/www/yourname/whatever/wp-content/themes/themename/header.php.
Alternatively, you could make the entire theme directory on one site a symlink to the other.
Both solutions absolutely require that the blogs are on the same server. If they’re not, then you can’t do it at all, period.
Although I agree with Chrisber, sounds like a heck of a lot of work for little gain.