Layout/Design of DataTables site

Layout/Design of DataTables site

dogcatgoatdogcatgoat Posts: 38Questions: 0Answers: 0
edited April 2011 in General
Hi Allan,
When I click on an example to read, I lose the site header. Most of the time, the explanations to your examples are too terse for me to understand so I usually have to search for keywords in your example to try to figure out what you are really doing.
I wanted to ask if you could please keep the header bar so that at least the search box is always present? Without having your site navigation bar on top, I have to scroll to the very bottom of the page and click on "datatables documentation" link to get to the searchbar again.
I also wanted to ask if its possible to put discussions on your individual example pages. Perhaps seeing other people's related questions here would be a good place to look for answers/respond to others with similar issues instead of always searching.
I had specific questions on your editable page:

http://www.datatables.net/examples/api/editable.html

I don't know how to use a "selector' when you suggest only enabling editing "limit to a particular column if you wish using the selector". I also do not understand most of the code that you have for it (e.g. a link to '../examples_support/editable_ajax.php', var aPos...).
Thanks again for developing such a great site.

Replies

  • allanallan Posts: 63,107Questions: 1Answers: 10,394 Site admin
    Hi dogcatgoat,

    Thanks for the feedback! There is indeed a certain level of Javascript knowledge assumed by the documentation on this site. I don't feel that it is appropriate to document how Javascript works here (nor do I have the time and energy) - for that there are books such as "Javascript the Good Parts" and "DOM Scripting". This site is intended to document the API of DataTables and show examples of how it can be used.

    I realise that the documentation isn't brilliant on this site for navigation and in future I intend to use API documentation like I have done for FixedColumns 2: http://datatables.net/docs/FixedColumns/ - for DataTables and all other 'extras'. I think this will greatly benefit anyone who wants to get specific information about the API.

    For your selector question - see the jQuery documentation for selectors: http://api.jquery.com/category/selectors/ . A quick google shows this as a resource for what selectors are: http://css.maxdesign.com.au/selectutorial/ . Also just a few posts down from this one in the forum was this thread: http://datatables.net/forums/comments.php?DiscussionID=4780&page=1#Item_2 - which should help.

    Allan
  • dogcatgoatdogcatgoat Posts: 38Questions: 0Answers: 0
    edited April 2011
    Hi Allan,
    Ah, ok, selector-- that's what your 'td' is for in the example so it makes every element selectable. I would have to specify a column instead. Thanks for the book links.
    I hope you can crowdsource your documentation more. The page you pointed me to do not show user-comments or a search bar. The layout is sexy, though.
    Thanks again...
  • dogcatgoatdogcatgoat Posts: 38Questions: 0Answers: 0
    Ok, think I'm getting it...

    I used the aoColumnDefs feature to give a class to the column I want editable like:

    [code]
    "aoColumnDefs": [{ "sClass": "myEditableName", "aTargets": [ 2 ] }
    [/code]

    and then use .myEditableName as the selector which gets the correct column :).

    I originally tried:

    [code]
    $('tr>td:nth-child(3)')
    [/code]

    but this didn't work as a selector for some reason...
This discussion has been closed.