Search code examples
javascriptfunctiondatatabletabletools

What do you mean by the initial letter on javascript variables/functions


The code below is just an example, this code is from jQuery DataTable. I just would like to know what is the meaning of "o" in oTable, "b" in bServerSide and the others. Are they holding some kind of meaning?

  var oTable = $('#unis').dataTable({
    //"bProcessing": true,
    "bServerSide": true,
    "sAjaxSource": "index.php?...&<?php echo JSession::getFormToken() . '=1' ?>",
    "sDom": "<'row-fluid'<'span6'T><'span6'f>r>t<'row-fluid'<'span6'l><'span6'p>>",
    "sPaginationType": "bootstrap",
       "aoColumns":[
                {"bSortable": false},
                {"bSortable": false},
                {"bSortable": true},
                {"bSortable": true},
                {"bSortable": false},
              ],
    "oTableTools": {
    "aButtons": [ "delete selected", "export" ]
}  

});

Solution

  • Those prefixes refer to the datatype of the variable:

    b = boolean
    s = string
    o = object
    a = array
    ao = array of objects