Border around specific rows in a table?

后端 未结 10 1573
轮回少年
轮回少年 2020-12-02 08:10

I\'m trying to design some HTML/CSS that can put a border around specific rows in a table. Yes, I know I\'m not really supposed to use tables for layout but I don\'t know en

10条回答
  •  Happy的楠姐
    2020-12-02 08:56

    the trick is with outline property thanks to enigment's answer with little modification

    use this class

    .row-border{
        outline: thin solid black;
        outline-offset: -1px;
    }
    

    then in the HTML

    ....
    
        ...
        ...
    
    

    and the result is hope this helps you

提交回复
热议问题