i've created an rss feed in php using the below code. i've double checked all the variables (i.e. username and password) and they are correct. mysql is set up correctly as well. i'm just getting a blank page when i try to view this locally on my computer using mamp. any help would be appreciated.. does this code look correct, and is there something else i should be using to view this other than mamp?
<? header('Content-type: text/xml'); ?>
<?php
$dbhost = "localhost"; // almost always localhost.
$dbname = "links"; // Database Name
$dbuser = "root"; // Database Username
$dbpass = "password"; // Databse Password
$connect = mysql_connect("$dbhost","$dbuser","$dbpass");// Connecting to Database
mysql_select_db($dbname) or die (mysql_error()); // Selecting Database
?>
<rss version="2.0">
<channel>
<title> </title>
<description> </description>
<link></link>
<?
$sql = "SELECT * FROM news limit 5";
$result = mysql_query($sql);
while($row = mysql_fetch_assoc($result)){
?>
<item>
<title><?=$row['title']; ?></title>
<author><?=$row['author']; ?></author>
<link>http://MYSITE.com/news.php?id=<?=$row['id']; ?></link>
</item>
<?
}
?>
</channel>
</rss>