<?php  header ("Content-Type: application/xml");?>
<rss version="2.0">

<channel>

<title>Property for Sale France - Articles on PFS France </title>
<description>Articles on buying french property and real estate. Property for Sale France advertise some of the finest and best cared for traditional french properties available. These articles may help you find and buy your dream home in France.</description>
<link>http://www.propertyforsalefrance.co.uk/</link>
<copyright>Copyright PFS France and eantics Ltd. May be reproduced 'as is' for private and commercial use.</copyright>

<?php

// Articles on PFS France
include("../dbconnection.php");
$sql="select * from guides where guideType='article' and guideMember='n' and guidePublish='y' order by guideUpdate DESC limit 30;";
$query=mysql_query($sql);

?>

<?

while($item=mysql_fetch_array($query))
 {
  $id=$item['guideID'];
  $title=ucwords(strtolower($item['guideTitle']));
  $title = str_replace("'","",$title);
  $title=htmlentities($title,ENT_QUOTES);
  $title = str_replace("&eacute;","e",$title);
  $title = str_replace("&ccedil;","c",$title);
  $title = str_replace("&sup2;","2",$title);
  $title = str_replace("&ocirc;","o",$title);
  $title = str_replace("&pound;","%A3",$title);
  $title = str_replace("€","EURO",$title);
  $title = str_replace("-"," ",$title);
  

  $body=$item['guideDescription'];
  $body=substr($body,0,300);
  $body=htmlentities($body,ENT_QUOTES);
  
  //replace non xml compatible chars
  $body = str_replace("&eacute;","e",$body);
  $body = str_replace("&ccedil;","c",$body);
  $body = str_replace("&sup2;","2",$body);
  $body= str_replace("&ocirc;","o",$body);
  $body=str_replace("&plusmn;","plus or minus",$body);
  $body= str_replace("&pound;","%A3",$body);
  $body= str_replace("€","EURO",$body);
  $body= str_replace("-"," ",$body);
  
  
  
// output to client
	
?>

  <item>
  <title><?php echo htmlentities($title,ENT_QUOTES);?></title>
  <description><?php echo $body."...";?></description>
  <link>http://www.propertyforsalefrance.co.uk/index.php?action=guides&amp;action2=showguide&amp;id=<?php echo $id;?></link> 
  </item>
<?php  
 } 
?>

</channel>
</rss>