Index: trunk/src/index.php
===================================================================
--- trunk/src/index.php	(revision 7728)
+++ trunk/src/index.php	(revision 7750)
@@ -11,38 +11,7 @@
 // Make it parse properly within Firefox so that it will display a DOM tree
 header('Content-Type: text/xml');
-
-// And echo the result to the screen
-// TODO: Need to fix this wierd error... Or is it just USBWebserver? Line is invisible!
 echo '<?xml version="1.0" encoding="UTF-8"?>';
 
-// Creating a placemark using our class
-$kmlPlacemark1 = new KMLPlacemark();
-$kmlPlacemark1->setName('Test name');
-$kmlPlacemark1->setDescriptionLocation('Test location description');
-$kmlPlacemark1->setDescriptionStatus('Test status description');
-$kmlPlacemark1->setLatitude(52.138476);
-$kmlPlacemark1->setLongitude(4.463046);
-$kmlPlacemark1->setStyle(PLACEMARK_GREEN);
-
-// Creating a second placemark using our class
-$kmlPlacemark2 = new KMLPlacemark();
-$kmlPlacemark2->setName('Placemark 2 name');
-$kmlPlacemark2->setDescriptionLocation('This is the second placemark location description');
-$kmlPlacemark2->setDescriptionStatus('This is the second placemark status description');
-$kmlPlacemark2->setLatitude(52.638476);
-$kmlPlacemark2->setLongitude(4.063046);
-$kmlPlacemark2->setStyle(PLACEMARK_ORANGE);
-
-// Creating a KMLFile using our class, add our placemarks and echo
-$kml = new KMLFile();
-$kml->addPlacemark($kmlPlacemark1);
-$kml->addPlacemark($kmlPlacemark2);
-/*
- * For testing, echo the example KML file
- * echo $kml->toString();
- * echo "\r\n\r\n\r\n\r\n\r\n -------------------------------------------------- \r\n\r\n\r\n\r\n\r\n";
- */
-
-// Now let's try reading from files and parsing the data in the files.
+// Let's try reading from files and parsing the data in the files.
 // First off, we create a new KMLFile object
 $kmlFile = new KMLFile();
@@ -51,9 +20,4 @@
 $nodeLocation = new FileHandler($config['node_location_file'], 'r');
 $kmlFile->parseLocationFile($nodeLocation->read());
-/*
- * For testing, echo the example KML file
- * echo $kmlFile->toString();
- * echo "\r\n\r\n\r\n\r\n\r\n -------------------------------------------------- \r\n\r\n\r\n\r\n\r\n";
- */
 
 // Let's try to read the node status file
@@ -61,4 +25,9 @@
 $kmlFile->parseStatusFile($nodeStatus->read());
 
+if ($_GET['write'] == true) {
+	// TODO: David: Write the KML file to a folder with date stamp
+}
+
+// And echo the result to the screen
 echo $kmlFile->toString();
 ?>
