necatikartal / symfony-rest-api

This is a REST API build with the use of Symfony Framework and Doctrine ORM.
1 stars 0 forks source link

jms serializer and fos rest configuration bugs #4

Open necatikartal opened 10 years ago

necatikartal commented 10 years ago

I tried to add to jms serializer to encode Doctrine entities to given _format such as json , xml or html with fosrestcontroller but there's something absolutely wrong and I still couldn't figure out :tired_face:

there was some other ways which i tried such as convert Doctrine entities to string -> json_encode or something like that -> return with in response or twig views to render but there are not giving multiple _format choice to get them.

Could you find out what's wrong there, please? @hasantayyar

hasantayyar commented 10 years ago

Your fos-rest and jms-serializer versions seems old. Please check and update them. Later create a new ApiBundle from scratch following this guide http://npmasters.com/2012/11/25/Symfony2-Rest-FOSRestBundle.html