Hi, I am trying to convert json data in to array using php. But unfortunately my json data contains encoded values. For this reason why i am unable to convert this json object in to array in php. I tried it in different ways, But i couldn't get any solutions to solve this.
This is the URL data i am getting from client side.
controller.php?type=assignPacksToServer&sid=54&skey=j59fsWqaBw!Gh!KoTbhC&svid=268&packs=[{"packid":"22","pverid":"18","yaml":"-%20url%3A%20%2Fstatic%0A%20%20static_dir%3A%20static%0A%0A-%20url%3A%20.*%0A%20%20script%3A%20provider.py"},{"packid":"23","pverid":"19","yaml":"-%20url%3A%20%2Fstatic%0A%20%20static_dir%3A%20static%0A%0A-%20url%3A%20.*%0A%20%20script%3A%20provider.py"}]
PHP Code:
$packs = json_decode(urldecode($_POST["packs"]),true);
print_r($packs);
Unfortunately it dosen't print anying. If i send null packs data, then it prints ok. Any help greatly appreciated.
Thanking you, sureace.