示例#1
0
 /**
  * Method to load a KunenaForumTopic object by id.
  *
  * @param null $id	The topic id to be loaded.
  *
  * @return bool	True on success.
  */
 public function load($id = null)
 {
     $exists = parent::load($id);
     $this->_hold = $this->hold === null ? 1 : $this->hold;
     $this->_posts = $this->posts;
     return $exists;
 }
示例#2
0
 /**
  * @see KunenaDatabaseObject::load()
  *
  * @param null $id
  *
  * @return bool
  */
 public function load($id = null)
 {
     $exists = parent::load($id);
     if (!$this->_saving) {
         $this->_alias = $this->get('alias', '');
     }
     $registry = new JRegistry();
     if ($this->params) {
         $registry->loadString($this->params);
     }
     $this->params = $registry;
     // Register category if it exists
     if ($exists) {
         KunenaForumCategoryHelper::register($this);
     }
     return $exists;
 }
示例#3
0
 /**
  * Method to load a KunenaForumMessage object by id.
  *
  * @param mixed $id	The message id to be loaded
  *
  * @return bool	True on success
  */
 public function load($id = null)
 {
     $exists = parent::load($id);
     $this->_hold = $exists ? $this->hold : 1;
     $this->_thread = $this->thread;
     return $exists;
 }
示例#4
0
	/**
	 * (non-PHPdoc)
	 * @see KunenaDatabaseObject::load()
	 */
	public function load($id = null) {
		$exists = parent::load($id);

		// Register category if it exists
		if ($exists) KunenaForumCategoryHelper::register($this);
		return $exists;
	}