我的提要是用PHP和MYSQL制作的,然后是feedburner。
我的问题是 dlvr.it 每次发布时都无法读取新条目。
这是我的PHP代码:
<?php
include('db.php');
header('Content-Type: text/xml');
echo '<?xml version="1.0" encoding="ISO-8859-1"?>
<rss version="2.0">
<channel>
<title>MindWeather Thesis</title>
<description>Latest News from my website</description>
<link>http://www.mindweather.info</link>';
$get_articles = "SELECT Fore_ID, Valid, Synopsis,
DATE_FORMAT(Issued,'%a, %e %b %Y %T') as formatted_date
FROM tblforecast ORDER BY Issued DESC LIMIT 15";
$articles = mysql_query($get_articles) or die(mysql_error());
while ($article = mysql_fetch_array($articles)){
echo '
<item>
<title>'.$article['Valid'].'-hour Forecast</title>
<description><![CDATA['.$article['Synopsis'].']]> </description>
<link>http://mindweather.info/fforecast.php?fore='.$article['Fore_ID'].'</link>
<pubDate>'.$article['formatted_date'].' GMT</pubDate>
</item>';
}
echo '</channel>
</rss>';
?>
进料燃烧器进料位于:http://www.mindweather.info/feedz2.php
您的答案将有很大帮助。谢谢!
检测源中新条目的机制是使用其唯一<guid>
来识别它们。由于您的 Feed 缺少该元素,因此此服务无法检测到新条目是完全正常的。
添加类似以下内容很简单:<guid><?php echo $article['Fore_ID']; ?></guid>
,当然假设Fore_ID
是唯一的。将它们添加到<item>
和</item>
之间
您还应该确保每个<link>
元素都是唯一的,因为这是源读取器尝试检测新/唯一条目的另一种方式,当他们使用该<guid>
元素无法做到这一点时。