"; $xmlfile1 = "testsitemap-" . $smap[$i]['id'] . "-page1.php"; $xmlfile2 = "testsitemap-" . $smap[$i]['id'] . "-page2.php"; $xmlfile3 = "testsitemap-" . $smap[$i]['id'] . "-page3.php"; $fh1 = fopen($xmlfile1, 'w') or die("can't open"); $fh2 = fopen($xmlfile2, 'w') or die("can't open"); $fh2 = fopen($xmlfile3, 'w') or die("can't open"); for ($f = 0; $f < count($smap[$i]['general']); $f++) { // general links Echo "Text:".$smap[$i]['general'][$f][0]." Link:".$smap[$i]['general'][$f][1]."
"; $stringData = "" . $smap[$i]['general'][$f][0] ."
"; $count++; if ($count == 100) { echo "
Hit 100
"; fwrite($fh1, $stringData); } } fclose($fh1); // echo count($smap[$i]['general']); for ($g = 0; $g < count($smap[$i]['locations']); $g++) { // location Echo "Location:".$smap[$i]['locations'][$g]."
"; for ($s = 0; $s < count($smap[$i]['location_links'][$smap[$i]['locations'][$g]]); $s++) { // location links Echo "Text:".$smap[$i]['location_links'][$smap[$i]['locations'][$g]][$s][0]." Link:".$smap[$i]['location_links'][$smap[$i]['locations'][$g]][$s][1]."
"; $stringData = "" . $smap[$i]['location_links'][$smap[$i]['locations'][$g]][$s][0] ."
"; // fwrite($fh, $stringData); $count++; // while ($count <= 150) { // echo $count; // } if ($count == 300) { echo "
Hit 300
"; } } } } echo $count; ?>