jqgrid's rowlist option is an array of integers that it uses to construct a dropdown; the user makes a selection from the dropdown to specify how many rows to see on the page. But there's no label next to the dropdown to tell the user what it's for. Has anyone come up with a tidy solution to putting an explanatory label of text next to this dropdown?
A:
jQuery("#<pager> .ui-pg-selbox").closest("td").before("<td dir='ltr'>No. Of Rows </td>");
Where <pager>
is the id of the grid's pager.
Vinodh Ramasubramanian
2010-01-14 14:22:10
Be aware that the .before() and .after() methods as used here are not idempotent, so if you use them in, say, a loadComplete event handler, you will need to write some first-time-only guard logic.
David Gorsline
2010-01-28 22:09:02