Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6597577
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T18:13:38+00:00 2026-05-25T18:13:38+00:00

I have a (weird ?) problem with JQGrid. I am populating the grid with

  • 0

I have a (weird ?) problem with JQGrid. I am populating the grid with local XML. I have set a JQGrid with rowNum:10 and rowList:[10,20,30,40,50].
I have 12 records.
The data (initially 10) is loaded perfectly in the grid and the table IDs are [“1”, “2”, “3”, “4”, “5”, “6”, “7”, “8”, “9”, “10”]. When I change the rowList to 20, the table IDs are [“1”, “2”, “3”, “4”, “5”, “6”, “7”, “8”, “9”, “10”, “10”, “11”]. The number 10 is shown twice.
Have anybody seen this error before ?
Thanks in advance.

JQuery version: 1.4.2
jqGrid version : 3.8.1

Code Snippets
The xml we have here is :

<?xml version=’1.0′ encoding=’utf-8′?><root><rows><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row><row><cell>prasanth</cell><cell>kumar</cell></row></rows></root>

The JQGrid is defined by the following code:


    jQuery("#tableGrid").jqGrid(
    { 
        datatype: "xmlstring",
        datastr : mystr, 
        height: 'auto', 
        rowNum: 10, 
        rowList: [10,20,30,40,50], 
        colNames:['First Name', 'Last Name'], 
        colModel:[ {name:'firstname', width:7, sorttype:"string"},
                   {name:'lastname', width:7, sorttype:"string"}       
                 ], 
        pager: "#pager", 
        viewrecords: true, 
        sortname: 'firstname', 
        autowidth:true,
        grouping:false
    }); 

When I check in firebug after changing the rowlist to 20, the rows are created as below:

<tr id="9" class="ui-widget-content jqgrow ui-row-ltr" role="row">
<tr id="10" class="ui-widget-content jqgrow ui-row-ltr" role="row">
<tr id="10" class="ui-widget-content jqgrow ui-row-ltr" role="row">

Note that the <tr id=”10″> is repeating. This happens when I put the rowNum as 10. If I change the rowNum to 3, the <tr id=”3″> will be created twice.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T18:13:39+00:00Added an answer on May 25, 2026 at 6:13 pm

    The source of the problem is that you don’t include the id information in the data which you posted. Moreover you use “retro” versions of jQuery and jqGrid. I recommend you to use jQuery 1.6.2 and jqGrid 4.1.2. Starting with the version 3.8.2 was introduced $.jgrid.randId() method which are used currently in many places. I hope that the problem are already fixed in the last version of jqGrid.

    In any way if you would add id attribute to the <row> element of your data the problem should not exist even if you would continue to use old version of jqGrid.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a weird problem. Using the mail() function and a local Postfix on
I have really weird problem with colors in interface builder. I set a color
i have a weird problem with my local Testing-Setup of a simple Java URL
i have a weird problem. i would like to delete an assembly(plugin.dll on harddisk)
I have a weird problem with images in visual web developer, I cant change
I have a weird problem where after setting nocheck on a foreign constraint and
I have this weird problem with setting up cookies with PHP. Everything worked fine
I have a weird problem that i can't figure out a solution for: I've
I have a weird problem, and I don't know if this is the default
Hey guys, I have a weird problem. I have an update system that refreshes

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.