oder meinst du das:
Da ich immer wieder Darstellungsprobleme mit dem Code hatte, der Code dann jetzt immer als .txt Datei zum Dowload.
gruß richy
Da ich immer wieder Darstellungsprobleme mit dem Code hatte, der Code dann jetzt immer als .txt Datei zum Dowload.
rssCopyright=Autornamefunction generateRss() {
global $REX;
global $art_table;
global $myIniFile;
$settings = parse_ini_file($myIniFile);
if ($settings['rssGenerate'] == 1) {
$filename = $REX['MEDIAFOLDER'] . '/tvsblog.xml';
$file = @fopen($filename, "w-", $use_include_path);
if ($file)
{
$actDate = date("D, j M Y H:i:s O");
$output = "<?xml version=\"1.0\" encoding=\"utf-8\"?>\n";
$output .= "<rss version=\"2.0\">\n";
$output .= " <channel>\n";
$output .= " <title>" . $settings['rssTitle'] . "</title>\n";
$output .= " <link>" . $settings['rssLink'] . "</link>\n";
$output .= " <description>" . $settings['rssDescription'] . "</description>\n";
$output .= " <language>" . $settings['rssLanguage'] . "</language>\n";
$output .= " <copyright>" .$settings['rssCopyright']."</copyright>\n";
$output .= " <pubDate>" . $actDate . "</pubDate>\n";
$sql = new rex_sql();
$sql->setQuery("SELECT * FROM " . $art_table . " ORDER BY id DESC");
if ($sql->getRows() > 0 )
{
for ($i = 1; $i <= $sql->getRows(); $i++) {
$datum = date("D, j M Y H:i:s O",$sql->getValue('create_date'));
$output .= " <item>\n";
$output .= " <title>" . $sql->getValue('title') . "</title>\n";
$output .= " <description><![CDATA[" . $sql->getValue('description') . "]]></description>\n";
$output .= " <link>" . $settings['rssLink'] . "/index.php?article_id=" . $settings['blogArticle_id'] . "&post_id=" . $sql->getValue('id') . "</link>\n";
$output .= " <author>" .$sql->getValue('create_user'). "</author>\n";
$output .= " <guid>" .$sql->getValue('id'). "</guid>\n";
$output .= " <pubDate>" . $datum . "</pubDate>\n";
$output .= " </item>\n";
$sql->next();
}
}
$output .= " </channel>\n</rss>\n";
fwrite($file, $output);
fclose($file);
}
}
}echo " <h2><a href='" . rex_getUrl('','', array('post_id'=>$sql->getValue('id')), '&') . "'>" . $sql->getValue('title') . "</a></h2>";echo " <h2><a href='" . rex_getUrl('','', array('tvsblog_category'=>$sql->getValue('categories'),'post_id'=>$sql->getValue('id')), '&') . "'>" . $sql->getValue('title') . "</a></h2>";if ($tvsblog_post_id != "") {
echo " <div id=\"fb-root\"></div>
<script src=\"http://connect.facebook.net/en_US/all.js#appId=YOUR_APP_ID&xfbml=1\"></script><fb:comments xid=\"YOUR_APP_ID\" width=\"410\"></fb:comments>";
}Mitglieder in diesem Forum: 0 Mitglieder und 3 Gäste