Categories | Question details Back To List | ||
Header width != data column width My grid works fine in Firefox displaying all 15 columns however, in IE7 my header width appears larger than my data column widths. Though all data columns are shown, my headers are not aligned to their respective dta columns. What's more, only 12 headers are shown due to their larger size. I have provided part of my code below foryour review. Also, I have tried setting the width by adding additional code in my php to generate the <head><column width=xxx> information - it works but I wanted to use a less hard coded approach. <div id="gridbox" style="width:900px;height:600px;background-color:white;"></div> <script> mygrid = new dhtmlXGridObject('gridbox'); mygrid.setImagePath("./dhtmlxGrid/codebase/imgs/"); mygrid.setHeader("ID,Desc,%,JAN,FEB,MAR,APR,MAY,JUN,JUL,AUG,SEP,OCT,NOV,DEC"); mygrid.attachHeader("#text_filter,#text_filter, ,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan,#cspan"); mygrid.setInitWidths("75,180,50,70,70,70,70,70,70,70,70,70,70,70,70"); mygrid.enableAutoWidth(true); mygrid.setColAlign("center,left,right,right,right,right,right,right,right,right,right,right,right,right,right"); mygrid.setColTypes("ro,ro,ro,ro,ro,ro,ro,ro,ro,ro,ro,ro,ro,ro,ro"); mygrid.setColSorting("str,str,str,str,str,str,str,str,str,str,str,str,str,str,str"); mygrid.init(); SQLstr = "getRecords.php"; mygrid.setSkin("light"); mygrid.enableSmartRendering(true); mygrid.loadXML(SQLstr); </script> thanks in advance. Answer posted by dhxSupport on Nov 16, 2009 07:43 Unfortunately we cannot reproduce this issue locally. Are you using latest dhtmlxGrid version? If no - you can download latest version here http://dhtmlx.com/docs/products/dhtmlxGrid/index.shtml Answer posted by jih on Nov 16, 2009 16:54 I dug a little deeper in your knowledge base after I posted my question and found out it was a css thing that affects IE. I fould a similar post with the same problem as mine and applied the changes suggested (added a th rule). Thanks, all the same. |