1

Does any of you have experienced problems with generating the sitemap due to using https instead of http?

I have 2 webshops (each own installation). One of those have a ssl certificate and uses https. I have added this code in the .htaccess to make the whole site use https:

RewriteCond %{HTTP_HOST} !^www\.
RewriteRule ^(.*)$ https://www.%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]

Everytime I try to generate sitemap it gives me an error that it's unable to generate the sitemap

while on the other installation (which do not use https) I can generate it no problem

that's why I'm concluding at the moment that there is something wrong with the https settings but I have no clue how to fix it

4
  • What error? How are generating it? Of course you've checked file system permissions?
    – user4351
    Feb 12, 2015 at 18:34
  • 2
    Try removing the htaccess lines you posted and enter your https address under System - Configuration - Web - Unsecure Base URL as well as Secure Base URL.
    – Simon
    Feb 12, 2015 at 20:42
  • Hi there, thanks for your replies, when I create sitemap via - Catalog - Google sitemap - it creates the sitemap.xml (I can access it via ftp, but it's empty) the file permission is 666. Magento gives me the error "Unable to generate the sitemap" I have removed the code from my .htaccess file and added https to the secure/unsecure base url but it still doesn't generate the sitemap. Just have to add that the site works perfectly fine and uses https. Feb 13, 2015 at 12:37
  • You could try to use /media/ as a path for the sitemap.xml, because you should have write permissions on this folder. Although it should not be a permission problem if the file is created. If this does not help: magento.stackexchange.com/questions/428/…
    – Simon
    Feb 13, 2015 at 14:12

1 Answer 1

1

Are you using "sitemap.xml" as the filename? Magento gives you the option to enter a custom filename, but for some reason it will throw an error when you enter a different name.

If you have multiple stores, you can add them in different folders (like /en_US/ and /fr_FR/) and still set the filename to sitemap.xml.

If that isn't working either, there is something wrong with the write permissions of your file (or the owner).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.