Download the PHP package shevabam/rss-feed-maker without Composer

On this page you can find all versions of the php package shevabam/rss-feed-maker. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package rss-feed-maker

RSS Feed Maker

Create RSS feeds easily in PHP!

This library allows you to create an XML file representing an RSS feed.

Requirement

Installation

With Composer, run this command:

composer require shevabam/rss-feed-maker

Usage

First, include the library in your code using the Composer autoloader and then create a Feed object.

Next, configure the feed:

Here are the parameters that can be modified for the feed:

RSS Tag PHP method Example Default Required
title setTitle() $feed->setTitle('RSS Feed Title'); Empty Yes
description setDescription() $feed->setDescription('Recent articles on your website'); Empty Yes
lastBuildDate setLastBuildDate() $feed->setLastBuildDate(); Actual date
pubDate setPubDate() $feed->setPubDate(); Empty
link setLink() $feed->setLink('https://website.com'); Empty Yes
webMaster setWebmaster() $feed->setWebmaster('John Doe'); Empty
category setCategory() $feed->setCategory('Blog'); Empty
copyright setCopyright() $feed->setCopyright('MyWebsite.com'); Empty
language setLanguage() $feed->setLanguage('en'); en
ttl setTtl() $feed->setTtl(30); Empty
image setImage() $feed->setImage([ 'title' => 'Image title', 'url' => 'https://website.com/Image.jpg', 'link' => 'https://website.com' ]); Empty

The language code is described here: https://www.rssboard.org/rss-language-codes

Default encoding is: utf-8. You can change it with:

Then, create the items and inject them into the feed:

Parameters for item:

RSS Tag PHP method Example Default Required
title setTitle() $item->setTitle('Blog post #1'); Empty Yes
description setDescription() $item->setDescription('Post content blabla'); Empty Yes
pubDate setPubDate() $item->setPubDate(); Empty
link setLink() $item->setLink('https://website.com/post-1'); Empty Yes
author setAuthor() $item->setAuthor('John Doe'); Empty
category setCategory() $item->setCategory('Tutorials'); Empty
guid setGuid() $item->setGuid('https://website.com/...'); Empty
comments setComments() $item->setComments('https://website.com/post-1/comments'); Empty
source setSource() $item->setSource([ 'url' => 'https://wikipedia...', 'source' => 'Description', ]); Empty
enclosure setEnclosure() $item->setEnclosure([ 'url' => 'https://website.com/podcasts/example.mp3', 'length' => 12345, 'type' => 'audio/mpeg', ]); Empty

For more information about the RSS schema, please see the specifications.

Finally, generate the XML with:

You can save the RSS feed to a file:

Full example

Result:


All versions of rss-feed-maker with dependencies

PHP Build Version
Package Version
Requires php Version >=7.4.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package shevabam/rss-feed-maker contains the following files

Loading the files please wait ....