You are here: Re: How to put some space at the left margin of a table cell? « HTML « IT news, forums, messages
Re: How to put some space at the left margin of a table cell?

Posted by Adrienne Boswell on 06/21/06 22:43

Martin wrote:
> In some cases, I want to space the data in a table cell over a little
> bit (have some white space between the left cell border and the text).
> But ONLY on the left side - not at the top and bottom. If I set the
> "padding", it enlarges the entire cell - I don't want that.
>
> I generally do this by inserting several " " before the cell text
> when I generate the table. This accomplishes what I want but is this
> the "best" way?
>
> One case in which the   does not work very well is when the cell
> text is a "hot link" (an href anchor tag); then the  's are
> underlined and it doesn't look good.
>
> Any thoughts?
>
> Thanks

CSS is the way to go, for example:

td {padding-left:.5em}

This will affect all tds in the table. Put it in an external sheet
(recommended), or put it in the head in a style element.

HTH
--
Adrienne Boswell at work
Administrator Nextblock
http://atlas.nextblock.com/files/
Please respond to the group so others can share

 

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

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