function boost_crawler_count in Boost 6
Count the number of URL's in the boost_cache table.
Parameters
$push_setting: Default crawler setting for the content type
$extension: File extension, controls the content type DB lookup
$expire: Has the site changed, if so get expire column
1 call to boost_crawler_count()
- boost_crawler_add_to_table in ./
boost.module - Add URL's to the boost_crawler table.
File
- ./
boost.module, line 6145 - Provides static file caching for Drupal text output. Pages, Feeds, ect...
Code
function boost_crawler_count($push_setting, $extension, $expire) {
if ($push_setting) {
if ($expire && BOOST_LOOPBACK_BYPASS) {
return db_result(db_query("SELECT COUNT(*) FROM {boost_cache} WHERE push <> 0 AND extension = '%s' AND expire BETWEEN 0 AND %d", $extension, BOOST_TIME));
}
else {
return db_result(db_query("SELECT COUNT(*) FROM {boost_cache} WHERE push <> 0 AND extension = '%s' AND expire = 0", $extension));
}
}
else {
if ($expire && BOOST_LOOPBACK_BYPASS) {
return db_result(db_query("SELECT COUNT(*) FROM {boost_cache} WHERE push = 1 AND extension = '%s' AND expire BETWEEN 0 AND %d", $extension, BOOST_TIME));
}
else {
return db_result(db_query("SELECT COUNT(*) FROM {boost_cache} WHERE push = 1 AND extension = '%s' AND expire = 0", $extension));
}
}
}