Ask Your Question

CSS should not use fixed width for elements with localizable text

asked 2012-08-05 03:29:30 -0500

Zahid's avatar

updated 2012-08-05 23:54:21 -0500

I see lots of cosmetic bugs. By checking I found that most of the elements are of fixed width. It is a bad practice actually. Let say about button Ask you question if I use my locale translation it cut-off. It is because of css fixed width. same for fixed height also.

Need to maintain it by css padding and margin.

As per Evegeny's comment, I'm attaching a screenshot. But actually lots of problem in other pages also. This make such a great app ugly :( image description

See highlighted area with red rectangle.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2012-08-05 11:55:09 -0500

Evgeny's avatar

It's fixed width to make the button look as wide as the column below - for the same cosmetic reasons.

You can create a fix for your language using the "lang-..." class on the body, which is added automatically.

edit flag offensive delete link more


It is fine that top ask you questions are fixed width. But I have seen lots of other elements arround with fixed width.

Does askbot provide any setting to set lang property in html body?

Thanks again!

Zahid's avatar Zahid  ( 2012-08-05 12:07:10 -0500 )edit

The language code is automatically set as class name on the "body" tag - take a look in the html source. I agree that most elements should not have fixed width - let me know which you find problematic.

Evgeny's avatar Evgeny  ( 2012-08-05 12:21:33 -0500 )edit

I have attached a screenshot with a cosmetic-error.

Zahid's avatar Zahid  ( 2012-08-05 23:54:52 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2012-08-05 03:29:30 -0500

Seen: 283 times

Last updated: Aug 05 '12