/** * Retrieves a user's profile as an entry * * @param string $user (optional) The username of interest * @param mixed $location (optional) The URL to query or a * Zend_Gdata_Query object from which a URL can be determined * @return Zend_Gdata_YouTube_UserProfileEntry The user profile entry */ public function getUserProfile($user = null, $location = null) { if ($user !== null) { $uri = self::USER_URI . '/' . $user; } else { if ($location instanceof Zend_Gdata_Query) { $uri = $location->getQueryUrl($this->getMajorProtocolVersion()); } else { $uri = $location; } } return parent::getEntry($uri, 'Zend_Gdata_YouTube_UserProfileEntry'); }
/** * Retrieves a user's profile as an entry * * @param string $user (optional) The username of interest * @param mixed $location (optional) The URL to query or a * Zend_Gdata_Query object from which a URL can be determined * @return Zend_Gdata_YouTube_UserProfileEntry The user profile entry */ public function getUserProfile($user = null, $location = null) { if ($user !== null) { $uri = 'http://gdata.youtube.com/feeds/users/' . $user; } else { if ($location instanceof Zend_Gdata_Query) { $uri = $location->getQueryUrl(); } else { $uri = $location; } } return parent::getEntry($uri, 'Zend_Gdata_YouTube_UserProfileEntry'); }