≡
×
Plus
Manual
Examples
Reference
Download
Blog
Community
Support
hyperlink column in data table
hyperlink column in data table
sameer
Posts: 2
Questions: 0
Answers: 0
September 2011
edited September 2011
in
General
is it possible to create hyperlink column in data table witout any concern with sql
Replies
sameer
Posts: 2
Questions: 0
Answers: 0
September 2011
If it possible then plz give me reply ?
fbas
Posts: 1,094
Questions: 4
Answers: 0
September 2011
yes. http://www.datatables.net/ref#fnRender
[code]
/* Using aoColumnDefs */
$(document).ready(function() {
$('#example').dataTable( {
"aoColumnDefs": [
{
"fnRender": function ( oObj ) {
return 'oObj.aData[3]+'';
},
"aTargets": [ 0 ]
}
]
} );
} );
[/code]
oObj is an object with the following parameters:
- int:iDataRow - the row in aoData
- int:iDataColumn - the column in question
- array:aData - the data for the row in question
- object:oSettings - the settings object for this DataTables instance
This discussion has been closed.
Replies
[code]
/* Using aoColumnDefs */
$(document).ready(function() {
$('#example').dataTable( {
"aoColumnDefs": [
{
"fnRender": function ( oObj ) {
return 'oObj.aData[3]+'';
},
"aTargets": [ 0 ]
}
]
} );
} );
[/code]
oObj is an object with the following parameters:
- int:iDataRow - the row in aoData
- int:iDataColumn - the column in question
- array:aData - the data for the row in question
- object:oSettings - the settings object for this DataTables instance