<?php
require_once 'config.php';
//$error=false;
$errors=array();
$cities=array();

$query="SELECT * FROM notify_to_user WHERE id=".$_GET['id'];

$row = mysqli_query($con,$query);
   
    if (mysqli_num_rows($row) >= 1) {
		//$r=mysqli_fetch_array($row)	;
			
		 while($r=mysqli_fetch_array($row)){ 
			 $clear = strip_tags($r['description']);
// Clean up things like &amp;
$clear = html_entity_decode($clear);
// Strip out any url-encoded stuff
$clear = urldecode($clear);
			$cities[]=['id'=>$r['id'],'user_id'=>$r['user_id'],'title'=>$r['title'],'description'=>$clear,'image'=>$r['image'],'attachment'=>$r['url'],'status'=>$r['status'],'created_at'=>$r['created_at']];
			
			// $cities['images']=$images;
			
			
		}   
		$errors['ibox']=$cities;
		//$errors['product_images']=$images;
		$errors['success']=true;
		$errors['message']='sms data';
    } else {
        
		$errors['success']=false;
		$errors['message']='There is content found';
    }
	echo json_encode($errors);
?>