|
Prev: Text Height
Next: two flowed columns?
From: Steve Swift on 23 Jan 2008 04:05 The table in question is at http://www.swiftys.org.uk/calendar The HTML is pre-Cambrian, almost certainly invalid, generated by one of the first CGI scripts that I ever wrote, about 15 years ago (initially). The strange fact is that it works in all popular browsers. It even works in "Off by One". The edge in question is the boundary between the tall/narrow grey cell on the right and the large grey cell at the "south east" corner of the table. I'd like it to go away, and I suspect this is a job for CSS. This raises an interesting question (I find it interesting): Which cell "owns" that boundary? Or is it somehow shared between the adjacent cells? Please, I'm not interested in criticism of the HTML or layout of the page any more than I'd be interested in criticism of the brand of oil I use on the wooden handle of my hammer. They are both tools, and they both work for me. That border is driving me nuts though, now I've noticed it, so if you can suggest how to make it go away, or even just reduce it a bit, then I'm all ears. -- Steve Swift http://www.swiftys.org.uk/swifty.html http://www.ringers.org.uk
From: Steve Swift on 24 Jan 2008 13:38 rf wrote: > If you want a particular cell to not have a border then you must switch off > the HTML borders (border='0') and switch on CSS borders (td {border=solid > 1px grey}). In your case it looks like top and left borders are dark grey > and the other two are light grey. Style them accordingly. Aha! A light comes on. I've seen borders defined as "ridge" and things like indented and outdented in HTML. What is actually happening is that the borders are coloured as you say, but inside the table, the cells are actually separated by a pair of different-coloured borders. The tricky part is maintaining the ridge effect on the exterior borders of the table, where there would be only a single (i.e. half width) border. I suspect this is the point where I gave up trying to emulate tables using DIV's - I never managed to make the exterior borders look the same as the interior ones. I suspect that the simplest solution is to do nothing. After a while, I'll stop noticing that extra tiny piece of border, in the same way that I don't see the paint peeling off my front door. :-) -- Steve Swift http://www.swiftys.org.uk/swifty.html http://www.ringers.org.uk
From: rf on 24 Jan 2008 20:36 "Steve Swift" <Steve.J.Swift(a)gmail.com> wrote in message news:479a288d$1(a)news.greennet.net... > rf wrote: >> If you want a particular cell to not have a border then you must switch >> off the HTML borders (border='0') and switch on CSS borders (td >> {border=solid 1px grey}). In your case it looks like top and left borders >> are dark grey and the other two are light grey. Style them accordingly. > > Aha! A light comes on. I've seen borders defined as "ridge" and things > like indented and outdented in HTML. What is actually happening is that > the borders are coloured as you say, but inside the table, the cells are > actually separated by a pair of different-coloured borders. The tricky > part is maintaining the ridge effect on the exterior borders of the table, > where there would be only a single (i.e. half width) border. You would utilise the tables border, which sits around the cell borders. > I suspect this is the point where I gave up trying to emulate tables using > DIV's - Don't. If it's a table then use a table. That is what they are for. > I never managed to make the exterior borders look the same as the interior > ones. Table border. > I suspect that the simplest solution is to do nothing. After a while, I'll > stop noticing that extra tiny piece of border, in the same way that I > don't see the paint peeling off my front door. :-) <tinkers> http://barefile.com.au/swift/calendar.htm Messy but it works. Look for the comments on the bits I changed, at the beginning and right at the end. -- Richard.
From: Steve Swift on 25 Jan 2008 05:16 rf wrote: > <tinkers> > http://barefile.com.au/swift/calendar.htm > Messy but it works. > Look for the comments on the bits I changed, at the beginning and right at > the end. Thank you! It will be a while before I get a chance to work out what you did, and how it works. Than I can add it to my CGI script. Incidentally, the table that I tried to convert to <DIV>s was not truly a table. It was a box into which I wanted to put 29 short facts about something. Each fact would fit in a table cell without wrapping. The page was a sequence of these "tables". I've ended up using a table with 100 columns, and using "COLSPAN=X" in each cell to achieve the necessary weight/width for each individual cell. The effect is like a brick wall built from random length bricks. It's not a table, as such. It would be easier to add extra facts, as happens occasionally, if I were dealing with the relative weights of each cell in its row. That way, it wouldn't matter if they didn't add up to 100. -- Steve Swift http://www.swiftys.org.uk/swifty.html http://www.ringers.org.uk
|
Pages: 1 Prev: Text Height Next: two flowed columns? |