To be able to support multiple domains, line 340 needs to be changed to

$dest = file_directory_path() .'/xmlsitemap/'. $_SERVER['HTTP_HOST'];

and line 398 to

$path = file_directory_path() .'/xmlsitemap/'. $_SERVER['HTTP_HOST'];

Otherwise all sitemaps would overwrite each other as they would all use the same directory.

Comments

darren oh’s picture

Status: Active » Closed (works as designed)

It is the site administrator's responsibility to choose a different files directory for each domain.

jurgenhaas’s picture

Status: Closed (works as designed) » Active

That's not good I'm afraid. Just so because we'Re having 50 subdomains which share logos and other files in the files directory.

Why shouldn't this module create subdirectories for each domain? At least this should be possible as an option, don't you think?

alliax’s picture

no it's not the site administrator responsibility to choose a different file folder, this is the first time I hear that!
I have used multi domain on one drupal install without problem until I found out the sitemap problem. What is the problem with supporting multi installs? Why do you add another useless task to a site administrator ONLY for your module?

This is not fair, thank you for the fix, but then I'll have to add it forever as xmlsitemap update its code.

hass’s picture

Think so, too as already said in http://drupal.org/node/194738.

darren oh’s picture

Status: Active » Closed (duplicate)