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


PHP Profile::id方法代码示例

本文整理汇总了PHP中Profile::id方法的典型用法代码示例。如果您正苦于以下问题:PHP Profile::id方法的具体用法?PHP Profile::id怎么用?PHP Profile::id使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Profile的用法示例。


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

示例1: ListMergeIssues

 private static function ListMergeIssues(Profile $profile)
 {
     if (Platal::globals()->merge->state != 'done') {
         return null;
     }
     $flags = XDB::fetchOneCell('SELECT  issues
                                   FROM  profile_merge_issues
                                  WHERE  pid = {?}', $profile->id());
     if (!$flags) {
         return null;
     }
     return new PlFlagSet($flags);
 }
开发者ID:Ekleog,项目名称:platal,代码行数:13,代码来源:profile_update.inc.php

示例2: modify

 protected function modify(Profile $profile)
 {
     $q = $this->dao->prepare('UPDATE ' . $this->table() . ' SET GENDER = :gender, LASTNAME = :lastname, FIRSTNAME = :firstname, DESCRIPTION = :description, PHONE = :phone, MOBILE_PHONE = :mobilePhone, OFFICE_PHONE = :officePhone, WEBSITE = :website, AVATAR = :avatar, USER_ID = :userId, MAIN_ADDRESS_ID = :mainAddressId, ALTERNATE_CURRENCIES_USED = :alternateCurrenciesUsed WHERE ID = :id');
     $q->bindValue(':gender', $profile->getGender());
     $q->bindValue(':lastname', $profile->getLastname());
     $q->bindValue(':firstname', $profile->getFirstname());
     $q->bindValue(':description', $profile->getDescription());
     $q->bindValue(':phone', $profile->getPhone());
     $q->bindValue(':mobilePhone', $profile->getMobilePhone());
     $q->bindValue(':officePhone', $profile->getOfficePhone());
     $q->bindValue(':website', $profile->getWebsite());
     $q->bindValue(':avatar', $profile->getAvatar());
     $q->bindValue(':userId', $profile->getUserId(), PDO::PARAM_INT);
     $q->bindValue(':mainAddressId', $profile->getMainAddressId(), PDO::PARAM_INT);
     $q->bindValue(':alternateCurrenciesUsed', $profile->getAlternateCurrenciesUsed());
     $q->bindValue(':id', $profile->id(), PDO::PARAM_INT);
     $q->execute();
 }
开发者ID:Tipkin-Commons,项目名称:tipkin,代码行数:18,代码来源:ProfilesManager_PDO.class.php

示例3: delRegistered

 public function delRegistered(PlPage $page, Profile $profile)
 {
     XDB::execute('DELETE FROM  contacts
                         WHERE  uid = {?} AND contact = {?}', S::i('uid'), $profile->id());
     if (XDB::affectedRows() > 0) {
         S::user()->invalidWatchCache();
         Platal::session()->updateNbNotifs();
         $page->trigSuccess("Contact retiré !");
     }
 }
开发者ID:Ekleog,项目名称:platal,代码行数:10,代码来源:carnet.php

示例4: checkProfile

 /** Check that the profile match the given rule.
  */
 public function checkProfile(Profile $profile)
 {
     $this->requireProfiles();
     $this->buildQuery();
     $count = (int) XDB::rawFetchOneCell('SELECT  COUNT(*)
                                        ' . $this->query . XDB::format(' AND p.pid = {?}', $profile->id()));
     return $count == 1;
 }
开发者ID:Ekleog,项目名称:platal,代码行数:10,代码来源:userfilter.php

示例5: isWatchedUser

 public function isWatchedUser(Profile $profile)
 {
     return in_array($profile->id(), $this->watchUsers());
 }
开发者ID:pombredanne,项目名称:platal,代码行数:4,代码来源:user.php

示例6: update_display_names

function update_display_names(Profile $profile, array $public_names, array $private_names = null)
{
    if (is_null($private_names)) {
        $private_names = XDB::fetchAllAssoc('SELECT  type, name
                                               FROM  profile_private_names
                                              WHERE  pid = {?}
                                           ORDER BY  type, id', $profile->id());
    }
    $display_names = build_display_names($public_names, $private_names, $profile->isFemale());
    XDB::execute('UPDATE  profile_display
                     SET  public_name = {?}, private_name = {?},
                          directory_name = {?}, short_name = {?}, sort_name = {?}
                   WHERE  pid = {?}', $display_names['public_name'], $display_names['private_name'], $display_names['directory_name'], $display_names['short_name'], $display_names['sort_name'], $profile->id());
    Profile::rebuildSearchTokens($profile->id(), false);
    if ($profile->owner()) {
        update_account_from_profile($profile->owner()->id());
    }
}
开发者ID:pombredanne,项目名称:platal,代码行数:18,代码来源:name.func.inc.php

示例7: register

 public static function register(Profile $profile, $field)
 {
     XDB::execute('INSERT INTO  watch_profile (pid, ts, field)
                        VALUES  ({?}, NOW(), {?})
       ON DUPLICATE KEY UPDATE  ts = NOW()', $profile->id(), $field);
 }
开发者ID:Ekleog,项目名称:platal,代码行数:6,代码来源:notifs.inc.php


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