本文整理匯總了PHP中xPDOObject::__construct方法的典型用法代碼示例。如果您正苦於以下問題:PHP xPDOObject::__construct方法的具體用法?PHP xPDOObject::__construct怎麽用?PHP xPDOObject::__construct使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類xPDOObject
的用法示例。
在下文中一共展示了xPDOObject::__construct方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: __construct
/**
* Ye olde Calculated fields (aka Accessors)
*/
public function __construct(xPDO &$xpdo)
{
parent::__construct($xpdo);
self::$x = $xpdo;
$this->_fields['url'] = $this->get('url');
$this->_fields['path'] = $this->get('path');
$this->_fields['basename'] = $this->get('basename');
$this->_fields['thumbnail_url'] = $this->get('thumbnail_url');
$this->_fields['thumbnail_width'] = $this->get('thumbnail_width');
$this->_fields['thumbnail_height'] = $this->get('thumbnail_height');
}
示例2: __construct
public function __construct(&$xpdo)
{
parent::__construct($xpdo);
}
示例3:
/**
* Overrides xPDOObject::__construct to set the _cacheFlag var for this class to false.
*
* @param xPDO $xpdo Reference to the xPDO|modX instance
*/
function __construct(&$xpdo)
{
parent::__construct($xpdo);
$this->_cacheFlag = false;
}
示例4: __construct
public function __construct(&$xpdo)
{
parent::__construct($xpdo);
$this->xpdo->loadClass('transport.xPDOTransport', XPDO_CORE_PATH, true, true);
}
示例5: __construct
/**
* Override to provide calculated fields
*/
public function __construct(xPDO &$xpdo)
{
parent::__construct($xpdo);
$this->_fields['calculated_price'] = $this->get('calculated_price');
}