You are here: Re: Enforcing table cell width « HTML « IT news, forums, messages
Re: Enforcing table cell width

Posted by Jukka K. Korpela on 03/06/07 20:56

Scripsit laredotornado@zipmail.com:

> What is a cross-browser way to enforce that a table cell adhere to a
> specified width

None. How wide is a table in speech rendering?

But if you are referring to reasonably new graphic browsers, then the answer
is, with the usual CSS Caveats, that you can "enforce" a width for a cell by
using table-layout: fixed for the table and by setting a width for the
entire table. (On IE, things work even if you don't set the table width; IE
defaults it to 100%.)

> even if there's a word in there that exceeds that
> width?

And what do you want to happen to the poor word? By default, the word
overflows to the neighbor cell, though IE uses the default of overflow:
hidden, i.e. brutally truncates the word. Both ways are rather problematic.

The answer to your _real_ question is _probably_ "Yes, people _can_ pollute
your guestbook with all kinds of stuff unless you take precautions. You
should preprocess the data so that the problem does not arise, e.g. by
truncating too long words before they get written onto a web page."

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация