<?php
$plik = 'tekst.txt';
$txt = file_get_contents($plik);
$znaleziono = array();
$ile = preg_match_all('/([0-9a-zA-Z_.-]+)@([0-9a-zA-Z_.-]+)/', $txt, $znaleziono); 
print_r($znaleziono);


?>
<html>
<head>

</head>
<body>
<ul>
<?php foreach($znaleziono[0] as $z): ?>
<li><?= $z ?></li>
<?php endforeach; ?>
</ul>

</body>
</html>
