views:

6

answers:

0

I am trying to update a Google sites WebPageEntry but my change does not get persisted and I do not receive any exceptions.

Here is my code:

WebPageEntry entry = mService.getEntry(new URL(getContentFeedUrl() + entryId), WebPageEntry.class);
string pageContent = getContentBlob(entry);
pageContent = pageContent + appendText;
XmlBlob xml = new XmlBlob();
xml.setBlob(pageContent);
entry.setContent(new XhtmlTextConstruct(xml));
entry.update();

What am I missing?

Secondarily I wonder if how I retrieve the WebPageEntry is part of the problem. I see two ways - The one above and the other by using ContentFeed contentFeed = mService.getFeed(...);

Is there a difference?