Loading...

RE: remove or disable sort on column header in qlistview

RE: remove or disable sort on column header in qlistview

#7200
Anonymous
Anonymous
Participant

Hi ,

About how to hide the column header. Please follow these steps:

  1. Open ezEdit.
  2. Go to Grid Appearance tab. Input to following line in the Header Style: display:none;
  3. Save the configuration.

About how to disable the sorting by clicking the column header. qListView doesn’t have an option to disable the sorting for a specific column. If you want to do this, you need to use javascript.

  1. Open ezEdit, then go to Custom Display tab. Copy and paste the following javascript to the Results Footer, remember to replace the value of the colTitle to your actual column title displayed on the header.
    <script type="text/javascript">
    var links=document.getElementsByTagName("a");
    var colTitle="WE WANT TO HIDE THIS OR STOP IT FROM SORTING";
    for(var index=0;index<links.length;index++)
    {
    var colHeader=links[index];
    if(colHeader.innerText==colTitle)
    {
    colHeader.href="#";
    }
    }
    </script>
  2. Go to Display tab, uncheck Enable AJAX to disable the AJAX. So that the javascript can be run every time the qListView raises a postback event.
  3. Save the configuration.

Thanks,