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
4.1.2 error: b.jgrid.jqID is not a function
30/09/2011
04:48
Avatar
yeecn
Member
Members
Forum Posts: 5
Member Since:
29/09/2011
sp_UserOfflineSmall Offline

Firefox reported the following error:

Error: b.jgrid.jqID is not a function
Source File: https://www.b2k.com/b2k/js/jqGrid-4.1.2/js/jquery.jqGrid.min.js
Line: 74

The page is as follows (jsp):

<HTML>
    <HEAD>
        <link type="text/css" href="${pageContext.request.contextPath}/js/jquery-ui-1.8.16/css/ui-lightness/jquery-ui-1.8.16.custom.css" rel="Stylesheet" />
        <script type="text/javascript" src="${pageContext.request.contextPath}/js/jqGrid/jquery-1.5.2.min.js"></script>
        
        <link type="text/css" href="${pageContext.request.contextPath}/js/jqGrid-4.1.2/css/ui.jqgrid.css" rel="Stylesheet" />
        <script type="text/javascript" src="${pageContext.request.contextPath}/js/jqGrid-4.1.2/js/jquery.jqGrid.min.js"></script>
        <script type="text/javascript" src="${pageContext.request.contextPath}/js/jqGrid-4.1.2/js/i18n/grid.locale-en.js"></script>
        
        <script>

        var mystr =
             "<?xml version='1.0' encoding='utf-8'?><invoices><rows><row>"
            + "<cell>data1</cell><cell>data2</cell><cell>data3</cell><cell>data4</cell><cell>data5</cell><cell>data6</cell>"    
            + "</row></rows></invoices>";
            
            jQuery(document).ready(function(){
                  jQuery("#list").jqGrid({
                    datatype: 'xmlstring',
                    datastr : mystr,
                    colNames:['Inv No','Date', 'Amount','Tax','Total','Notes'],
                    colModel :[
                      {name:'invid', index:'invid', width:55, sorttype:'int'},
                      {name:'invdate', index:'invdate', width:90, sorttype:'date', datefmt:'Y-m-d'},
                      {name:'amount', index:'amount', width:80, align:'right', sorttype:'float'},
                      {name:'tax', index:'tax', width:80, align:'right', sorttype:'float'},
                      {name:'total', index:'total', width:80, align:'right', sorttype:'float'},
                      {name:'note', index:'note', width:150, sortable:false} ],
                    pager: '#pager',
                    rowNum:10,
                    viewrecords: true,
                    caption: 'My first grid'
                  });
                });
        </script>
    </HEAD>

    <BODY>
        <table id="list"></table>
        <div id="pager"></div>
    </BODY>
</HTML>

30/09/2011
05:11
Avatar
yeecn
Member
Members
Forum Posts: 5
Member Since:
29/09/2011
sp_UserOfflineSmall Offline

The example was take from jqGrid Wiki - xmlstring

http://www.trirand.com/jqgridw.....eving_data

30/09/2011
09:39
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello,

I'm not sure if the example is taken from the wiki.

You problem is that the locale file (grid.locale-en.js) should be loaded before the grid file (jquery.jqGrid.min.js).

This situation is very clear described into the  wiki docs

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.

30/09/2011
09:42
Avatar
tony
Sofia, Bulgaria
Moderator
Members

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

Hello again.

More over your example will not work in IE based browsers.

Please set a DOCTYPE too.

Also please read carfully the docs and try to understand them.

Here is the right link to the wiki

http://www.trirand.com/jqgridw.....to_install

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.

30/09/2011
10:02
Avatar
yeecn
Member
Members
Forum Posts: 5
Member Since:
29/09/2011
sp_UserOfflineSmall Offline

Oh my.... I forgot all about the ordering of the .js

Perhaps it pays to highlight it in install.txt

Thanks very much for your help.

Regards,

Chut

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
48 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