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


PHP JTable::__construct方法代码示例

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


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

示例1: __construct

 public function __construct(&$db = null)
 {
     if ($db == null) {
         $db = JFactory::getDbo();
     }
     parent::__construct('#__ganalytics_profiles', 'id', $db);
 }
开发者ID:naquib555,项目名称:quBitolgy,代码行数:7,代码来源:profile.php

示例2: __construct

 /**
  * Constructor
  *
  * @param   JDatabaseDriver  $db  Database connector object
  *
  * @since   1.5
  */
 public function __construct(JDatabaseDriver $db)
 {
     $this->typeAlias = 'com_banners.banner';
     parent::__construct('#__banners', 'id', $db);
     $this->created = JFactory::getDate()->toSql();
     $this->setColumnAlias('published', 'state');
 }
开发者ID:Rai-Ka,项目名称:joomla-cms,代码行数:14,代码来源:banner.php

示例3:

 /**
  * Constructor
  *
  * @param object Database connector object
  */
 function __construct(&$db)
 {
     parent::__construct('#__bt_portfolios', 'id', $db);
     if ($this->id == 0) {
         $this->extra_fields = self::loadExtraFields($this->extra_fields, 0);
     }
 }
开发者ID:Tommar,项目名称:remate,代码行数:12,代码来源:portfolio.php

示例4: __construct

 /**
  * Constructor
  *
  * @param   JDatabase  &$db  A database connector object.
  *
  * @since  11.1
  */
 public function __construct(&$db)
 {
     parent::__construct('#__users', 'id', $db);
     // Initialise.
     $this->id = 0;
     $this->sendEmail = 0;
 }
开发者ID:ronildo,项目名称:joomla-cms,代码行数:14,代码来源:user.php

示例5: time

 function __construct(&$kunena_db)
 {
     $fbConfig =& CKunenaConfig::getInstance();
     parent::__construct('#__fb_sessions', 'userid', $kunena_db);
     $this->lasttime = time() + $fbConfig->board_ofset - KUNENA_SECONDS_IN_YEAR;
     $this->currvisit = time() + $fbConfig->board_ofset;
 }
开发者ID:kaantunc,项目名称:MYK-BOR,代码行数:7,代码来源:kunena.session.class.php

示例6: __construct

 /**
  * Constructor
  *
  * @access public
  * @subpackage Yireo
  * @param string $table_name
  * @param string $primary_key
  * @param JDatabase $db
  * @return null
  */
 public function __construct($table_name, $primary_key, $db)
 {
     // Determine the table name
     $table_namespace = preg_replace('/^com_/', '', JFactory::getApplication()->input->getCmd('option'));
     if (!empty($table_name)) {
         if (!strstr($table_name, '#__')) {
             $table_name = $table_namespace . '_' . $table_name;
         }
     } else {
         $table_name = $table_namespace;
     }
     // Call the constructor to finish construction
     parent::__construct($table_name, $primary_key, $db);
     // Initialize the fields based on an array
     $fields = $this->getDatabaseFields();
     if (!empty($fields)) {
         foreach ($fields as $field) {
             if (!empty($this->_defaults[$field])) {
                 $this->{$field} = $this->_defaults[$field];
             } else {
                 $this->{$field} = null;
             }
         }
     }
 }
开发者ID:apiceweb,项目名称:MageBridgeCore,代码行数:35,代码来源:table.php

示例7:

	/**
	 * Constructor
	 *
	 * @param   database  &$db  A database connector object.
	 *
	 * @return  JTableSession
	 *
	 * @since  11.1
	 */
	function __construct(&$db)
	{
		parent::__construct('#__session', 'session_id', $db);

		$this->guest = 1;
		$this->username = '';
	}
开发者ID:nikosdion,项目名称:Akeeba-Example,代码行数:16,代码来源:session.php

示例8: XmapPlugin

 function XmapPlugin(&$_db, $id = NULL)
 {
     parent::__construct('#__xmap_ext', 'id', $_db);
     if ($id) {
         $this->load($id);
     }
 }
开发者ID:omarmm,项目名称:MangLuoiBDS,代码行数:7,代码来源:XmapPlugin.php

示例9: __construct

 /**
  * Constructor
  *
  * @param   JDatabaseDriver  $db  A database connector object
  *
  * @since   11.1
  */
 public function __construct(JDatabaseDriver $db)
 {
     $this->typeAlias = 'com_content.article';
     parent::__construct('#__content', 'id', $db);
     // Set the alias since the column is called state
     $this->setColumnAlias('published', 'state');
 }
开发者ID:Rai-Ka,项目名称:joomla-cms,代码行数:14,代码来源:content.php

示例10: __construct

 /**
  * Constructor
  *
  * @param   JDatabaseDriver  &$db  Database connector object
  *
  * @since   1.5
  */
 public function __construct(&$db)
 {
     parent::__construct('#__banners', 'id', $db);
     JTableObserverContenthistory::createObserver($this, array('typeAlias' => 'com_banners.banner'));
     $this->created = JFactory::getDate()->toSql();
     $this->setColumnAlias('published', 'state');
 }
开发者ID:SysBind,项目名称:joomla-cms,代码行数:14,代码来源:banner.php

示例11: __construct

 public function __construct(&$db = null)
 {
     parent::__construct('#__dpfields_fields', 'id', $db);
     $this->setColumnAlias('published', 'state');
     JObserverMapper::addObserverClassToClass('JTableObserverTags', 'DPFieldsTableField', array('typeAlias' => 'com_dpfields.field'));
     JObserverMapper::addObserverClassToClass('JTableObserverContenthistory', 'DPFieldsTableField', array('typeAlias' => 'com_dpfields.field'));
 }
开发者ID:beingsane,项目名称:DPFields,代码行数:7,代码来源:field.php

示例12: iCalEventDetail

 /**
  * Null Constructor
  */
 function iCalEventDetail(&$db)
 {
     // get default value for multiday from params
     $cfg = JEVConfig::getInstance();
     $this->_multiday = $cfg->get('multiday', 1);
     parent::__construct('#__jevents_vevdetail', 'evdet_id', $db);
 }
开发者ID:madcsaba,项目名称:li-de,代码行数:10,代码来源:iCalEventDetail.php

示例13: __construct

 /**
  * Constructor
  *
  * @param   JDatabaseDriver  &$_db  Database connector object
  *
  * @since   1.5
  */
 public function __construct(&$_db)
 {
     parent::__construct('#__banners', 'id', $_db);
     JTableObserverContenthistory::createObserver($this, array('typeAlias' => 'com_banners.banner'));
     $date = JFactory::getDate();
     $this->created = $date->toSql();
 }
开发者ID:Tommar,项目名称:remate,代码行数:14,代码来源:banner.php

示例14:

 /**
  * Constructor
  *
  * @param object Database connector object
  * @since 1.0
  */
 function __construct(&$db)
 {
     $tableName = '#__arcna_animals';
     parent::__construct($tableName, 'id', $db);
     $fields =& $this->getFields();
     $this->initDataObject($fields, $this);
 }
开发者ID:snellcode,项目名称:ARCNA-Animals,代码行数:13,代码来源:animals.php

示例15: __construct

 /**
  * Constructor
  *
  * @param   object  $db  Database Object
  * @return  void
  */
 public function __construct(&$db)
 {
     parent::__construct('#__newsletter_mailinglists', 'id', $db);
     //set up the assoc table
     $this->_tbl_assoc = '#__newsletter_mailinglist_emails';
     $this->_tbl_assoc_key = 'id';
 }
开发者ID:kevinwojo,项目名称:hubzero-cms,代码行数:13,代码来源:mailinglist.php


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