<?php

include "connection.php";

// $APP_ID = $_SESSION['id'];
$MEM_ID = $_SESSION['MEM_ID'];
$query = "SELECT MEM_PHOTO FROM NAA_MEMBERS WHERE MEM_ID = '$MEM_ID' ";

					
 
 
$parseresults = ociparse($conn, $query);

ociexecute($parseresults);


 $abc = array();
while (($row = oci_fetch_array($parseresults, OCI_ASSOC+OCI_RETURN_NULLS)) != false) {

	foreach($row as $key=>$data) {

			if(is_object($data)){
				$abc[$key] = $data->load();
			//	base64_to_jpeg($data->load(),'abc.jpg');
			} else{
				$abc[$key] = $data;
			}
	}
	$abc = array_map('utf8_encode', $abc);
  //$output[]=$abc;
}
//$arout= json_decode(json_encode($output));

 
oci_free_statement($parseresults);
oci_close($conn);

$photoout=$abc['MEM_PHOTO'];




?>