Sunday, February 06, 2011

Output XML with PHP

Something to get you started with php and xml. Complete with get request and xml header:


<?php
header('Content-Type: text/xml');
echo '<?xml version="1.0" encoding="UTF-8" standalone="yes"?>';
?>
<?php
$getrequestparam1 = $_GET["getrequestparam1"];

echo "\n<result>No Results Found for $getrequestparam1</result>";
?>

No comments:

Post a Comment