XML Sitemaps Generator

Author Topic: Last madified time & date in xml sitemap?  (Read 9102 times)

syeyehya

  • Registered Customer
  • Approved member
  • *
  • Posts: 4
Last madified time & date in xml sitemap?
« on: December 07, 2009, 09:52:32 PM »
I understand that as I am using a php site then the last mod field is the last time that the page was accessed.

Is there a way to work around this issue in simple terms please?

It would be nice to reflect the real last modified times as this would stop the robots crawling the same pages over and over.

Many thanks,

Sye

XML-Sitemaps Support

  • Administrator
  • Hero Member
  • *****
  • Posts: 10624
Re: Last madified time & date in xml sitemap?
« Reply #1 on: December 07, 2009, 10:34:13 PM »
Hello,

you will need to modify your website's PHP script by adding a lst modified http header with code similar to:
Code: [Select]
<?php
header
('Last-modified: ' gmdate('D, d M Y H:i:s'$your_lastmod_date));
?>
Oleg Ignatiuk
www.xml-sitemaps.com
Send me a Private Message

For maximum exposure and traffic for your web site check out our additional SEO Services.

syeyehya

  • Registered Customer
  • Approved member
  • *
  • Posts: 4
Re: Last madified time & date in xml sitemap?
« Reply #2 on: December 08, 2009, 06:06:45 PM »
Thanks, I will ask my web guy to do it.

 

SMF 2.0.12 | SMF © 2014, Simple Machines
XHTML RSS WAP2