<?php
set_include_path(get_include_path() . PATH_SEPARATOR . __DIR__ . '/../src/');
-$fullUri = $_SERVER['REQUEST_URI'];
-if (isset($_SERVER['REDIRECT_URL'])) {
- $path = $_SERVER['REDIRECT_URL'];
-} else {
- $path = '/';
+$path = $fullUri = urldecode($_SERVER['REQUEST_URI']);//with query string
+$qPos = strpos($fullUri, '?');
+if ($qPos !== false) {
+ $path = substr($fullUri, 0, $qPos);
}
$dataDir = __DIR__ . '/../data/';
$varDir = realpath(__DIR__ . '/../var') . '/';
}
$xml .= "</ListOfItems>\n";
- header('Content-type: text/xml');
+ header('Content-type: text/xml; charset=iso-8859-1');
echo $xml;
}
?>