<?php
include("../../db.php");
header("Access-Control-Allow-Origin: * ");

$id = $_REQUEST['id'];
$field = $_REQUEST['field'];
$field_value = $_REQUEST['field_value'];

$aryData = array($field => $field_value);

$flgUp = $db->updateAry("student", $aryData, "where idno='$id' ");

if ($flgUp) {
    echo json_encode(array('status' => 1, 'msg' => 'Data Changed Successfully..!', 'field_value'=>$field_value));
} else {
    echo json_encode(array('status' => 0, 'msg' => 'Unable to change data..!', 'field_value'=>$field_value));
}