Location: PHPKode > scripts > GG-Tracker GPS and GSM Tracking > gg-tracker-gps-and-gsm-tracking/rsscreate.php
<?php 

/* This extension writes the newly received location to a RSS. This file
   can be used for a syndication or data exchange purposes.  
*/

/* Test values */
//$lat = 51.9159;
//$lon = 4.32317;
//$speed = 0;
//$rssfile = "ggtrack_rss.xml";

//Check if a position was found
if (($status <> "Z") && ($status <> "F")) {
  //Open XML file for writing
  $handle = fopen($rssfile, 'w') or die("Can't create RSS file: ".$rssfile);
	
  //Create the content
  $bestand = "<?xml version=\"1.0\" encoding=\"utf-8\"?>
<rss version=\"2.0\">
  <channel>
    <title>GPS and GSM Tracking</title>
    <description>Live tracking without GPS</description>
    <link>http://tracker.eppenga.com/</link>
    <item>
      <title>Latitude: $lat</title>
      <link>http://tracker.eppenga.com/</link>
    </item>
    <item>
      <title>Longitude: $lon</title>
      <link>http://tracker.eppenga.com/</link>
    </item>
    <item>
      <title>Speed: $speed km/h</title>
      <link>http://tracker.eppenga.com/</link>
    </item>
  </channel>
</rss>
";

	//Write the file and close
	fwrite($handle, $bestand);
	fclose($handle);	
}	

?>
Return current item: GG-Tracker GPS and GSM Tracking