<? $f = file_get_contents('index.html'); //index.html <-- урл текстовика $f = preg_replace("/Values:\r\n(.+)\r\n(.+)/i","\\1 ::: \\2\r\n",$f); $f = preg_match_all('/(.+) ::: (.+)\r\n/i',$f,$matches,PREG_SET_ORDER); foreach($matches as $row) { $f = fopen('skype.txt', 'ab'); fwrite($f, $row[0]); fclose($f); echo str_replace("\n",'<br>',$row[0]); } ?>