It's way too much work to create a restful web service. Why can't we just create a simple php page which receives requests and simply echos the JSON string. for example:
<?php
$action = $_POST['action'];
if (action == "users")
{
//get all users from DB and echo a JSON string
}
else if (action = "ads")
{
//get all ads from DB and echo a JSON string
}
//etc ect
?>