The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> non-floating border, div borders
cpanon
post Jan 12 2007, 12:20 PM
Post #1





Group: Members
Posts: 1
Joined: 12-January 07
Member No.: 1,533



Hello
I have a div around a table that has explicit widths. When I apply this:
border-width: 1px;
border-color: #0000ff;
border-style: solid;
to the div the border floats with the resizing of the browser. How can I get the table to obey the explicit total width and the summation of the <td> widths so the border will only enclose the area and not float? tia.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
jimlongo
post Jan 12 2007, 12:23 PM
Post #2


This is My Life
*******

Group: Members
Posts: 1,128
Joined: 24-August 06
From: t-dot
Member No.: 16



Apply the border to the table instead of the div.
Or give the div explicit width.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Christian J
post Jan 12 2007, 05:20 PM
Post #3


.
********

Group: WDG Moderators
Posts: 9,656
Joined: 10-August 06
Member No.: 7



QUOTE(cpanon @ Jan 12 2007, 06:20 PM) *

How can I get the table to obey the explicit total width and the summation of the <td> widths so the border will only enclose the area and not float? tia.

Do you mean you want the DIV to shrink to fit the table's width? That can be done by floating the DIV (and then clearing the content following).

But a DIV containing only a table makes little sense, so instead I echo jimlongo's suggestion. cool.gif
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 25th April 2024 - 09:16 AM