Editor1.3.2 - how to change table name?
Editor1.3.2 - how to change table name?
darlin
Posts: 9Questions: 1Answers: 0
Which way I can change the name of the table (the same database).
I trying change on:
var editor = new $.fn.dataTable.Editor( {
"ajax": "php/table.object.php",
"table": "#abcd",
and
Editor::inst( $db, 'abcd', 'id' )
but it is not working
This discussion has been closed.
Replies
Hi darlin,
The '#table:' refers to the name fo the datatable that you are producing (
) and not the name of the SQL table. Make sure that this #table name matches the name of your table (
<
table name="abcd"...>).
The second instance is the correct and should work fine.
I hope that helps.
nige
Ups...
thx nigel. Now is ok.
BTW, a what about if I would like to switch between more tables (the same columns)
I should make variable session storage?
something as:
It is good resolve?
That would certainly be one option. If the tables all have identical fields then there is no reason you couldn't do it that way. Another option, if they have different fields would be to have a different PHP field for each table and
include
it as needed.Allan
In case of different columns, I have to make second instance of editor and datatables?
Which way I can switch between instances? is there any methods (table/editor visable?)
You would just use standard DOM or jQuery methods (
$().show()
for example, for css display: none`). Showing and hiding a table isn't something that DataTables has built in.Allan