Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
jqGrid not displaying any records
02/07/2014
01:56
Avatar
bkoubik
New Member
Members
Forum Posts: 1
Member Since:
02/07/2014
sp_UserOfflineSmall Offline

Hi,

 

my grid persists empty.

I don´t know why - what must i change?

Tanks

Here is my code:

 <!DOCTYPE html>
<html>
<head>
<meta charset="ISO-8859-1">
<title>Insert title here</title>
<link rel="stylesheet" href="//code.jquery.com/ui/1.10.4/themes/ui-lightness/jquery-ui.css">
<link rel="stylesheet" href="jqgrid/css/ui.jqgrid.css">

<script type='text/javascript' src='//cdnjs.cloudflare.com/ajax/libs/jquery-ajaxtransport-xdomainrequest/1.0.0/jquery.xdomainrequest.min.js'></script>

<script src="//code.jquery.com/jquery-1.10.2.js"></script>
<script src="jqgrid/js/grid.locale-de.js"></script>
<script src="jqgrid/js/jquery.jqGrid.min.js"></script>

<script type="text/javascript">
$(function () {
    $("#list").jqGrid({
        url: 'http://www.iNorthwind.com/Service1.svc/getOrdersForCustomer/BERGS',
        contentType: "application/json",
        datatype: "json",
        jsonReader: {
            root: "GetOrdersForCustomerResult",
            id: "OrderID",
            repeatitems: false
        },
        mtype: "GET",
        colNames: ["ID", "Date", "ShipName", "ShipAddress", "ShipCity", "ShippedDate"],
        colModel: [
            { name: "OrderID", width: 80, align: "center" },
            { name: "OrderDate", width: 90, align: "center" },
            { name: "ShipName", width: 250 },
            { name: "ShipAddress", width: 250 },
            { name: "ShipCity", width: 95 },
            { name: "ShippedDate", width: 95 },
        ],
        pager: "#pager",
        height: 'auto',
        rowNum: 8,
        rowList: [8, 16, 24],
        loadonce: true,
        sortname: "OrderID",
        sortorder: "desc",
        viewrecords: true,
        gridview: true,
        ignoreCase: true,
        autoencode: true,
        caption: "Northwind orders"
    });
});
</script>
</head>
<body>
    <table id="list"><tr><td></td></tr></table>
    <div id="pager"></div>
</body>
</html>

Insert title here

//

 
 
08/07/2014
10:52
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

Please look at your server response. Seee documentation

Regards

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
29 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information