viktoras/rss-reader

A library to parse RSS feed

v1.0.0 2022-06-17 09:14 UTC

This package is auto-updated.

Last update: 2025-03-17 16:15:15 UTC


README

PHP library to read RSS files.

Installation

composer require viktoras/rss-reader

Example

$reader = new Reader(file_get_contents('https://packagist.org/feeds/packages.rss'));

echo $reader->getChannel()->getTitle() . PHP_EOL;

foreach ($reader->getItems() as $item) {
    echo ' - ' . $item->getTitle() . PHP_EOL;
}

Development

  • composer fmt - Code formatting
  • composer psalm - Static check
  • composer test - Tests

License

MIT