Hi, I'm trying to rename an existing spreadsheet via the Zend Gdata
library. I'm relatively
new to the docs api... Here's what I'm attempting:
$spreadsheetService = new Zend_Gdata_Spreadsheets($client);
$feed = $spreadsheetService->getSpreadsheetFeed();
foreach($feed as $feeditem)
{
if(stripos($feeditem->title->getText(), 'ts') !== false)
{
$newTitle = str_ireplace('TS', 'TxS', $feeditem-
>getTitle());
$feeditem->setTitle($newTitle);
$feeditem->save();
}
}
My script successfully loops through the docs and parses them, but I
want to mark the docs that have been processed by the script by
renaming them, and that's where the problem occurs.
When I run the code above, I get the following error:
Fatal error: Call to a member function getDOM() on a non-object in /
var/local/www/pm/lib/Zend/Gdata/App/FeedEntryParent.php on line 239
The fatal error is inside the Zend framework, but I doubt it's a bug
in
the Zend framework. More likely culprit is my call of $feeditem->save
(). The problem goes away when I comment out the save function
call.
But I don't know what I'm doing wrong. Any one have any
thoughts?
Thanks,
Lohms
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Docs Data APIs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Docs-Data-APIs?hl=en
-~----------~----~----~----~------~----~------~--~---