ok, the box is one as well as the header and footer, check here:
http://www.music-web.org/sitemap.php
Moderator: Moderators

// Never know who might have tricked us![]()
else
{
mx_sitemaps_message_die(GENERAL_MESSAGE, 'Invalid request');
}
<?php
/***************************************************************************
* sitemap.php
* -------------------
* begin : Saturday, Feb 20, 2006
* copyright : (C) dcz
* Contact : www.phpbb-seo.com
*
* $Id: sitemap.php, v1.0.1 2006/06/14 18:05:13 fds Exp $
*
*
***************************************************************************/
/***************************************************************************
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
***************************************************************************/
//mxBB PORTAL
// YOU SHOULD SET HERE THE CORRECT PATH IN CASE YOUR PORTAL IN INSTALLED
// IN A SUB FOLDER (STARTING FROM ROOT E.G. 'mxBB/')
$mx_root_path = '';
define('IN_PHPBB', true);
$phpbb = TRUE;
// YOU HAVE TO SET THE CORRECT PATH FOR PHPBB IF YOU WANT
// TO USE THIS SITEMAP SYSTEM OUTSIDE OF THE PHPBB FOLDER
// AND TO LOOK AT LINE 72 too ;-)
$mx_root_path = $module_root_path2 = $module_root_path = $phpbb_root_path = '';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
// Start session management
$userdata = session_pagestart($user_ip, PAGE_INDEX);
init_userprefs($userdata);
// Good old heavy method. Do this here to allow for sitemap installation at the server root level
$script_name = preg_replace('/^\/?(.*?)\/?$/', '\1', trim($board_config['script_path']));
$server_name = trim($board_config['server_name']);
$server_protocol = 'http://'; // No https here, since it's ment for google Bots
$server_port = ($board_config['server_port'] <> 80) ? ':' . trim($board_config['server_port']) . '/' : '/';
$root_url = $server_protocol . $server_name . $server_port;
$server_url = $root_url . $script_name;
if(substr($server_url, -1, 1) != "/")
{
$server_url .= "/";
}
// Comment this line if you put your sitemap in the root folder
// and phpbb installed in a subfolder.
$root_url = ($phpbb) ? $server_url : $root_url;
//
// Include common module stuff...
//
include($module_root_path . 'mx_ggsitemaps/includes/common_GGsitemaps.' . $phpEx);
// Grab ggsitemaps config
$sql = "SELECT * FROM " . GGSITEMAP_TABLE;
if( !$result = $db->sql_query($sql) )
{
mx_sitemaps_message_die(GENERAL_ERROR, "Couldn't get Google sitemaps config information", "", __LINE__, __FILE__, $sql);
}
while ( $row = $db->sql_fetchrow($result) )
{
$ggsitemap_config[$row['config_name']] = $row['config_value'];
}
// Even this is too much to stay for nothing
$db->sql_freeresult($result);
// Set some usefull vars
$sql_limit = $ggsitemap_config['sitemap_sql_limit'];
$url_limit = $ggsitemap_config['sitemap_url_limit'];
$sitemap_ver = $ggsitemap_config['sitemap_ver'];
$C_info = $ggsitemap_config['sitemap_c_info'];
$Rewrite_sitemap = ( $ggsitemap_config['sitemap_rewrited'] == "TRUE" ) ? TRUE : FALSE;
$is_index = false;
$started = false;
$query_ok = TRUE;
// Since echo is the fast way here, let's define headers and footers
// Those are inteded to allow validation
//Sitemaps
// DO NOT REMOVE (C) INFOS !!!
$S_header = '<?xml version=\'1.0\' encoding=\'UTF-8\'?>
<urlset xmlns="http://www.google.com/schemas/sitemap/0.84"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.google.com/schemas/sitemap/0.84
http://www.google.com/schemas/sitemap/0.84/sitemap.xsd">
<!-- Generated by mx Google Sitemaps ' . $sitemap_ver . ' - ' . $C_info . ' -->' . "\n";
$S_footer = '</urlset>';
//Sitemap index
// DO NOT REMOVE (C) INFOS !!!
$I_header = '<?xml version=\'1.0\' encoding=\'UTF-8\'?>
<sitemapindex xmlns="http://www.google.com/schemas/sitemap/0.84"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.google.com/schemas/sitemap/0.84
http://www.google.com/schemas/sitemap/0.84/siteindex.xsd">
<!-- Generated by mx Google Sitemaps ' . $sitemap_ver . ' - ' . $C_info . ' -->' . "\n";
$I_footer = '</sitemapindex>';
// Load sitemaps, I know this mean that all module are included here
// even if they end not being asked for, but what is the cost of
// even a dozen $_GET performed in several includes for a page that's
// not supposed to be even loaded ten times a day?
$location = $module_root_path . 'mx_ggsitemaps/includes';
$dir = @opendir( $location );
while( $file = @readdir($dir) )
{
if( preg_match("/^sitemap_.*?\." . $phpEx . "$/", $file) )
{
include_once($location . '/' . $file);
}
}
@closedir($dir);
// Check if nobody tricked us
if ($started)
{
mx_sitemaps_redirect(append_sid("index.$phpEx"));
}
// Nothing matched so it's an index
elseif (!$started)
{
$is_index = true;
// Load sitemap index
$dir = @opendir( $location );
while( $file = @readdir($dir) )
{
if( preg_match("/^index_.*?\." . $phpEx . "$/", $file) )
{
include_once($location . '/' . $file);
}
}
@closedir($dir);
}
// End output if necessary
if ($started)
{
echo $I_footer;
exit;
}
?>
elseif (!$started)
{
$is_index = true;
// Load sitemap index
$dir = @opendir( $location );
while( $file = @readdir($dir) )
{
if( preg_match("/^index_.*?\." . $phpEx . "$/", $file) )
{
include_once($location . '/' . $file);
}
}
@closedir($dir);
}
// End output if necessary
if ($started)
{
echo $I_footer;
exit;
} elseif (!$started)
{
$is_index = true;
header("Content-type: text/xml");
echo $I_header;
// Load sitemap index
$dir = @opendir( $location );
while( $file = @readdir($dir) )
{
if( preg_match("/^index_.*?\." . $phpEx . "$/", $file) )
{
include_once($location . '/' . $file);
}
}
@closedir($dir);
}
// End output if necessary
if ($is_index)
{
echo $I_footer;
exit;
} //Output start if necessary
if (!$started)
{
header("Content-type: text/xml");
$started = true;
echo $I_header;
}




it's rather simple to use.

dcz wrote:Please start a new topic if needed though, in the robots forum as we are attempting to crawl a web site.

Users browsing this forum: No registered users and 2 guests