本文整理汇总了PHP中CacheEngine::CachePages方法的典型用法代码示例。如果您正苦于以下问题:PHP CacheEngine::CachePages方法的具体用法?PHP CacheEngine::CachePages怎么用?PHP CacheEngine::CachePages使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CacheEngine
的用法示例。
在下文中一共展示了CacheEngine::CachePages方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: array
$result = $select->commit();
$element = $db->fetch_assoc($result);
$lines = array();
foreach ($element as $db_key => $db_val) {
$lines[] = $db_key . '=>' . $db_val;
}
$insertquery = new DBInsert('interface_history', array('action' => 'edit', 'area' => 'pages', 'field' => intval($key), 'user' => $futurebb_user['id'], 'time' => time(), 'old_value' => base64_encode(implode("\n", $lines))), 'Failed to insert history entry');
$insertquery->commit();
foreach ($val as $field => $field_value) {
//update the field
$updatequery = new DBUpdate('pages', array($field => $field_value), 'id=' . intval($key), 'Failed to update page entry');
$updatequery->commit();
}
}
}
CacheEngine::CachePages();
redirect($base_config['baseurl'] . '/admin/interface/pages');
} else {
echo '<p>Your password was incorrect. Hit the back button to try again.</p>';
return;
}
} else {
if (isset($_POST['form_sent_a'])) {
//submitted, but not confirmed
$changes_list = array();
$changes_submit = array();
while ($page = $db->fetch_assoc($result)) {
if (isset($_POST['url'][$page['id']])) {
//it's changed somehow, reflect the changes
$changed = false;
$cur_change = '<tr><td';
示例2: remove_page
static function remove_page($url)
{
global $db;
$db->query('DELETE FROM `#^pages` WHERE url=\'' . $db->escape($url) . '\'') or enhanced_error('Failed to remove page from database', true);
CacheEngine::CachePages();
}