Using DataTables on PHP-Site + Tune UP Performance

Using DataTables on PHP-Site + Tune UP Performance

svrsvr Posts: 23Questions: 0Answers: 0
edited August 2011 in General
hi all!
i'm new into datatables but as far as i can see right now its as nice and beautyfull as i expected during testing with the examples.
thanks to everyone sharing that plattform!!!

:) ... of course i've got some questions:

first: i cant change the example.html to example.php ... is there a way to do this? ... i'm trying to let the php-script create the datatables + dynamic ... also some javascript settings (localizing) out of a database (mysql) and after php renders the example.php datatables shows a errorpromt. is there a way to change the filetype from html to php and get use of all functonallity?

second: as i'm trying to get 3000-5000 elements displayed (with up to 30 columns) i think there might be some performance problems. is there any help to set up datatables as fast as possible or things to know how to prevent the javascript to be "lazy" ???

thanks for your help ...
stefan

ps: i'm using latest version 1.8.1

Replies

  • allanallan Posts: 63,213Questions: 1Answers: 10,415 Site admin
    [quote]svr said: first: i cant change the example.html to example.php ... is there a way to do this?[/quote]

    [code]
    mv example.html example.php
    [/code]

    :-) (in Linux / Mac). If you are getting an PHP error, it would be useful if you could show us that error, but most likely that will be a problem with your PHP installation given the source file (in this case) has no PHP in it.

    2. use Ajax sourced data with deferred rendering - that will cope with 5000+ rows no problem. Example: http://datatables.net/release-datatables/examples/ajax/defer_render.html

    Allan
  • svrsvr Posts: 23Questions: 0Answers: 0
    thank you allan for your quick reply. i have a sample here: http://wp.herrvonundzu.eu/index.php

    there are two errormessages...
    DataTables warning (table id = 'example'): Requested unknown parameter '0' from the data source for row 0

    could you please answer my question if its a problem using .php inspite of .html ? i guess it might also be a problem with the datasource and/column count as well ...


    also: is there an function reading all columnames at its own and render the tables as the datasource needs?



    stefan
  • svrsvr Posts: 23Questions: 0Answers: 0
    sorry, i made a mistake... the shown example isn'nt the right file. will check that in the afternoon.
  • svrsvr Posts: 23Questions: 0Answers: 0
    i have to say it was my fault! sorry! i jsut had to use serverside processing and php cached output to get this fixed. sorry for the irritations.

    stefan
This discussion has been closed.