Start Building Professional
Web Apps Today


 
Categories Question details Back To List
Question  posted by andreea on May 30, 2008 02:12
open dhtmlx forum
i have done so : mygrid = new dhtmlXGridObject('gridbox'); mygrid.setImagePath('
i have done so :


          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);
          mygrid.callEvent('onGridReconstructed',[]);
          });


yet the columns are left aligned  . The $grid_col_align is 'center,center,center,center and so one '
Answer posted by Support on May 30, 2008 03:45
The only situation when such problem may occur - the XML which you are loading contains head/column section with different configuration , which redefine js settings.
In any other case align must work ( sample attached )

If problem still occurs for you - please provide any kind of sample where issue can be reconstructed ( you can send it directly to support@dhtmlx.com )

Attachments (1)