本文整理汇总了PHP中RSS::GetFeed方法的典型用法代码示例。如果您正苦于以下问题:PHP RSS::GetFeed方法的具体用法?PHP RSS::GetFeed怎么用?PHP RSS::GetFeed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RSS
的用法示例。
在下文中一共展示了RSS::GetFeed方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: escapeinteger
<?php
//header("Content-Type: application/xml; charset=ISO-8859-1");
include_once "addlogic.inc.php";
include_once "lifestylelinking/rsscode/classes/RSS.class.php";
$lifestylelid = escapeinteger($_GET['lifestyleid']);
//echo $lifestylelid;
//$lifestylesubid = escapeinteger($_GET['lifestylesubid']);
//echo $lifestylesubid;
$rss = new RSS();
echo $rss->GetFeed($lifestylelid);
示例2: RSS
<?php
header("Content-Type: application/xml; charset=ISO-8859-1");
include "classes/RSS.class.php";
$rss = new RSS();
echo $rss->GetFeed();
示例3: getItems
<description>' . $row['description'] . '</description>
<language>' . $row['language'] . '</language>
<pubDate>' . date(DATE_RSS) . '</pubDate>';
}
return $channel;
}
private function getItems($conn)
{
$itemsTable = "rssItems";
$query = "SELECT * FROM " . $itemsTable . " ORDER BY `id` DESC LIMIT 31";
$result = $conn->prepare($query);
$result->execute();
$items = '';
foreach ($result as $row) {
$items .= '<item>
<title>' . $row["title"] . '</title>
<link>' . $row["link"] . '</link>
<description><![CDATA[' . $row["description"] . ']]></description>
</item>';
}
$items .= '</channel>
</rss>';
return $items;
}
}
header("Content-Type: application/xml; charset=ISO-8859-1");
require_once 'includes/pdoconn.php';
$rss = new RSS();
echo $rss->GetFeed($pdoconn);
?>