You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on May 16, 2018. It is now read-only.
I have created a code to post photo to picasa web album .
But getting error like show below
Fatal error: Uncaught exception 'Zend_Http_Header_Exception_InvalidArgumentException' with message 'Invalid header value' in C:\xampp\htdocs\masterZend\library\Zend\Http\Header\HeaderValue.php:124 Stack trace: #0 C:\xampp\htdocs\masterZend\library\Zend\Http\Client.php(1605): Zend_Http_Header_HeaderValue::assertValid('multipart/relat...') #1 C:\xampp\htdocs\masterZend\library\Zend\Http\Client.php(467): Zend_Http_Client->_validateHeaderValue('multipart/relat...') #2 C:\xampp\htdocs\masterZend\library\Zend\Http\Client.php(439): Zend_Http_Client->setHeaders('Content-Type', 'multipart/relat...') #3 C:\xampp\htdocs\masterZend\library\Zend\Gdata\App.php(650): Zend_Http_Client->setHeaders(Array) #4 C:\xampp\htdocs\masterZend\library\Zend\Gdata.php(219): Zend_Gdata_App->performHttpRequest('POST', 'https://picasaw...', Array, Object(Zend_Gdata_MediaMimeStream), 'multipart/relat...', NULL) #5 C:\xampp\htdocs\masterZend\library\Zend\Gdata\App.php(908): Zend_Gdata->performHttpRequest('POST', 'https://picasaw...', Array, Object(Zend_Gd in C:\xampp\htdocs\masterZend\library\Zend\Http\Header\HeaderValue.php on line 124
Here is the code
$userName = "default";
$fileName = "Desert.jpeg";
$photoName = "My Test Photo";
$photoCaption = "The first photo I uploaded to Picasa Web Albums via PHP.";
$photoTags = "beach, sunshine";
// We use the albumId of 'default' to indicate that we'd like to upload
// this photo into the 'drop box'. This drop box album is automatically
// created if it does not already exist.
$albumId = "default";
$fileDetails = $googleWebPicasaClient->newMediaFileSource($fileName);
$fileDetails->setContentType("image/jpeg");
// Create a PhotoEntry
$photoEntry = $googleWebPicasaClient->newPhotoEntry();
$photoEntry->setMediaSource($fileDetails);
$photoEntry->setTitle($googleWebPicasaClient->newTitle($photoName));
$photoEntry->setSummary($googleWebPicasaClient->newSummary($photoCaption));
// add some tags
$imageKeywords = new Zend_Gdata_Media_Extension_MediaKeywords();
$imageKeywords->setText($photoTags);
$photoEntry->mediaGroup = new Zend_Gdata_Media_Extension_MediaGroup();
$photoEntry->mediaGroup->keywords = $imageKeywords;
// We use the AlbumQuery class to generate the URL for the album
$albumQuery = $googleWebPicasaClient->newAlbumQuery();
$albumQuery->setUser($userName);
$albumQuery->setAlbumId($albumId);
// We insert the photo, and the server returns the entry representing
// that photo after it is uploaded
$insertedEntry = $googleWebPicasaClient->insertPhotoEntry($photoEntry, $albumQuery->getQueryUrl());
Please guide me on this.. i search for issue on net .. but not getting proper solution
The text was updated successfully, but these errors were encountered:
I have created a code to post photo to picasa web album .
But getting error like show below
Fatal error: Uncaught exception 'Zend_Http_Header_Exception_InvalidArgumentException' with message 'Invalid header value' in C:\xampp\htdocs\masterZend\library\Zend\Http\Header\HeaderValue.php:124 Stack trace: #0 C:\xampp\htdocs\masterZend\library\Zend\Http\Client.php(1605): Zend_Http_Header_HeaderValue::assertValid('multipart/relat...') #1 C:\xampp\htdocs\masterZend\library\Zend\Http\Client.php(467): Zend_Http_Client->_validateHeaderValue('multipart/relat...') #2 C:\xampp\htdocs\masterZend\library\Zend\Http\Client.php(439): Zend_Http_Client->setHeaders('Content-Type', 'multipart/relat...') #3 C:\xampp\htdocs\masterZend\library\Zend\Gdata\App.php(650): Zend_Http_Client->setHeaders(Array) #4 C:\xampp\htdocs\masterZend\library\Zend\Gdata.php(219): Zend_Gdata_App->performHttpRequest('POST', 'https://picasaw...', Array, Object(Zend_Gdata_MediaMimeStream), 'multipart/relat...', NULL) #5 C:\xampp\htdocs\masterZend\library\Zend\Gdata\App.php(908): Zend_Gdata->performHttpRequest('POST', 'https://picasaw...', Array, Object(Zend_Gd in C:\xampp\htdocs\masterZend\library\Zend\Http\Header\HeaderValue.php on line 124
Here is the code
Please guide me on this.. i search for issue on net .. but not getting proper solution
The text was updated successfully, but these errors were encountered: