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
Internet Explorer problem. Anyone help pls!
23/03/2009
06:04
Avatar
fractalsanta
New Member
Members
Forum Posts: 2
Member Since:
23/03/2009
sp_UserOfflineSmall Offline

Hi there,

Could anyone help pls - currently having issues with getting my grid to work in IE7. The grid renders fine in Firefox, but in Internet Explorer 7 the red loading message ("Loading...") does not disappear and the pagination and other elements dont display. Also, the sorting doesn't work. In FF everything renders fine, except that the pagination doesn't work. I'm using a JSONSTRING to display the data.

Could anyone please help? Here is the html output that is created by a custom PHP class :

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
                    "http://www.w3.org/TR/html4/loose.dtd">
                   
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>iSAMS Layout</title>
<!--CSS declarations-->
<link rel="stylesheet" type="text/css" href="css/main.css" />
<link rel="stylesheet" type="text/css" href="css/accordion.css" />
<link rel="stylesheet" type="text/css" media="screen" href="themes/basic/grid.css" />
<link rel="stylesheet" type="text/css" media="screen" href="themes/jqModal.css" />
<!--JS declarations-->
<script src="jquery.js" type="text/javascript"></script>
<script src="jquery.jqGrid.js" type="text/javascript"></script>

<script type="text/javascript" src="jquery-ui-personalized-1.5.3.js"></script>

</head>

                         
          <script type="text/javascript">
 var mystr =
  "{" +
  "total: '3'," +
  "page: '1'," +
  "records: '13'," +
  "rows : [" +
  "{id:'0', cell:[]}," + "{id:'1', cell:['1','Akasia','1234']}," + "{id:'2', cell:['2','Pretoria Noord','1334']}," + "]" +
  "}";
  
  jQuery(document).ready(function()
  {jQuery("#list").jqGrid(
  { datatype: 'jsonstring',
   datastr: mystr, 
   jsonReader : {
      root: "rows",
      page: "page",
      total: "total",
      records: "records",
      repeatitems: true,
      cell: "cell",
      id: "id",
      subgrid: { root:"rows", repeatitems: true, cell:"cell" }
   },

     colNames:['SchoolID','SchoolName','EMISNumber'],
           colModel :[{name:'SchoolID',index:'SchoolID', width:20, sortable:true, align:'center'},{name:'SchoolName',index:'SchoolName', width:20, sortable:true, align:'center'},{name:'EMISNumber',index:'EMISNumber', width:20, sortable:true, align:'center'}],
     pager: jQuery('#pager2'),
     rowNum:10,
     rowList:[10,20,30],
     imgpath: 'themes/basic/images',
     sortname: 'SchoolID',
     viewrecords: true,
     sortorder: 'asc',
     caption: 'GridName',
     width: 300,
     height: 200

  
    }).navGrid('#pager2',{edit:false,add:false,del:false});
   });
  
  </script>          
          </head>
          <body>
          <!-- the grid definition in html is a table tag with class 'scroll' -->
          <table id="list" class="scroll" cellpadding="0" cellspacing="0"></table>
          <div id="pager2" class="scroll" style="text-align:left;"></div>                      
     
   <br style="clear: both;" />
</body>
</html>

Your help would be much appreciated!

23/03/2009
06:24
Avatar
fractalsanta
New Member
Members
Forum Posts: 2
Member Since:
23/03/2009
sp_UserOfflineSmall Offline

Also, will the jsonstring method work if I want to implement the search functionality later. Since I'm not going to be using $_GET or anything does this limit me with AJAX usage as well?

24/03/2009
02:19
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

Before to pass this in jqGrid try to see what is when you do this in IE7

var myjsonarr = eval("("+mystr+")");

This should produce a json object, but I see emty cell - ie cell:[],

Try to put emty data here instead that this should be empty.

Regards

Tony

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:
55 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