<?php
header("Content-Type: text/xml");

// dynamically generate and output your xml here
?> 
<?php include ('../database1.php'); ?>

<?php



echo '

       <rss version="2.0">

<channel>

	<title>' . $name .'</title>

	<link>' . $url . '</link>

	<description>' . $tagline .'</description>

	<lastBuildDate>'. date("D, d M Y H:i:s +0000") .'</lastBuildDate>

	<language>en</language>

	<copyright>Copyright ' . $name .'</copyright>

	<ttl>1</ttl>

	<image>

		<url>' . $url . '/test7.png</url>

		<title>' . $name .'</title>

		<link>' . $url . '</link>

		<description>' . $tagline .'</description>



	</image>';?>

<?php

mysql_select_db($database_htshop);

$result = mysql_query("SELECT id,title,content FROM guides");

while($r = mysql_fetch_array($result))

{ 

   $id=$r["id"];

   $title=$r["title"];

   $content=$r["content"];

   $email="ece60217@port.ac.uk";



echo '

<item>

<link>' . $site .'post.php?id=' . $id . '</link>

<guid>' . $site .'post.php?id=' . $id . '</guid>

<title>' . $title . '</title>

<author>'. $email . '</author>

<description><![CDATA[' . $content . ']]></description>

</item>'; 



 }

?>

</channel>

</rss>
