PHPackages                             rudak/rss-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. rudak/rss-bundle

ActiveSymfony-bundle

rudak/rss-bundle
================

Modern Symfony RSS Bundle for PHP 8.2+

150PHPCI failing

Since Dec 9Pushed 5mo ago1 watchersCompare

[ Source](https://github.com/rudak/RssBundle)[ Packagist](https://packagist.org/packages/rudak/rss-bundle)[ RSS](/packages/rudak-rss-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (2)Used By (0)

RssBundle
=========

[](#rssbundle)

Modern Symfony RSS Bundle for PHP 8.2+ and Symfony 6.4+/7.0+

[![CI](https://github.com/rudak/RssBundle/workflows/CI/badge.svg)](https://github.com/rudak/RssBundle/actions)

This bundle generates RSS feeds dynamically for your Symfony application.

Requirements
------------

[](#requirements)

- PHP 8.2 or higher
- Symfony 6.4+ or 7.0+

Installation
------------

[](#installation)

Install the bundle via Composer:

```
composer require rudak/rss-bundle
```

If you're not using Symfony Flex, register the bundle manually in `config/bundles.php`:

```
return [
    // ...
    Rudak\RssBundle\RudakRssBundle::class => ['all' => true],
];
```

Configuration
-------------

[](#configuration)

Configure the bundle in `config/packages/rudak_rss.yaml`:

```
rudak_rss:
    rssparameters:
        entity:
            repository: 'App\Entity\Article'
            methodName: 'findLatestArticles'

        channel:
            title: 'My Blog RSS Feed'
            link: 'https://example.com'
            description: 'Latest articles from my blog'
            language: 'en'
            copyright: 'contact@example.com'
            webmaster: 'webmaster@example.com'
            managingEditor: 'editor@example.com'
            generator: 'Symfony RSS Bundle'
            ttl: '3600'
            pubDate:
                type: 'datetime'
            lastBuildDate:
                type: 'datetime'
            image:
                type: 'image'
                url: 'https://example.com/logo.png'
                title: 'My Blog'
                link: 'https://example.com'

        items:
            route: 'article_show'
            params:
                id: 'id'
                slug:
                    type: 'slug'
                    index: 'title'

        associations:
            title: 'title'
            description: 'description'
            guid: 'id'
            pubDate:
                type: 'datetime'
                index: 'createdAt'
```

Usage
-----

[](#usage)

### Basic Usage

[](#basic-usage)

Inject the RSS generator service in your controller:

```
