grid
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Untitled Document</title>
<link rel="stylesheet" href="ext/resources/css/ext-all.css"/>
<script src="ext/ext-all.js" language="javascript"></script>
<script src="ext/adapter/ext/ext-base.js" language="javascript"></script>
<script src="ext/ext-all-debug.js" language="javascript" type="text/javascript"></script>
<script>
Ext.onReady(function(){
var store=new Ext.data.Store({
url:'json_data_format2.php',
reader:new Ext.data.JsonReader({
root:'rows',
totalProperty:'results',
id:'id'
},[
'name',
'email',
'address'
])
});
store.load();
var grid=new Ext.grid.GridPanel({
renderTo:document.body,
frame:true,
title:'Student Record',
height:300,
width:500,
store:store,
columns:[
{header:"Name",sortable:true,dataIndex:'name'},
{header:"Email",sortable:true,dataIndex:'email'},
{header:"Address",sortable:true,dataIndex:'address'}
]
});
//Ext.Msg.alert('Title','Hello world');
});
</script>
</head>
<body>
</body>
</html>
Comments 0