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


PHP QQN::WpUsers方法代码示例

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


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

示例1: process_object

 /**
  * @param DleUsers $objDleUsers The DB ORM object to process
  */
 protected function process_object($objDleUsers)
 {
     // wp: ID,      user_login, user_nicename, user_email, user_registered,           display_name
     // dl: user_id, name,       name,          email,      FROM_UNIXTIME( reg_date ), fullname
     $strEmail = $objDleUsers->Email;
     if ($strEmail && strlen($strEmail)) {
         // check if already copied
         if (!WpUsers::QueryCount(QQ::Equal(QQN::WpUsers()->UserEmail, $strEmail))) {
             $objWpUsers = new WpUsers();
             $objWpUsers->Initialize();
             // set defaults
             $objWpUsers->UserLogin = $objDleUsers->Name;
             $objWpUsers->UserNicename = $objDleUsers->Name;
             $objWpUsers->UserEmail = $objDleUsers->Email;
             $objWpUsers->UserRegistered = QDateTime::FromTimestamp(intval($objDleUsers->RegDate));
             $objWpUsers->DisplayName = $objDleUsers->Fullname;
             $objWpUsers->UserPass = '';
             $objWpUsers->UserUrl = '';
             $objWpUsers->UserActivationKey = '';
             $objWpUsers->UserStatus = 0;
             $objWpUsers->Save();
             $this->intUserCount++;
         }
     }
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:28,代码来源:WpUsersTask.class.php

示例2: LoadWpUser

 /**
  * @return WpUsers The Wordpress user for this DLE post author.
  */
 public function LoadWpUser()
 {
     $objDleUsers = DleUsers::LoadByName($this->Autor);
     if (!$objDleUsers) {
         return null;
     }
     return WpUsers::QuerySingle(QQ::Equal(QQN::WpUsers()->UserEmail, $objDleUsers->Email), QQ::Clause(QQ::LimitInfo(1)));
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:11,代码来源:DlePost.class.php

示例3: LoadWpUsers

 /**
  * @return WpUsers|null The Wordpress user for this DLE comment author.
  */
 public function LoadWpUsers()
 {
     $objDleUsers = $this->User;
     if (!$objDleUsers) {
         return WpUsers::QuerySingle(QQ::Equal(QQN::WpUsers()->UserEmail, $this->Email), QQ::Clause(QQ::LimitInfo(1)));
     }
     return $objDleUsers->LoadWpUsers();
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:11,代码来源:DleComments.class.php

示例4: LoadFirst

 public function LoadFirst()
 {
     return self::QuerySingle(QQ::All(), QQ::Clause(QQ::OrderBy(QQN::WpUsers()->Id), QQ::LimitInfo(1)));
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:4,代码来源:WpUsers.class.php

示例5: CountByUserNicename

 /**
  * Count WpUserses
  * by UserNicename Index(es)
  * @param string $strUserNicename
  * @return int
  */
 public static function CountByUserNicename($strUserNicename)
 {
     // Call WpUsers::QueryCount to perform the CountByUserNicename query
     return WpUsers::QueryCount(QQ::Equal(QQN::WpUsers()->UserNicename, $strUserNicename));
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:11,代码来源:WpUsersGen.class.php

示例6: LoadWpUsers

 /**
  * @return WpUsers The Wordpress user for this DLE user.
  */
 public function LoadWpUsers()
 {
     return WpUsers::QuerySingle(QQ::Equal(QQN::WpUsers()->UserEmail, $this->Email), QQ::Clause(QQ::LimitInfo(1)));
 }
开发者ID:hiptc,项目名称:dle2wordpress,代码行数:7,代码来源:DleUsers.class.php


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