Discover some solutions in C or other languages but at no use at php.
I need to replace all numbers in a (large) json file to avoid numbers will be seen as string when used in javascript.
for example:
[["Alt","128","36.00","36.00","test" .....]]
What I want:
[["Alt",128,36.00,36.00,"test" .....]]
Have tried several things but I'm not a preg expert, something like this doesn't work:
$sOutput = preg_replace('/^(\'[0-9]\'|"([0-9])")$/', '$2$3', $sOutput );
die( $sOutput );
How can I achieve my goal?