Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Column Wordwrap in JQGrid

Anybody knows on how to wrap column names in JQGrid. Please find my JSON code below

colModel: [ { name: 'RequestID', index: 'CreditRequest.CreditRequestID', width:100, align: 'left' },.....

With reference to the above code if the size of the content exceeds I want it to be wrapped. Any thoughts or comments

like image 882
SARAVAN Avatar asked Dec 29 '09 19:12

SARAVAN


2 Answers

Just reference it in your own css file.

.ui-jqgrid tr.jqgrow td {
    height: 50px;
    white-space: normal;
}

As long as your css file is listed in the header after the jqGrid.css file then it will override it.

like image 163
Christine Avatar answered Oct 21 '22 18:10

Christine


For what it's worth, here it is for the header row:

.ui-jqgrid .ui-jqgrid-htable th div, .ui-jqgrid-sortable  {
    height:auto;
    overflow:hidden;
    white-space:normal !important;
}
like image 27
gsaslis Avatar answered Oct 21 '22 18:10

gsaslis