开发者

CKEditor 3: Table style gets overwritten

开发者 https://www.devze.com 2023-02-24 12:48 出处:网络
I just installed CKEditor 3.0. Everything works fine, except the style of the editor. Because in this newest version the WYSIWYG buttons are put on the website (instead in a frame), my stylesheet over

I just installed CKEditor 3.0. Everything works fine, except the style of the editor. Because in this newest version the WYSIWYG buttons are put on the website (instead in a frame), my stylesheet overwrites the CKEditor buttons. My stylesheet conta开发者_Python百科ins te following:

.block table tr td,
.block table tr th {
    border-bottom: 1px solid #ddd;
    padding: 10px;
    line-height: normal;
    text-align: left;
}

But since CKEditor uses tables, they get pretty messed up. What to do?

(This question is similar to this one, but I don't think the answer given on that page is the correct answer. After all, it should be possible to solve this problem without hacking in CKEditor)


Silly me. Came up with an easy solution, just changing my stylesheet to:

.block > table

So that the rule only applies to the first table. Again, this is still not the correct way of doing this. So other answers are still welcome!

0

精彩评论

暂无评论...
验证码 换一张
取 消