I have a .json file exported with phpAdmin tool. My problem is that json is invalid.... I ask me how is possible that Phpadmin exports a Json file that is not correct? Comments in my file are the biggest problem. Please help me because when I attach this .json they tell me that this json is Invalid. And Firebase can't use this.
It seems you can't ignore the comment generation in JSON format, if you have access to the phpMyAdmin source code on your server you can remove the comment generation yourself pretty easily in the file
phpMyAdmin/libraries/plugins/export/ExportJson.php
see the exportHeader function and for the other comments just search the file for // (it's not that long).
If you don't have access to the phpMyAdmin source code you may be able to remove the comments after the file creation (either manually or with a program on your computer if you just need it once or a few times). You can use two regular expressions for that, if you need further help I can post an example.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With