PHPからRSSを手軽に作成するライブラリ: RSSWriter
2006年02月06日-
RSSWriter is a convenience class for generating RSS 1.0 feeds with PHP.
RSSWriterを使えば、RSSの詳しいフォーマットについて知らなくても、手軽にRSS1.0 feedを作成することが出来ます。
クラスの形式でライブラリ化されているので、自作のツールに組み込むのも容易です。
サンプルは次のような感じ。
<?php
include("rss10.inc");
$rss=new RSSWriter("http://www.example.org/",
"Example Site",
"The best examples out there.",
array(
"dc:publisher" => "Example Publishing Inc.",
"dc:creator" => "E X Ample <me@example.org>"
)
);
$rss->setImage("http://www.example.org/images/rss.gif", "Example Site: All the Examples Fit to Print");
$rss->addItem("http://www.example.org/page1.html", "First Example Page");
$rss->addItem("http://www.example.org/page2.html", "Second Example Page",
array(
"description" => "This is the second page of examples on this wonderful site",
"dc:subject" => "examples",
"dc:creator" => "Fred <fred@example.org>"
)
);
$rss->serialize();
?>
最新のブログ記事(新着順)
- 2000種類以上の汎用ピクトグラムアイコン集「Atlas Icons」
- かわいい手書き風フォント「うさぎとまんげつのサンセリフ」
- ランディングページのサンプル集「Landings」
- WEBのUIコンポーネントギャラリー「The Component Gallery」
- 汎用で使える700+のピクトグラムアイコン「Sargam Icons」
- 白黒写真をWEB上で簡単にカラーにできる「Palette」
- iPhone14Proのモックアップ
- 建築素材風のおしゃれな背景画像「Architextures」
- クールな今どきのギャラリーサイトを作れるサンプル
- SVG形式の背景パターンなどをWEBで生成できる「fffuel」
- 過去のエントリ