javascripthtmlcssno-framework

Find last td without using Jquery


I need to find the Last td of every row in a HTML table, and remove a css from that td. Can I do it without using Jquery. How?


Solution

  • You can use css3 last-child property for this. Write like this:

    tr td:last-child{
     color:red;
    }
    

    But it's not work in IE8 & below.