public function dealprocates()
 {
     $ordernums = I('post.procate_ordernum');
     $title = I('post.procate_title');
     if (is_array($ordernums)) {
         foreach ($ordernums as $cid => $value) {
             $procate['ordernum'] = intval($value);
             $procate['title'] = $title[$cid];
             M('procates')->where("cid={$cid}")->save($procate);
         }
     }
     writeProductsCateCache();
     $this->success('更新成功', 'classify');
 }
Exemple #2
0
 $types = explode(",", $cachetype);
 if ($cachetype == 'all' || in_array('langs', $types)) {
     writeLangsCache();
 }
 if ($cachetype == 'all' || in_array('settings', $types)) {
     writeGlobalCache();
     writeSettingsCache();
 }
 if ($cachetype == 'all' || in_array('contact', $types)) {
     writeContactCache();
 }
 if ($cachetype == 'all' || in_array('channels', $types)) {
     writeChannelsCache();
 }
 if ($cachetype == 'all' || in_array('procates', $types)) {
     writeProductsCateCache();
 }
 if ($cachetype == 'all' || in_array('links', $types)) {
     writeLinksCache();
 }
 if ($cachetype == 'all' || in_array('votes', $types)) {
     writeVotesCache();
 }
 if ($cachetype == 'all' || in_array('folders', $types)) {
     writeFoldersCache();
 }
 if ($cachetype == 'all' || in_array('users', $types)) {
     writeUsersCache();
 }
 if ($cachetype == 'all' || in_array('templatevars', $types)) {
     writeTemplatevarsCache();
Exemple #3
0
function reBuildLang()
{
    global $db, $_SYS;
    $rows = $db->row_select("langs", "ishidden=0", 0, "*", "isdefault desc,ordernum");
    $langs = array();
    foreach ($rows as $row) {
        $_SYS['alangid'] = $row['id'];
        writeSettingsCache();
        writeLinksCache();
        writeChannelsCache();
        writeProductsCateCache();
        writeContactCache();
        writeVotesCache();
        writeTemplatevarsCache();
    }
}