jailtonsc / laravel-response-xml

Add the method xml integrating the laravel's response, converting eloquent return to XML.
46 stars 15 forks source link

Use with Lumen #9

Open Tommixoft opened 7 years ago

Tommixoft commented 7 years ago

Hi, im new to Laravel/Lumen and im having problem using this with Lumen. How can i register it with lumen? Stupid framework cant output xml...and it's soo popular, makes me even laugh :) Your code nice but cant figureout how to use it

zietbukuel commented 7 years ago

I think you should stick to Laravel. I mean, even the name of this package includes "laravel" in it, which means it's specifically designed for Laravel. I know this isn't the answer you want, but if you don't want to deal with more of this just stick to Laravel.

Tommixoft commented 7 years ago

but i don't want to use that giant shit when i can use only Lumen :) Anyways thanks, looks like need to create my own serializer or just format xml by 'hand' :D

ronnie-depp commented 6 years ago

@Tommixoft You will need a Lumen-Specific package which will wrap around this Laravel-Specific package. I'm thinking to try writing my own wrapper for Lumen.

BarryBotha commented 4 years ago

return response($xml)->header('Content-Type', 'application/xml'); That outputs XML.