<?php
$search_engines = array(
'blogsearch.com' => 'http://blogsearch.google.com/ping?url=',
);
$search_engine_responses = array(
'blogsearch.com' => 'Thanks',
);
$sitemaps = array(
'Site 1' => 'http://gggg.com/url3',
'Site 2' => 'http://gggg.com/url3',
'Site 3' => 'http://gggg.com/url3'
);
foreach($search_engines as $engine_name => $engine_url){
echo "<p><b>$engine_name</b>";
foreach($sitemaps as $site_name => $site_map){
$response = file_get_contents($engine_url.$site_map);
echo "<br>";
if(substr_count($response, $search_engine_responses[$engine_name])){
echo $site_name.": <span style='color: green;'>Success</span>";
}
else{
echo $site_name.": <span style='color: red;'>Failure</span>";
}
}
echo "</p>";
}
?>
Есть список
$sitemaps в txt file
Как сделать чтобы они брались из файла по очереди?