/ Published in: PHP

Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
if ($num != 0) { $file= fopen("results.xml", "w"); $_xml ="<?xml version=\"1.0\" encoding=\"UTF-8\" ?> "; $_xml .="<site> "; if ($row["pageTitle"]) { $_xml .="\t<page title=\"" . $row["pageTitle"] . "\"> "; $_xml .="\t\t<file>" . $row["pageLink"] . "</file> "; $_xml .="\t</page> "; } else { $_xml .="\t<page title=\"Nothing Returned\"> "; $_xml .="\t\t<file>none</file> "; $_xml .="\t</page> "; } } $_xml .="</site>"; echo "XML has been written. <a href=\"results.xml\">View the XML.</a>"; } else { echo "No Records found"; } ?>
URL: http://builder.com.com/5110-6388-5055276.html
Comments
