2017 © Pedro Peláez
 

library laravel-xml-response

Added a method to Laravel response for handling xml response and also converting Eloquent return to XML.

image

tartan/laravel-xml-response

Added a method to Laravel response for handling xml response and also converting Eloquent return to XML.

  • Wednesday, June 20, 2018
  • by tartan
  • Repository
  • 1 Watchers
  • 1 Stars
  • 0 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Laravel XML Response

Added a method to Laravel response for handling xml response and also converting Eloquent return to XML., (*1)

Composer Installation

composer require php-monsters/laravel-xml-response 

Integration with Laravel 5.0+

for Laravel < 5.6 add to config/app.php, (*2)

PhpMonsters\XmlResponse\XmlResponseServiceProvider::class

Publish

php artisan vendor:publish --provider="PhpMonsters\XmlResponse\XmlResponseServiceProvider"

Example

// basic usage with default config from xml.php file
Route::get('/', function () {
    return response()->xml(User::all());
});


// custom template like: '<result></result>'
Route::get('/foo', function () {
    return response()->xml(['foo' => 1, 'bar' => 2, 'baz' => 3], [], '<result></result>);
});

Team

This component is developed by the following person(s) and a bunch of awesome contributors., (*3)

Aboozar Ghaffari
Aboozar Ghaffari

License

The Laravel XML Response is open-sourced software licensed under the MIT license, (*4)

The Versions

20/06 2018

dev-master

9999999-dev

Added a method to Laravel response for handling xml response and also converting Eloquent return to XML.

  Sources   Download

MIT

The Requires

 

laravel xml eloquent response