当前位置: 首页>>代码示例>>PHP>>正文


PHP POD类代码示例

本文整理汇总了PHP中POD的典型用法代码示例。如果您正苦于以下问题:PHP POD类的具体用法?PHP POD怎么用?PHP POD使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了POD类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: showYearAndTermAction

 public function showYearAndTermAction()
 {
     $sql = "select Eva_year_term from evaluate order by Eva_year_term desc limit 1";
     require_once $_SERVER['DOCUMENT_ROOT'] . '/school' . '/model/pod.php';
     $pod = new POD();
     $result = $pod->query($sql);
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:7,代码来源:evaluate.php

示例2: memberLinkInfo

 public function memberLinkInfo($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('studentAssocationMemberItem' => 'stu_union_member', 'studentInfoItem' => 'stu_basic_info');
     $table = array('stu_union_member', 'stu_basic_info');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:studentAssocationMemberItem.php

示例3: classLinkStaff

 public function classLinkStaff($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('classItem' => 'class', 'staffInfoItem' => 'emp_basic_info');
     $table = array('class', 'emp_basic_info');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:classItem.php

示例4: projectLinkGroup

 public function projectLinkGroup($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('researchGroupProjectItem' => 'res_group_achievement', 'researchGroupItem' => 'res_group');
     $table = array('res_group_achievement', 'res_group');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:researchGroupProjectItem.php

示例5: awardLinkTeacher

 public function awardLinkTeacher($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('teacherInfoItem' => 'teacher_basic_info', 'teacherAwardItem' => 'teacher_award');
     $table = array('teacher_award', 'teacher_basic_info');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:teacherAwardItem.php

示例6: stuLinkClass

 public function stuLinkClass($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('studentIdentityItem' => 'stu_identification_info', 'studentInfoItem' => 'stu_basic_info');
     $table = array('stu_identification_info', 'stu_basic_info');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:evaluateTypeItem.php

示例7: messageLinkContent

 public function messageLinkContent($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('messageContentItem' => 'message', 'messageContraceItem' => 'message_interconnect');
     $table = array('message', 'message_interconnect');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:messageContraceItem.php

示例8: logLinkGroupMember

 public function logLinkGroupMember($req, $lk, $arg)
 {
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $map = array('researchGroupMemberItem' => 'res_member', 'researchGroupLogItem' => 'res_group_log');
     $table = array('res_member', 'res_group_log');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:13,代码来源:researchGroupLogItem.php

示例9: removeAll

 function removeAll($removeAttachments = true)
 {
     global $database;
     $blogid = getBlogId();
     POD::query("UPDATE {$database['prefix']}BlogStatistics SET visits = 0 WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}DailyStatistics WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Categories WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Attachments WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Comments WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}RemoteResponses WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}RemoteResponseLogs WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}TagRelations WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Entries WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Links WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Filters WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}RefererLogs WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}RefererStatistics WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}Plugins WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}FeedStarred WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}FeedReads WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}FeedGroupRelations WHERE blogid = {$blogid}");
     POD::query("DELETE FROM {$database['prefix']}FeedGroups WHERE blogid = {$blogid}");
     if (file_exists(__TEXTCUBE_CACHE_DIR__ . "/rss/{$blogid}.xml")) {
         unlink(__TEXTCUBE_CACHE_DIR__ . "/rss/{$blogid}.xml");
     }
     if ($removeAttachments) {
         Path::removeFiles(Path::combine(ROOT, 'attach', $blogid));
     }
 }
开发者ID:Avantians,项目名称:Textcube,代码行数:29,代码来源:Textcube.Data.php

示例10: getEntriesByKeyword

function getEntriesByKeyword($blogid, $keyword)
{
    global $database;
    $keyword = POD::escapeString($keyword);
    $visibility = doesHaveOwnership() ? '' : 'AND visibility > 1';
    return POD::queryAll("SELECT id, userid, title, category, comments, published \n\t\t\tFROM {$database['prefix']}Entries \n\t\t\tWHERE blogid = {$blogid} \n\t\t\t\tAND draft = 0 {$visibility} \n\t\t\t\tAND category >= 0 \n\t\t\t\tAND (title LIKE '%{$keyword}%' OR content LIKE '%{$keyword}%')\n\t\t\tORDER BY published DESC");
}
开发者ID:hinablue,项目名称:TextCube,代码行数:7,代码来源:blog.keyword.php

示例11: facebookSocialPlugins

function facebookSocialPlugins($target, $mother)
{
    global $database, $suri, $blog, $configVal;
    $data = Misc::fetchConfigVal($configVal);
    $output = '';
    $directive = array('archive', 'category', 'guestbook', 'imageResizer', 'link', 'login', 'logout', 'pannels', 'protected', 'search', 'tag', 'trackback', 'rss', 'atom', 'ientry', 'sync', 'm', 'commentcomment');
    if (in_array(str_replace('/', '', $suri['directive']), $directive)) {
        return $target;
    }
    $permalink = $blog['useSloganOnPost'] ? 'entry/' . POD::queryCell("SELECT `slogan` FROM {$database['prefix']}Entries WHERE `id`={$mother} LIMIT 1") : $mother;
    $permalink = urlencode(getBlogURL() . '/' . $permalink);
    $title = urlencode(POD::queryCell("SELECT `title` FROM {$database['prefix']}Entries WHERE `id`={$mother} LIMIT 1"));
    $output = '<div style="margin-top:1em;width:auto;height:auto;clear:both;">';
    $__width = !isset($data['content_width']) || (int) $data['content_width'] <= 0 ? 520 : $data['content_width'];
    if ($data['like_button']) {
        $output .= '<div class="fb-like" data-href="' . $permalink . '" data-send="true" data-width="' . $__width . '" data-show-faces="true"></div>';
    }
    if ($data['comments']) {
        $output .= '<div class="fb-comments" data-href="' . $permalink . '" data-num-posts="2" data-width="' . $__width . '"></div>';
    }
    if ($data['share']) {
        $output .= '<div class="fb-send" data-href="' . $permalink . '"></div>';
    }
    $output .= '</div><br />';
    return $target . $output;
}
开发者ID:hinablue,项目名称:TextCube,代码行数:26,代码来源:index.php

示例12: close

 function close()
 {
     if (isset($this->_result)) {
         POD::free($this->_result);
         unset($this->_result);
     }
     $this->_count = 0;
     $this->reset();
 }
开发者ID:webhacking,项目名称:Textcube,代码行数:9,代码来源:Textcube.Data.Category.php

示例13: removeServiceSetting

function removeServiceSetting($name, $pruneSimilarEntries = false)
{
    global $database;
    clearServiceSettingCache();
    if ($pruneSimilarEntries) {
        return POD::execute("DELETE FROM {$database['prefix']}ServiceSettings WHERE name like '" . POD::escapeString($name) . "'");
    } else {
        return POD::execute("DELETE FROM {$database['prefix']}ServiceSettings WHERE name = '" . POD::escapeString($name) . "'");
    }
}
开发者ID:hinablue,项目名称:TextCube,代码行数:10,代码来源:common.setting.php

示例14: queryColumnWithDBCache

 public static function queryColumnWithDBCache($query, $prefix = null, $type = 'both', $count = -1)
 {
     $cache = queryCache::getInstance();
     $cache->reset($query, $prefix);
     if (!$cache->load()) {
         $cache->contents = POD::queryColumn($query, $type, $count);
         $cache->update();
     }
     return $cache->contents;
 }
开发者ID:ragi79,项目名称:Textcube,代码行数:10,代码来源:POD.php

示例15: test2Action

 public function test2Action()
 {
     require $_SERVER['DOCUMENT_ROOT'] . '/school' . '/model/pod.php';
     $db = new POD();
     $p = $db->connect();
     if ($p == false) {
         throw new Exception('Database connect failed');
     }
     $req = array();
     $lk = array('account');
     $req[0] = array('key' => 'account', 'account' => '111', 'table' => 'p');
     $arg = array('name', 'password');
     $table = array('Person', 'Account');
     $map = array('p' => 'Person', 'a' => 'Account');
     $sql = $db->genLinkSql($req, $lk, $arg, $table, $map);
     //echo $sql;
     //exit;
     $res = $db->query($sql);
     return $res;
 }
开发者ID:muzhiqiang,项目名称:school,代码行数:20,代码来源:test.php


注:本文中的POD类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。