Trouble styling tables collected from php Ajax source.
Trouble styling tables collected from php Ajax source.
First off let me apologize as I am fairly new to all of this. We have been using data tables for a while now and have had great success. However we have currently run into a situation where a more dynamic feel is needed. We found the need to refresh the table without refreshing the entire page. So we turned to Ajax to solve this issue. Which worked perfectly as far as returning table data sourced from a php file which built the table and passed it back. However where we have now hit a snag is applying the styling back to the data that has been returned. No matter what I try I end up with a style free table. After some tinkering it seems to be that it has to do with the scripts not running for the data that is collected through Ajax. If we build the table on the main page there are no issues, but as soon as we scrap that and collect the table from Ajax source we lose styling.
This discussion has been closed.
Replies
See http://datatables.net/examples/api/highlight.html, http://datatables.net/examples/advanced_init/highlight.html, and http://datatables.net/examples/advanced_init/row_callback.html
Hth,
Gerardo
We ended up building off the Server Side Example and finally got it.