Disable ordering on the first column
Disable ordering on the first column
lienkhuong
Posts: 2Questions: 1Answers: 0
hello, i want to disable ordering on the first column
i use wordpress and use plugin Inline Google Spreadsheet Viewer
my shortcode
[gdoc key=”https://docs.google.com/spreadsheets/d/W7pjg1L8VvpO36SjUfhSSMHMp67PsLNjWZKz1So/edit#gid=788544765″ query=”select B,H,I,J” datatables_dom=”flrtip” datatables_page_length=”100″ class=”stripe hover”]
and i use js:
$('#igsv-W7pjg1L8VvpO36SjUfhSSMHMp67PsLNjWZKz1So').dataTable( {
"columnDefs": [
{ "orderable": false, "targets": 0 }
]
} );
but the first column not disable
how to fix it
Thanks
Edited by Colin - Syntax highlighting. Details on how to highlight code using markdown can be found in this guide.
This discussion has been closed.
Replies
Yep, that's all you should need - see here. It suggests that code isn't initialising the table - is something else doing it perhaps?