jeditab with datatable id=null
jeditab with datatable id=null
I have a problem with the id. It seems do be empty ?
The output of "print_r($_POST)" is
Array ( [value] => http://www.100artikel. [id] => [row_id] => null [column] => 1 )
The following code i have used:
[code]
$(document).ready(function() {
/* Init DataTables */
var oTable = $('#example').dataTable();
/* Apply the jEditable handlers to the table */
$('td', oTable.fnGetNodes()).editable( 'test3.php', {
"callback": function( sValue, y ) {
var aPos = oTable.fnGetPosition( this );
oTable.fnUpdate( sValue, aPos[0], aPos[1] );
},
"submitdata": function ( value, settings ) {
return {
"row_id": this.parentNode.getAttribute('id'),
"column": oTable.fnGetPosition( this )[2]
};
},
"height": "14px"
} );
} );
avzID
avzUrl
avzOvi
avzOviDatum
avzUser
avzPasswort
avzUpDate
avzFollow
avzArtBearb
avzEigenerAnkertxt
avzArtFreisch
avzArtIndex
avzAnmerkung
avzStatus
<?php do { ?>
<?php echo $row_test['avzID']; ?>
<?php echo $row_test['avzUrl']; ?>
<?php echo $row_test['avzOvi']; ?>
<?php echo $row_test['avzOviDatum']; ?>
<?php echo $row_test['avzUser']; ?>
<?php echo $row_test['avzPasswort']; ?>
<?php echo $row_test['avzUpDate']; ?>
<?php echo $row_test['avzFollow']; ?>
<?php echo $row_test['avzArtBearb']; ?>
<?php echo $row_test['avzEigenerAnkertxt']; ?>
<?php echo $row_test['avzArtFreisch']; ?>
<?php echo $row_test['avzArtIndex']; ?>
<?php echo $row_test['avzAnmerkung']; ?>
<?php echo $row_test['avzStatus']; ?>
<?php } while ($row_test = mysql_fetch_assoc($test)); ?>
[/code]
The output of "print_r($_POST)" is
Array ( [value] => http://www.100artikel. [id] => [row_id] => null [column] => 1 )
The following code i have used:
[code]
$(document).ready(function() {
/* Init DataTables */
var oTable = $('#example').dataTable();
/* Apply the jEditable handlers to the table */
$('td', oTable.fnGetNodes()).editable( 'test3.php', {
"callback": function( sValue, y ) {
var aPos = oTable.fnGetPosition( this );
oTable.fnUpdate( sValue, aPos[0], aPos[1] );
},
"submitdata": function ( value, settings ) {
return {
"row_id": this.parentNode.getAttribute('id'),
"column": oTable.fnGetPosition( this )[2]
};
},
"height": "14px"
} );
} );
avzID
avzUrl
avzOvi
avzOviDatum
avzUser
avzPasswort
avzUpDate
avzFollow
avzArtBearb
avzEigenerAnkertxt
avzArtFreisch
avzArtIndex
avzAnmerkung
avzStatus
<?php do { ?>
<?php echo $row_test['avzID']; ?>
<?php echo $row_test['avzUrl']; ?>
<?php echo $row_test['avzOvi']; ?>
<?php echo $row_test['avzOviDatum']; ?>
<?php echo $row_test['avzUser']; ?>
<?php echo $row_test['avzPasswort']; ?>
<?php echo $row_test['avzUpDate']; ?>
<?php echo $row_test['avzFollow']; ?>
<?php echo $row_test['avzArtBearb']; ?>
<?php echo $row_test['avzEigenerAnkertxt']; ?>
<?php echo $row_test['avzArtFreisch']; ?>
<?php echo $row_test['avzArtIndex']; ?>
<?php echo $row_test['avzAnmerkung']; ?>
<?php echo $row_test['avzStatus']; ?>
<?php } while ($row_test = mysql_fetch_assoc($test)); ?>
[/code]
This discussion has been closed.
Replies
Allan
Thank you ! Now it works.
But i get a second Problem. I have 300 rows in the table an it loads 90sec. How can i make it faster? Shout i use "server-side processing" ?
I'd suggest checking a Javascript profiler and resource loading (Firebug / YSlow etc) to see where the time is being taken up.
Allan