<?php
extrairDadosNotificacao("arquivo1.txt");
extrairDadosNotificacao("arquivo2.txt");
function extrairDadosNotificacao($NomeArquivo){
$arquivo = fopen($NomeArquivo, 'r');
while(!feof($arquivo)) {
$linha = fgets($arquivo);
echo $linha . "<br>";
}
}
A file returns exactly what I expect, which would read each line of the file, but the other would not (see image).
Ibelievethatinthesecondfileitisnotidentifyinglinebreakssinceonlyonelineisreturnedwithalldata.ThesefilesareissuedbySPCBRAZILiethereisnopossibilitytochangethedefault.
Doesanyonehaveanyideahowtogetittoreadthesecondfilecorrectly?Q.:Ihavepreparedanexampletoquicklytestwithsamplefiles: here