I want to push one more value id to the content value.
I want to add Photo id
$id=$comment_fet['ID'];`
to content value
$content = $comment_fet['CONTENT_VALUE'];
Now
$content="{
"name": "ghggh",
"commentuser": "jghjhgjghj",
"content_type": "alb_comment",
"website_id": "571710720",
"id": 86,
"nodes": [],
"date": "2015-12-14T06:39:25.921Z",
"displayDate": "Mon Dec 14 2015 12:09:25 GMT+0530 (India Standard Time)",
"Like": 0,
"Unlike": 0,
"rating": 0,
"reportAbuse": 0
}"
function get_album_comment($prefix) {
$postdata = file_get_contents("php://input");
$request = json_decode($postdata);
// print_r($request);
$id = $request->photoid;
$sql = "select * from user_comment where SUB_ID='$id'";
$query = mysql_query($sql) or sqlerrorhandler("(" . mysql_errno() . ") " . mysql_error(), $sql, __LINE__);
//$datas = array();
while ($comment_fet = mysql_fetch_assoc($query)) {
$content = $comment_fet['CONTENT_VALUE'];
$id=$comment_fet['ID'];
$datas[] = json_decode($content);
}
echo $get_like = json_encode($datas);
}