[Building Sakai] A note about POSTing data to EntityBroker
Steve Swinsburg
steve.swinsburg at gmail.com
Fri Mar 23 04:21:08 PDT 2012
That's probably one for Aaron, it may be in the JSON parsing perhaps.
Sent from my iPad
On 23/03/2012, at 9:52 PM, Matthew Buckett <matthew.buckett at oucs.ox.ac.uk> wrote:
> On 23 March 2012 00:00, Steve Swinsburg <steve.swinsburg at gmail.com> wrote:
>> Hi all,
>>
>> I've just spent a considerable amount of time battling through an issue I
>> had with POSTing data to EntityBroker, in order to create entities.
>>
>> To cut a long story short, you need to ensure the content type is being set
>> correctly otherwise you will get unexpected results like the object being
>> created but no data being populated.
>>
>> In the case of JSON, it must be:
>> application/json; charset=utf-8
>
> Is there a reason why from a design point of view it should fail with:
> Content-Type: application/x-www-form-urlencoded ?
>
> To me this sounds like a bug in entity broker that should either
> support additional content type or throw a nice error saying you need
> to switch to a different content-type.
>
> --
> Matthew Buckett
> VLE Developer, LTG, Oxford University Computing Services
More information about the sakai-dev
mailing list