Title: [Plugin: Google XML Sitemaps] Errors when generating sitemap
Last modified: August 19, 2016

---

# [Plugin: Google XML Sitemaps] Errors when generating sitemap

 *  [krackerjaxz](https://wordpress.org/support/users/krackerjaxz/)
 * (@krackerjaxz)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/)
 * I got the error when I first tried to build my sitemap as well as get the same
   error when I try to rebuild the sitemap.
 * Warning: mktime() expects parameter 1 to be long, string given in /home/public_html/
   wp-content/plugins/google-sitemap-generator/sitemap-core.php on line 2438
 * The main problem is that the plugin gets stuck in a loop. When that error comes
   up it’s as if the plugin keeps trying and trying and trying. I have to click 
   on some link in WP so that it will end it. I have disabled the plugin for now
   just in case when I add content it tries to rebuild the sitemap. I wouldn’t want
   an infinite loop to end up starting without me knowing it. I’m sure my host would
   have a cow.

Viewing 6 replies - 1 through 6 (of 6 total)

 *  [deank](https://wordpress.org/support/users/deank/)
 * (@deank)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157141)
 * To fix it, I followed the instructions here:
 * [plugin help](http://www.arnebrachhold.de/2006/04/07/google-sitemaps-faq-sitemap-issues-errors-and-problems/?utm_source=wp-wm&utm_medium=install&utm_content=help-files#P28_gen_files)
 * I created two blank text files, named them `sitemap.xml` and `sitemap.xml.gz`,
   put them in my root folder, chmod/changed permissions to make them writable —
   then I went back into the Plugin page and clicked the link to manually re-generate
   the sitemap — worked fine, stopped the infinite looping.
 * You should be able to do that and not have your host want to have a cow 🙂
 *  Thread Starter [krackerjaxz](https://wordpress.org/support/users/krackerjaxz/)
 * (@krackerjaxz)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157147)
 * Thanks. That worked. cmoded them to 644 and it works great.
 * I have this plugin installed on two blogs. Both hosted under the same shared 
   hosting account. That fix fixed the problem on one blog but I still have the 
   same error on another blog. I have even tried deactivating the plugin on the 
   blog in question, deleting the files, reuploading them, and then activating the
   plugin again.
 * Same problem.
 *  [anthonyportal](https://wordpress.org/support/users/anthonyportal/)
 * (@anthonyportal)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157153)
 * Hi DeanK,
 * Kindly take a look on this screenshot, please check whether i upload it to correct
   location
 * [http://i896.photobucket.com/albums/ac163/anthonyportal/root.jpg](http://i896.photobucket.com/albums/ac163/anthonyportal/root.jpg)
 * however i already changed the mentioned 2 file to 777. it still give me the same
   error although i rebuild.
 * any help will appreciate
 * Thank you
 *  Thread Starter [krackerjaxz](https://wordpress.org/support/users/krackerjaxz/)
 * (@krackerjaxz)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157294)
 * That is not correct. I noticed that you have a subdirectory of blog. The way 
   I read it was to upload it to your blog root directory. Therefore, those two 
   files should be moved to the blog directory.
 * Also, in regards to my issue of still having that error message on one of my 
   blogs, I have found a fix. The answer is in this post:
 * [http://wordpress.org/support/topic/281175?replies=8](http://wordpress.org/support/topic/281175?replies=8)
 * Basically, on line 2438 replace this:
 * `return mktime($hour, $min, $sec, $month, $day, $year);`
 * with this:
    `return mktime(doubleval( $hour), $min, $sec, $month, $day, doubleval(
   $year));`
 *  [anthonyportal](https://wordpress.org/support/users/anthonyportal/)
 * (@anthonyportal)
 * [16 years, 10 months ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157484)
 * HI krackerjaxz,
 * Thank you, it worked now.
 *  [davidtrounce](https://wordpress.org/support/users/davidtrounce/)
 * (@davidtrounce)
 * [16 years, 1 month ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157600)
 * Hi,
 * I have installed google sitemaps plugin and am wondering about its interaction
   with my online shop. My wordpress blog is in a subdirectory /blog on my server,
   My Shop (prestashop) is in the root.
 * Will my current sitemap add my blog automatically or should i use another sitemap(
   plug in) for inside my /blog directory? Are their any advantages or disadvantages
   to this and does your plugin affect my shop at all?
 * Also, the same issue applies to google analytics. Will Analytics/webmasters for
   my shop pick up my blog as well or should i set up a new analytics for my /blog?
   Are there any special procedures for this and will it help/hinder my SEO in google?(
   i.e seeing duplicate content or link farming, etc..)
 * Thanks.
 * David

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘[Plugin: Google XML Sitemaps] Errors when generating sitemap’ is closed
to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 6 replies
 * 4 participants
 * Last reply from: [davidtrounce](https://wordpress.org/support/users/davidtrounce/)
 * Last activity: [16 years, 1 month ago](https://wordpress.org/support/topic/plugin-google-xml-sitemaps-errors-when-generating-sitemap/#post-1157600)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
