icamys / php-sitemap-generator

A simple PHP sitemap generator.
MIT License
168 stars 65 forks source link

Adds base sitemap URL configuration parameter #55

Closed arueckauer closed 1 year ago

arueckauer commented 1 year ago

This PR provides the functionality described in #24 by adding an optional sitemapBaseURL property. The default value is that of baseURL. Since it is probably more common to have the sitemap directly in the base URL, the constructor signature is not changed and the value set separately via a setter.

Would be happy to see this feature be introduced. Looking forward to hearing from you.

arueckauer commented 1 year ago

@icamys Did you have a look at this? Do you have any questions/feedback? Let me know if I can assist any further. We would love to see this getting merged. 😊

icamys commented 1 year ago

@arueckauer Thank your PR! I got the issue and it looks like it's pretty common. I appreciate your effort in solving it, however, I believe it should be solved in a slightly different way. I'm working on the next version of the library which will include the fix for the issue. I will notify you when it is done. I'll still keep the PR for now for reference. Thank you again for your contribution!

arueckauer commented 1 year ago

Hi @icamys Just wanted to follow-up on the progress as we are in need of this feature. Can we support you in any way to speed up the progress? We would be happy to make contribution or even a one-time donation to compensate you for your time.

icamys commented 1 year ago

@arueckauer Thank you again for your contribution and patience. Version 5.0.0 is now released which supports this feature using setSitemapIndexURL(). If you upgrade, please pay attention to the way the generator is created - the constructor accepts configuration objects instead of arguments. If you are willing to support this project, here's a link to my Patreon page.