Solved

How can I have vertical lines on my site

Posted on 2010-09-14
10
336 Views
Last Modified: 2012-05-10
At www.groenerekenkamer.nl I have multiple columns with differing length. There are vertical lines between them but they are limited by the text length. I would like to be line 1, 4 and 5 to be just as long (and starting at the same height) as 2 and 3 now. Can this be done?

Thanks
0
Comment
Question by:TheoRichel
  • 3
  • 3
  • 2
  • +1
10 Comments
 
LVL 3

Expert Comment

by:wuff
ID: 33672715
i had a quick look at your html code and css. I suggest you add an extra <div> surrounding your right column parts. Put border on the left and right side of it and remove the borders of div with <div id="rightwide">
0
 

Author Comment

by:TheoRichel
ID: 33672778
Thank you, but that is not unsimilar as to how its done now. If I put divs around these columns, they will only go as deep as the containing text, while I want the middle, main, column to dictate that length.
0
 
LVL 17

Expert Comment

by:mreuring
ID: 33672878
Actually for your website that's particularly easy. Since the .centerpage element already has overflow:hidden, yours is a perfect page to abuse an equal column technique with a padding/margin combination! See more: http://www.positioniseverything.net/articles/onetruelayout/equalheight

Example, add the following:
#left {
margin:0 0 -5000px;
padding:0 5px 5005px;
}

As you can see I kept the padding 5px larger than the negative margin, this is to keep the existing padding of 5px...
0
Active Directory Webinar

We all know we need to protect and secure our privileges, but where to start? Join Experts Exchange and ManageEngine on Tuesday, April 11, 2017 10:00 AM PDT to learn how to track and secure privileged users in Active Directory.

 
LVL 3

Expert Comment

by:wuff
ID: 33672978
Sorry, I misunderstood you. Never scrolled down. I thought the problem was something else.
Now I know what you mean.

Maybe if you have a container under the header which covers your left, center and right columns and then set all the outer columns div height to 100% with a top and bottom margin to get some space up and down.
0
 
LVL 17

Expert Comment

by:Thomas4019
ID: 33673751
0
 

Author Comment

by:TheoRichel
ID: 33675893
@mreuring
Thanks: I managed to create the left line, but on the right side it is more complicated. I tried:

#right2 {
  background: #FFFFFF;
  color: #000000;
  float: left;
  padding: 0px 5px 5px;
  border-right: 1px solid #006600;
  font-family: Tahoma,Verdana,Arial,Helvetica,sans-serif;
  font-size: 1em;
  margin: 0;
  width: 158px;
  overflow: hidden;
}
  #right2 {
margin:0 0 -5000px;
padding:0 5px 5005px;
}


But it didnt produce anything.
0
 
LVL 17

Expert Comment

by:Thomas4019
ID: 33676324
You don't have an element with and ID of right2 in your site's theme.
0
 
LVL 17

Expert Comment

by:mreuring
ID: 33677643
Well, since you have no single right-hand element, picking up the first element and performing the same trick worked for me, in FF3.something, using firebug on OSX...
#right1 {
border-right:1px solid black;
margin:0 0 -5000px;
padding:0 0 5005px 5px;
width:325px;
}

Open in new window

0
 

Author Comment

by:TheoRichel
ID: 33682390
@mreuring: Thanks but  applying this setting also sets the block in region right1 at another  width (right1 is supposed to be 150, not the 325 you set here, right2 158)..
I have applied the setting to right2 where it works. Only on long pages it doesnt go to the bottom, not even after I change it to 15.000px and even 2500px (after clearing the cache). See www.groenerekenkamer.nl/windenergie

If I use the setting you supplied for right1 with its regular width (150px) than this is interpreted as the right end of the page (nothing thereafter is shown anymore).

So to summarise I manage line 1,2,3 and 5, though the latter is not long enough and how about line 4?

0
 
LVL 17

Accepted Solution

by:
mreuring earned 500 total points
ID: 33685175
Well, I had a look at your page, you are sure trying to create a complicate layout :) Perhaps you should wait for CSS3 grid support!
On the short term, there is a practical limit to how much margin/padding you can supply (too much of a good thing makes the browsers belly hurt), the limit for your site (including the 5px padding) would be as follows:
[code]
#right2 {
   margin:0 0 -32762px;
   padding:0 5px 32767px;
}
[/code]

What I do not yet comprehend is what is this 'line 4'? And perhaps your salvation lies in a little cheating? Using faux-columns to generate that extra line by abusing the background of 'centerpage' and a repeating 1px gif?
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

When applying CSS to your HTML, there are many different ways to select which element(s) the CSS applies to.  Some of these selectors are more commonly known and used than others - Here are the more common ones: #X - Matches an ID of X .X - Matche…
So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …

828 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question