SitePoint Sponsor |
|
User Tag List
Results 1 to 2 of 2
Thread: Google sitemap on parked pages
-
May 27, 2009, 07:27 #1
- Join Date
- Oct 2004
- Location
- uk
- Posts
- 853
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Google sitemap on parked pages
Hi guys
I have about 350 parked names. Is there a way I can add a google sitemap to each but using the same file
for instance
domain1.com/sitemap.xml
domain2.com/sitemap.xml
The problem I see is that "sitemap.xml" is the same file on each name as parked names use the same files.
Is there a way I could maybe do it dynamically?
-
May 27, 2009, 07:54 #2
- Join Date
- Apr 2008
- Location
- North-East, UK.
- Posts
- 6,111
- Mentioned
- 3 Post(s)
- Tagged
- 0 Thread(s)
Just setup an .htaccess rule to parse sitemap.xml as php, then setup a variable for the domain from which the script was requested.
PHP Code:<?php
$sDomain = $_SERVER['HTTP_HOST'];
?>@AnthonySterling: I'm a PHP developer, a consultant for oopnorth.com and the organiser of @phpne, a PHP User Group covering the North-East of England.
Bookmarks