Can you post your custom module here so I can take a look?
Hi this is my code
` class BWP_GXS_MODULE_SCHOOL_SITEMAP_1 extends BWP_GXS_MODULE {
function __construct() {
$this->set_current_time();
$this->build_data();
}
function build_data() {
global $wpdb, $bwp_gxs, $wp_schoolfinderurl;
/* QUERY TO GET ALBUMS – THE TABLE IS IN THE SAME WORDPRESS DB, SO
YOU CAN USE HERE THE wpdb WORDPRESS CLASS TO INTERACT WITH THE DATABASE */
$sitemap_urls = readUrlFromFile();
/* IF THE TABLE IS IN ANOTHER DATABASE,
YOU CAN USE THE PHP MYSQL FUNCTIONS */
if ( !isset( $sitemap_urls) || 0 == sizeof( $sitemap_urls ))
return false;
$data = array();
for ( $i = 1; $i <= 5000; $i++ ) {
$url = $sitemap_urls[$i];
$data = $this->init_data( $data );
// REPLACE THIS WITH CORRECT URL TO YOUR ALBUMS
// ESPECIALLY YOUR WEBSITE URL
$data[“location”] = $url;
$data[“lastmod”] = $this->format_lastmod(strtotime(current_time(“mysql”)));
$this->data[] = $data;
}
return true;
}
}
Or else please let me know how to remove the Last Modified Date from the sitemap development. So it is fine for me now.
I have fixed the Last modified date issue with Sitemap XML using custom xsl stylesheet.
I removed it using custom xsl, but is it possible to build the current date.?
Hmm try this (replacing the corresponding block):
$now = current_time('timestamp');
$data = array();
for ( $i = 1; $i <= 5000; $i++ ) {
$url = $sitemap_urls[$i];
$data = $this->init_data( $data );
// REPLACE THIS WITH CORRECT URL TO YOUR ALBUMS
// ESPECIALLY YOUR WEBSITE URL
$data["location"] = $url;
$data["lastmod"] = $this->format_lastmod($now);
$this->data[] = $data;
}