Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by andreea on Jun 02, 2008 02:22
open dhtmlx forum
the first column (and the rest), only the header is centered

this is the xml i have loaded : 
[...]
and this is the configuration :
mygrid = new dhtmlXGridObject('gridbox');
        mygrid.setImagePath('<?= $mosConfig_live_site ?&gt;/includes/js/dhtmlxgrid/codebase/imgs/');
        mygrid.setHeader('<?=addslashes($grid_col)?&gt;');
        mygrid.setInitWidths('<?=$grid_col_width?&gt;');

          mygrid.setColAlign('<?=$grid_col_align?&gt;');

          mygrid.setColTypes('<?=$grid_col_types?&gt;');

          mygrid.setColSorting('<?=$grid_col_sorting?&gt;');
          mygrid.enableAlterCss('even','uneven');
          mygrid.enableAutoHeigth(true);
          mygrid.enableMultiline(true);
          mygrid.init();                       
          mygrid.setSkin('light');
          mygrid.setOnCheckHandler(doOnCheck);
          mygrid.loadXML('<?= $mosConfig_live_site ?&gt;/xml_trees/<?= $actFileName ?&gt;', function(){
          mygrid.attachHeader('<?=$grid_col2?&gt;');
                document.getElementById('c_u').appendChild(document.getElementById('c_u_box').childNodes[0]);
          mygrid.setSizes();         
          mygrid.setOnGridReconstructedHandler(onGridReconstructed);

where $grid_col_align is center,center,left,left,left,left,left,left,left,left,left,left,left,left,left,left,center,center

Yet, in the first column (and the rest), only the header is centered . I also need for the rest of the cells of the column to be centered
Answer posted by Support on Jun 02, 2008 08:57
Please  check attached sample - it uses the same XML data and the same grid initialization code - but works correctly.