Closed abishekrsrikaanth closed 11 years ago
I'm confused with exactly what features the bundle for CodeIgniter has, that Laravel4 doesn't? Could you explain some more?
@carbontwelve, with a response, it supports the following output content types/formats.
xml - almost any programming language can read XML
json - useful for JavaScript and increasingly PHP apps.
csv - open with spreadsheet programs
html - a simple HTML table
php - Representation of PHP code that can be eval()'ed
serialize - Serialized data that can be unserialized in PHP
I don't see this existing on L4 with an exception for json
using Response::json
with the other 2, all i require to do is $this->response($obj);
and the client can use any of the above formats that they require.
Oh, yes that makes complete sense now.
Perfect thing for a package.
I have been a great fan of Phil Strugeon's Rest Server bundle for CodeIgniter which provides great flexibility on the formats that it supports out of the box. It would be good to have something like this when working with REST Controllers on Laravel 4. I am sure there are a many who would find this very helpful.
FuelPHP's Rest Controllers has this out-of-the-box and the above plugin does wonders on CodeIgniter.