private function _mysql_author_load($authorid)
	{
		static $_propertyauthormap = array(
			'uidNumber'    => 'id',
			'givenName'    => 'firstname',
			'middleName'   => 'middlename',
			'surname'      => 'lastname',
			'organization' => 'org',
			'bio'          => 'bio',
			'url'          => 'url',
			'picture'      => 'picture',
			'vip'          => 'principal_investigator'
		);

		$db =  \App::get('db');

		$query = "SELECT * FROM `#__author` WHERE id=" . $db->quote($authorid);

		$db->setQuery($query);

		$result = $db->loadAssoc();

		if ($result === false)
		{
			$this->setError('Error retrieving data from author table: ' . $db->getErrorMsg());
			return false;
		}

		if (empty($result))
		{
			$this->setError('No such author [' . $authorid . ']');
			return false;
		}

		$this->clear();

		foreach ($_propertyauthormap as $property => $aproperty)
		{
			if (!empty($result[$aproperty]))
			{
				$this->set($property, $result[$aproperty]);
			}
		}

		return true;
	}
private function _mysql_author_load($authorid)
	{
		static $_propertyauthormap = array(
			'uidNumber'    => 'id',
			'givenName'    => 'firstname',
			'middleName'   => 'middlename',
			'surname'      => 'lastname',
			'organization' => 'org',
			'bio'          => 'bio',
			'url'          => 'url',
			'picture'      => 'picture',
			'vip'          => 'principal_investigator'
		);

		$db =  \App::get('db');

		$query = "SELECT * FROM `#__author` WHERE id=" . $db->quote($authorid);

		$db->setQuery($query);

		$result = $db->loadAssoc();

		if ($result === false)
		{
			$this->setError('Error retrieving data from author table: ' . $db->getErrorMsg());
			return false;
		}

		if (empty($result))
		{
			$this->setError('No such author [' . $authorid . ']');
			return false;
		}

		$this->clear();

		foreach ($_propertyauthormap as $property => $aproperty)
		{
			if (!empty($result[$aproperty]))
			{
				$this->set($property, $result[$aproperty]);
			}
		}

		return true;
	}
private function _mysql_author_load ( $ authorid ) { static $ _propertyauthormap = array ( 'uidNumber' => 'id' , 'givenName' => 'firstname' , 'middleName' => 'middlename' , 'surname' => 'lastname' , 'organization' => 'org' , 'bio' => 'bio' , 'url' => 'url' , 'picture' => 'picture' , 'vip' => 'principal_investigator' ) ; $ db = \ App :: get ( 'db' ) ; $ query = "SELECT * FROM `#__author` WHERE id=" . $ db -> quote ( $ authorid ) ; $ db -> setQuery ( $ query ) ; $ result = $ db -> loadAssoc ( ) ; if ( $ result === false ) { $ this -> setError ( 'Error retrieving data from author table: ' . $ db -> getErrorMsg ( ) ) ; return false ; } if ( empty ( $ result ) ) { $ this -> setError ( 'No such author [' . $ authorid . ']' ) ; return false ; } $ this -> clear ( ) ; foreach ( $ _propertyauthormap as $ property => $ aproperty ) { if ( ! empty ( $ result [ $ aproperty ] ) ) { $ this -> set ( $ property , $ result [ $ aproperty ] ) ; } } return true ; }
Load an author record into this profile

@param   integer  $authorid  Author ID
@return  boolean  True on success, False on error
Load an author record into this profile