fopen question
How do I post the data created with this code:
<?php
require('config.php');
require_once('include/functions.php');
$result = mysql_query("SELECT ProductID, ProductName FROM ura_items WHERE CategoryID != 0 AND CategoryID != 1 AND CategoryID != 2 ORDER BY Add_Date DESC")
or die(mysql_error());
// keeps getting the next row until there are no more to get
while($row = mysql_fetch_array( $result )) {
echo "".seo_links('detail', $row['ProductID'], $row['ProductName'], 1, _SEO)."<br>";
}
?>
into another text file?
I can get a single line to print to another file using the code below but I can't get the code above to run and print out a long list.
<?php
$file= fopen("sitemap.txt", "w");
$data = "testing";
fwrite($file, $data);
fclose($file);
print "data posted";
?>
"Jamroom is a Profile Centric CMS system suitable as a development framework for building entire communities. Highly modular in concept. Suitable for enterprise level development teams or solo freelancers."
The 2nd Amendment, 1789 - The Original Homeland Security.
Gun control means never having to say, "I missed you."
Are you using WordPress? Have you tried qSandbox yet?