本文整理汇总了PHP中PMF_Init::cleanRequest方法的典型用法代码示例。如果您正苦于以下问题:PHP PMF_Init::cleanRequest方法的具体用法?PHP PMF_Init::cleanRequest怎么用?PHP PMF_Init::cleanRequest使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PMF_Init
的用法示例。
在下文中一共展示了PMF_Init::cleanRequest方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: trim
}
if (!isset($changeFreq)) {
$changeFreq = PMF_SITEMAP_GOOGLE_CHANGEFREQ_DAILY;
}
$node = '<url>' . '<loc>' . PMF_String::htmlspecialchars($location) . '</loc>' . '<lastmod>' . $lastmod . '</lastmod>' . '<changefreq>' . $changeFreq . '</changefreq>' . (isset($priority) ? '<priority>' . $priority . '</priority>' : '') . '</url>';
return $node;
}
//
// Future improvements
// WHEN a User PMF Sitemap will be:
// a. bigger than 10MB (!)
// b. w/ more than 50K URLs (!)
// we'll manage this issue using a Sitemap Index Files produced by this PHP code
// including Sitemap URLs always produced by this same PHP code (see PMF_SITEMAP_GOOGLE_GET_INDEX)
//
PMF_Init::cleanRequest();
session_name(PMF_COOKIE_NAME_AUTH . trim($faqconfig->get('main.phpMyFAQToken')));
session_start();
$oFaq = new PMF_Faq();
// Load the faq
$items = $oFaq->getTopTenData(PMF_SITEMAP_GOOGLE_MAX_URLS - 1);
$visitsMax = 0;
$visitMin = 0;
if (count($items) > 0) {
$visitsMax = $items[0]['visits'];
$visitMin = $items[count($items) - 1]['visits'];
}
// Sitemap header
$sitemap = '<?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">';
// 1st entry: the faq server itself
$sitemap .= buildSitemapNode(PMF_Link::getSystemUri('/sitemap.google.php'), PMF_Date::createISO8601Date($_SERVER['REQUEST_TIME'], false), PMF_SITEMAP_GOOGLE_CHANGEFREQ_DAILY, PMF_SITEMAP_GOOGLE_PRIORITY_MAX);