read2me-online/itunes-podcast-feed-php
Composer 安装命令:
composer require read2me-online/itunes-podcast-feed-php
包简介
A tiny PHP library for generating iTunes-compatible podcast feeds.
关键字:
README 文档
README
Installation
composer require read2me-online/itunes-podcast-feed-php
Usage
Put this in a file that you want to become your feed (e.g. https://mysite.com/rss/feed.php):
use iTunesPodcastFeed\Channel; use iTunesPodcastFeed\FeedGenerator; use iTunesPodcastFeed\Item; require __DIR__ . '/vendor/autoload.php'; // SETUP CHANNEL $title = 'Read2Me Daily Curated Articles'; $link = 'https://read2me.online'; $author = 'NYTimes and Medium'; $email = 'hello@read2me.online'; $image = 'https://d22fip447qchhd.cloudfront.net/api/widget/static/images/android-chrome-1400x1400.png'; $explicit = false; $categories = [ 'News', 'Technology', 'Culture', 'Entrepreneurship', 'Productivity' ]; $description = 'Daily curated articles from New York Times and Medium'; $lang = 'en'; $copyright = 'The New York Times Company and The Medium Company'; $ttl = 43200; // 12 hours in seconds $channel = new Channel( $title, $link, $author, $email, $image, $explicit, $categories, $description, $lang, $copyright, $ttl ); // SETUP EPISODE $title = "Trump Says Disclosure of Mueller Questions in Russia Probe Is ‘Disgraceful’"; $fileUrl = 'https://s3.read2me.online/audio/www-nytimes-com-2018-05-01-us-politics-trump-mueller-russia-questions-html-7e9601.mp3'; $duration = '2:18'; $description = 'WASHINGTON — President Trump on Tuesday said it was “disgraceful” that questions the special counsel would like to ask him were publicly disclosed, and he incorrectly noted that there were no questions about collusion. The president also said collusion was a “phony” crime.'; $date = 1525177808; $filesize = 828387; $mime = 'audio/mpeg'; $item = new Item( $title, $fileUrl, $duration, $description, $date, $filesize, $mime ); $item2 = clone $item; // just to give you an idea of how it works // SETUP FEED $feed = new FeedGenerator($channel, ...[$item, $item2]); // OUTPUT XML header('Content-Type: application/xml; charset=utf-8'); print $feed->getXml();
Then, go to https://podcastsconnect.apple.com/my-podcasts/new-feed and submit your feed.
Addendum
- XML syntax based off aaronsnoswell/itunes-podcast-feed
- This library is in production use at Read2Me
- Demo: https://read2me.online/rss/daily-curated-articles.php
- iTunes link for the aforementioned demo: https://itunes.apple.com/hr/podcast/read2me-daily-curated-articles/id1378984368
- Donate: https://paypal.me/skopac
read2me-online/itunes-podcast-feed-php 适用场景与选型建议
read2me-online/itunes-podcast-feed-php 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 223 次下载、GitHub Stars 达 5, 最近一次更新时间为 2018 年 05 月 01 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「itunes」 「rss」 「podcast feed」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 read2me-online/itunes-podcast-feed-php 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 read2me-online/itunes-podcast-feed-php 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 read2me-online/itunes-podcast-feed-php 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Generate RSS feed for podcast, including iTunes, RawVoice, DublinCore and syndication fields.
A library that implements the App Store API (Server API and Connect API) and facilitates App Store Server Notifications V2
PHP library to find podcasts
PHP receipt validator for Apple iTunes, Google Play and Amazon App Store
Import an RSS-feed into blog
A module for adding a podcast or multiple podcasts to your SilverStripe site. With support for audio, video or other files.
统计信息
- 总下载量: 223
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 5
- 点击次数: 5
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2018-05-01