Added code to retrieve posts as json.  Fixed bug in post update functionality.