I want to hire someone to help me with DataTables

I want to hire someone to help me with DataTables

ms_webcasams_webcasa Posts: 5Questions: 0Answers: 0
edited June 2012 in General
Here is my DataTable page: http://bryantracing.com/wp/inventory/

I want to add a click down to the top, first columns for TYPE ENGINE like this example:
http://www.datatables.net/examples/api/multi_filter_select.html

But I only need a single clickdown for that first column and at the top of the table, not the bottom.

I will pay for this to be done on my wordpress website. Please reply if you are interested. Thank you.

Replies

  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    Hi,

    Thanks very much for picking up the DataTables support option. Do you want the select list for the "Type Engine" column to be in a separate row from the rest of the header, inline with the current "Type Engine" header (i.e. replacing that text) or outside the table itself - perhaps next to the global "Search" box for the table?

    Regards,
    Allan
  • ms_webcasams_webcasa Posts: 5Questions: 0Answers: 0
    Hmmm... not sure? Probably replacing that text in the header column itself would be the cleanest way but I'm open to your suggestions. As long as someone can search by that first column, I'm good with it.

    One thing I need to let you know is that this list is an inventory list and it changes due to availability. So the table will be replaced weekly at most- with a new one- with the same name and everything. Is this going to 'undo' whatever integration you do? If so, what do you think is the best way to do this so it can be updated weekly and not erase the integration you do?
  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    Hi,

    Here we go: http://live.datatables.net/ulokuc/edit#javascript,html . The filter is dynamically created, so it will always reflect the most recent changes that you've made to the table. Also, rather than replacing the text in the header (which can be done if you want), I've added it to the header text - this way the user won't look the information about what is contained in the column.

    I've heavily commented the code that creates the table and handles the filtering, but if you have any questions about it, do feel free to ask!

    Regards,
    Allan
  • ms_webcasams_webcasa Posts: 5Questions: 0Answers: 0
    Thank you. Forgive my ignorance but I'm not at all a coder. I'm assuming the html part of the page gets cut & pasted on the page where I want to show the table. The one on the left is javascript. I'm assuming I cut & paste that into a different file? Can you give me specific instructions on where I put all of this code? Thank you!
  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    I'm afraid I'm not a WordPress user, so I can only say in general web-development terms. Basically the script I've given you needs to be inserted into the document - the function "fnCreateSelect" and the DataTables plug-in "jQuery.fn.dataTableExt.oApi.fnGetColumnData" need to be inserted into the document before the DataTables initialisation made by TableReloaded, in tags - i.e.:

    [code]

    jQuery.fn.dataTableExt.oApi.fnGetColumnData = function (...) {
    ...
    }

    function fnCreateSelect( aData ) {
    ....
    }

    [/code]

    Then the document ready function that I've put in can be inserted after TableReloaded has made its initialisation call (also in script tags). It might be an idea to ask Tobias of TableReloaded how exactly that can be done with WordPress, since, as I say, I'm not particularly family with WordPress.

    Allan
  • ms_webcasams_webcasa Posts: 5Questions: 0Answers: 0
    I think it's def. different in Wordpress as I'm modifying only the plugin files- not the html usually. How can I get ahold of Tobias to ask him specifically which files need to be changed in the wp plugin?
  • allanallan Posts: 63,542Questions: 1Answers: 10,476 Site admin
    Are you using it TableReloaded only on this page? If so, then it is no problem to change the core files - however, if you are using tables on other pages, or plan to, then changing the core files will result in these modifications being on all of the pages! As such you really want to put this Javascript on only the page with the table that you want to have this extra filter.

    If you follow this link and select the "Support" tab, Tobias (the author of WP-Table Reloaded, which packages up DataTables for WordPress) might be able to offer some advice about how to integrate my example code: http://wordpress.org/support/plugin/wp-table-reloaded .

    Regards,
    Alln
  • ms_webcasams_webcasa Posts: 5Questions: 0Answers: 0
    Thank you. I just posted it there :-)
This discussion has been closed.