<?php
include "../../inc/inc.koneksi.php";
$kode= $_POST['kode'];

$sql= mysql_query("SELECT * FROM stock WHERE kode_st= '$kode' ");
$r	= mysql_fetch_array($sql);
$data['kodest']	= $r['kode_st'];
$data['namast']	= $r['nama_st'];
$data['satuan']	= $r['satuan'];
$data['hgbeli']	= $r['hg_beli'];
$data['jmlstok']= $r['jml_stokb'];
$data['expired']= $r['expired'];
echo json_encode($data);
?>