I need to access an array which is outputted by Perl's Data::Dumper.
Array is in a raw file, and I need to access it with php.
Array is formatted as this:
$stats = {
'days' => 25,
'lengths' => {
'Piwee' => 269,
'Jeanne-' => 904,
'kaAnar' => 340,
[... Very Big ARRAY....]
I found this solution on here, but I don't want to use eval() because this array will have user-input data.
Since I will always need to eval() output in case of a str_replace solution, I think I need to find another way to do it.
Maybe convert to XML or by direct PHP parsing?
I'm not sure about what would be the best solution here.
A perl / PHP / bash solution would be okay
note 1: I can't edit the Perl code that output this raw file
note 2: I don't code in Perl so I don't know how to work with such data