當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Base::Save方法代碼示例

本文整理匯總了PHP中Base::Save方法的典型用法代碼示例。如果您正苦於以下問題:PHP Base::Save方法的具體用法?PHP Base::Save怎麽用?PHP Base::Save使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Base的用法示例。


在下文中一共展示了Base::Save方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: Save

 function Save()
 {
     global $zbp;
     if ($this->Template == $zbp->option['ZC_INDEX_DEFAULT_TEMPLATE']) {
         $this->Data['Template'] = '';
     }
     return parent::Save();
 }
開發者ID:jdjjdkdkdm,項目名稱:zblogphp,代碼行數:8,代碼來源:tag.php

示例2: RegPage_CreateCode

function RegPage_CreateCode($n)
{
    global $zbp;
    for ($i = 0; $i < 100; $i++) {
        $r = new Base($GLOBALS['RegPage_Table'], $GLOBALS['RegPage_DataInfo']);
        $r->InviteCode = GetGuid();
        $r->Level = $zbp->Config('RegPage')->default_level;
        $r->Save();
    }
}
開發者ID:zblogcn,項目名稱:zblogphp,代碼行數:10,代碼來源:include.php

示例3: Save

 function Save()
 {
     global $zbp;
     if ($this->Template == $zbp->option['ZC_INDEX_DEFAULT_TEMPLATE']) {
         $this->data['Template'] = '';
     }
     foreach ($GLOBALS['Filter_Plugin_Tag_Save'] as $fpname => &$fpsignal) {
         $fpreturn = $fpname($this);
         if ($fpsignal == PLUGIN_EXITSIGNAL_RETURN) {
             return $fpreturn;
         }
     }
     return parent::Save();
 }
開發者ID:jdjjdkdkdm,項目名稱:zblogphp,代碼行數:14,代碼來源:tag.php

示例4: Save

 /**
  * @return bool
  */
 public function Save()
 {
     global $zbp;
     if ($this->Type == ZC_POST_TYPE_ARTICLE) {
         if ($this->Template == GetValueInArray($this->Category->GetData(), 'LogTemplate')) {
             $this->data['Template'] = '';
         }
     }
     if ($this->Template == $zbp->GetPostType_Template($this->Type)) {
         $this->data['Template'] = '';
     }
     foreach ($GLOBALS['hooks']['Filter_Plugin_Post_Save'] as $fpname => &$fpsignal) {
         $fpsignal = PLUGIN_EXITSIGNAL_NONE;
         $fpreturn = $fpname($this);
         if ($fpsignal == PLUGIN_EXITSIGNAL_RETURN) {
             return $fpreturn;
         }
     }
     return parent::Save();
 }
開發者ID:zblogcn,項目名稱:zblogphp,代碼行數:23,代碼來源:post.php

示例5: Save

 /**
  * @return bool
  */
 function Save()
 {
     global $zbp;
     foreach ($GLOBALS['Filter_Plugin_Module_Save'] as $fpname => &$fpsignal) {
         $fpreturn = $fpname($this);
         if ($fpsignal == PLUGIN_EXITSIGNAL_RETURN) {
             $fpsignal = PLUGIN_EXITSIGNAL_NONE;
             return $fpreturn;
         }
     }
     if ($this->Source == 'theme') {
         if (!$this->FileName) {
             return true;
         }
         $c = $this->Content;
         $d = $zbp->usersdir . 'theme/' . $zbp->theme . '/include/';
         $f = $d . $this->FileName . '.php';
         if (!file_exists($d)) {
             @mkdir($d, 0755);
         }
         @file_put_contents($f, $c);
         return true;
     }
     return parent::Save();
 }
開發者ID:jdjjdkdkdm,項目名稱:zblogphp,代碼行數:28,代碼來源:module.php

示例6: Save

 /**
  * 保存評論數據
  * @return bool
  */
 function Save()
 {
     global $zbp;
     foreach ($GLOBALS['hooks']['Filter_Plugin_Comment_Save'] as $fpname => &$fpsignal) {
         $fpsignal = PLUGIN_EXITSIGNAL_NONE;
         $fpreturn = $fpname($this);
         if ($fpsignal == PLUGIN_EXITSIGNAL_RETURN) {
             return $fpreturn;
         }
     }
     return parent::Save();
 }
開發者ID:ijustyce,項目名稱:zblogphp,代碼行數:16,代碼來源:comment.php

示例7: Save

 /**
  * @return bool
  */
 public function Save()
 {
     global $zbp;
     $this->Content = str_replace($zbp->host, '{$host}', $this->Content);
     foreach ($GLOBALS['hooks']['Filter_Plugin_Module_Save'] as $fpname => &$fpsignal) {
         $fpsignal = PLUGIN_EXITSIGNAL_NONE;
         $fpreturn = $fpname($this);
         if ($fpsignal == PLUGIN_EXITSIGNAL_RETURN) {
             return $fpreturn;
         }
     }
     if ($this->Source == 'theme') {
         if (!$this->FileName) {
             return true;
         }
         $c = $this->Content;
         $d = $zbp->usersdir . 'theme/' . $zbp->theme . '/include/';
         $f = $d . $this->FileName . '.php';
         if (!file_exists($d)) {
             @mkdir($d, 0755);
         }
         @file_put_contents($f, $c);
         return true;
     }
     //return parent::Save();
     //防Module重複保存的機製
     $m = $zbp->GetListType('Module', $zbp->db->sql->get()->select($zbp->table['Module'])->where(array('=', $zbp->datainfo['Module']['FileName'][0], $this->FileName))->sql);
     if (count($m) < 1) {
         return parent::Save();
     } else {
         if ($this->ID == 0) {
             return false;
         }
         return parent::Save();
     }
 }
開發者ID:zblogcn,項目名稱:zblogphp,代碼行數:39,代碼來源:module.php


注:本文中的Base::Save方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。