2
I have a problem about regex and I come here to ask you for help.
I’m trying to get a file value .chr
by regex, but it does not return any match, I find it strange because I have tested in regex engines online and gave match.
$conteudo = file_get_contents($chart);
preg_match('/valorLoteIni=./', $conteudo, $matches);
var_dump($matches); exit;
In case I’m trying to get the value of valueLoteIni
As I said before, I have already tested on websites, and the result was the following:
As you can see, the regex is working.
I hope you help me, thank you and even more.
EDIT.
For those who want to test I will post the file: https://drive.google.com/file/d/1SuOd6ZvBz1xxNculHgy-eN2-coOBQW3a/view?usp=sharing
If you put a
echo $conteudo;
shows something?– Sam
shows the file contents
– Felipe Horizonte
How strange.. could test with the file?
– Felipe Horizonte
I used the same file. Chr to get the data.
– Sam
Okay, thank you so much for your return man. It helped me a lot
– Felipe Horizonte
This file . Chr is plain text, like a . txt?
– Sam
I posted the file in the post
– Felipe Horizonte
arranged the link!
– Felipe Horizonte