With Jeditable but not on all column

With Jeditable but not on all column

mickeymicmickeymic Posts: 23Questions: 0Answers: 0
edited September 2009 in General
Hello,

Sorry for my english.

I use DataTables wih Jeditable like http://www.datatables.net/examples/api/editable.html

And I want that my last column is not editable. (because it's a checkbox)

Is it possible ?

Please can you explain to me... Try to use easy english words...

Thanks

Replies

  • allanallan Posts: 63,498Questions: 1Answers: 10,471 Site admin
    Hi mickeymic,

    You just need to use the correct selector in your jQuery statement. I'm using "$('#example tbody td')", but it could be "$('#example tbody tr td:eq(0)')" which (I think!) will select the first column. You can modify the selector to match exactly what you are looking for - have a look at the jQuery documentation: http://docs.jquery.com/Selectors

    Regards,
    Allan
  • mickeymicmickeymic Posts: 23Questions: 0Answers: 0
    Hello allan,

    ok it's good for me

    Thanks

    ;D)
  • bakaynbakayn Posts: 14Questions: 0Answers: 0
    not function "$('#example tbody tr td:eq(0)')", this only edit the target (0,0) from the table (comprobated) and see http://docs.jquery.com/Selectors/eq#index.

    i need edit the fourth column.

    help pliss !!!
  • bakaynbakayn Posts: 14Questions: 0Answers: 0
    edited September 2009
    i found the solution (proven functionality):
    [code] jQuery('table.styleTable tbody tr td:nth-child(7)').editable( { .... } ); [/code]

    '7' is the number the editable column.
  • condondcondond Posts: 6Questions: 0Answers: 0
    Could Someone put this into an example?

    I am a beginning javascripter. I am having the same trouble and could use a full example.
This discussion has been closed.