Add Categories to Blogger with Google Api?

1.2k Views Asked by At

I am using the Zend Google API for posting to my blogger (Blogspot) Blog. I can enter only the Title and Content but I don't know how to add categories (also known as "Labels"). Is there a way to use the Zend Api to post to blogger with Categories?

Thanks!

1

There are 1 best solutions below

0
On BEST ANSWER

http://groups.google.com/group/bloggerdev/browse_thread/thread/84053cb152af6423/e76330903c5061f7?lnk=gst&q=category

$labels = $entry->getCategory(); 
$newLabel = $gdClient->newCategory('testlabel2', 'http://www.blogger.com/atom/ns#'); 
$labels[] = $newLabel; // Append the new label to the list of labels. 
$entry->setCategory($labels);