473,813 Members | 2,745 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

CSS formatted links not working

Hi there

Am doing some work on a page at the moment, a bit of a newbie at the
moment with CSS and am having a few troubles.

The left hand navigation does not seem to work when a gap is inserted
in the space between it and the body text. I could not get left margin
or left padding to work. So in the end, I positioned the bodytxt div
as relative and put left:10px; in to give a 10px gap. When this gap is
removed, the left nav works fine, but for some reason it will not work
with the space.

Here is the link to the page:
www.fuzzcube.com

for what it is worth, the left nav is built up using a SSI include,
the target for the link page is:
www.fuzzcube.com/leftlinkinclude.php

Thanks in advance
Paul
Jun 27 '08 #1
8 1473
On May 22, 9:15*pm, mehstg1319 <meh...@gmail.c omwrote:
Hi there

Am doing some work on a page at the moment, a bit of a newbie at the
moment with CSS and am having a few troubles.

The left hand navigation does not seem to work when a gap is inserted
in the space between it and the body text. I could not get left margin
or left padding to work. So in the end, I positioned the bodytxt div
as relative and put left:10px; in to give a 10px gap. When this gap is
removed, the left nav works fine, but for some reason it will not work
with the space.

Here is the link to the page:www.fuzzcube.com

for what it is worth, the left nav is built up using a SSI include,
the target for the link page is:www.fuzzcube.com/leftlinkinclude.php

Thanks in advance

Paul
sorry got the link wrong:

http://www.fuzzcube.com/leftLinkInclude.php
Jun 27 '08 #2
In article
<2a************ *************** *******@r66g200 0hsg.googlegrou ps.com>,
mehstg1319 <me****@gmail.c omwrote:
http://www.fuzzcube.com/leftLinkInclude.php
Care to comment on why you are marking up like this?

--
dorayme
Jun 27 '08 #3
mehstg1319 wrote:
Hi there

Am doing some work on a page at the moment, a bit of a newbie at the
moment with CSS and am having a few troubles.

The left hand navigation does not seem to work when a gap is inserted
in the space between it and the body text. I could not get left margin
or left padding to work. So in the end, I positioned the bodytxt div
as relative and put left:10px; in to give a 10px gap. When this gap is
removed, the left nav works fine, but for some reason it will not work
with the space.

Here is the link to the page:
www.fuzzcube.com

for what it is worth, the left nav is built up using a SSI include,
the target for the link page is:
www.fuzzcube.com/leftlinkinclude.php

Thanks in advance
Use Firefox with WebDeveloper's Bar, set to "Outline Current Element"
and hover you cursor over your links and see what div#bodytxt
covers...hint, your menu won't work that way..

--
Take care,

Jonathan
-------------------
LITTLE WORKS STUDIO
http://www.LittleWorksStudio.com
Jun 27 '08 #4

mehstg1319 wrote:
>
The left hand navigation does not seem to work when a gap is inserted
in the space between it and the body text. I could not get left margin
or left padding to work. So in the end, I positioned the bodytxt div
as relative and put left:10px; in to give a 10px gap.

www.fuzzcube.com
I had to read this several times to figure out what this "gap" thing is
supposed to be. I see no text in the page to illustrate the problem,
probably due to the absolute height values coupled with overflow:hidden .
Hint: try looking at the page in a narrower window, like around 800px.

I'm going to take a shot in the dark anyway. You want a 10px space
between the left column and the text in the main content area. Yes? If
so, then you're not understanding how floats work, or more specifically,
how other elements flow around them.

If you don't already have it, get the Web Developer extension for
Firefox, then turn on outlines for block elements. You'll see that the
left edge of the #bodytxt block is not at the right edge of #left-nav
like you probably thought. Set margin-left of #bodytxt to 10px more than
the width of #left-nav and drop the left:10px. The width setting should
now be unnecessary, as #bodytxt will now take all the available space.
for what it is worth, the left nav is built up using a SSI include
That should be irrelevant.

--
Berg
Jun 27 '08 #5
On 05/22/08 01:15 pm, mehstg1319 wrote:
>
Am doing some work on a page at the moment, a bit of a newbie at the
moment with CSS and am having a few troubles.

The left hand navigation does not seem to work when a gap is inserted
in the space between it and the body text. I could not get left margin
or left padding to work. So in the end, I positioned the bodytxt div
as relative and put left:10px; in to give a 10px gap. When this gap is
removed, the left nav works fine, but for some reason it will not work
with the space.
The positioning moved the bodytxt div over the menu blocking access to
the menu.
Here is a method for a 3 column layout that has the left and right
columns at a fixed size:
- Float the left column left
- Float the right column right
- Set the center column (your #content) with a left margin large enough
for the left column, and a right margin large enough for the right column.

Get rid of all of the positioning CSS rules.
Get rid of the overflow rules.
Get rid of the height rules (except for images).
You will have to change #bodytxt to .bodytxt so that you can insert the
right column <divin between two bodytxt blocks (one for the heading,
which should be an h1, the other for the body text).

--
jmm (hyphen) list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Jun 27 '08 #6
On May 23, 12:48*am, Jim Moe <jmm-list.AXSPA...@s ohnen-moe.comwrote:
On 05/22/08 01:15 pm, mehstg1319 wrote:
Am doing some work on a page at the moment, a bit of a newbie at the
moment with CSS and am having a few troubles.
The left hand navigation does not seem to work when a gap is inserted
in the space between it and the body text. I could not get left margin
or left padding to work. So in the end, I positioned the bodytxt div
as relative and put left:10px; in to give a 10px gap. When this gap is
removed, the left nav works fine, but for some reason it will not work
with the space.

* The positioning moved the bodytxt div over the menu blocking access to
the menu.
* Here is a method for a 3 column layout that has the left and right
columns at a fixed size:
- Float the left column left
- Float the right column right
- Set the center column (your #content) with a left margin large enough
for the left column, and a right margin large enough for the right column.

* Get rid of all of the positioning CSS rules.
* Get rid of the overflow rules.
* Get rid of the height rules (except for images).
* You will have to change #bodytxt to .bodytxt so that you can insert the
right column <divin between two bodytxt blocks (one for the heading,
which should be an h1, the other for the body text).

--
jmm (hyphen) list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Have almost got it working now, seems to break in Safari and Opera now
though (Mac versions, i'm not sure about windows.)
Paul
Jun 27 '08 #7

mehstg1319 wrote:
>
Have almost got it working now, seems to break in Safari and Opera now
re: http://www.fuzzcube.com/

You need to get rid of the fixed heights. What do you expect to happen
when there is more text than will fit in height:500px? All you have to
do is bump up the text size a couple times and it all spills out.

You also don't need to make a separate div for every image, or use empty
paragraphs to space things out. Make use of margin, padding and
background images better and you can get rid of a lot of bloat.

Use the cube image as a background for the left column, move some of
those styles to other elements and trim the HTML.

#left-nav {
background: #ff0 url(../img/cube.jpg) center top no-repeat;
padding-top: 180px; /* img height + some padding */
}
#left-nav ul {
border-top: 1px solid #fff;
}

<div id="left-nav">
<ul><li><a href="http://www.fuzzcube.co m/index.php?id=1" >Home </a></li>
....
</ul>
</div>

Likewise, use the silhouette as a background image for the #bodytxt
area. Apply padding right to keep the text clear of the image. No need
for an empty div for this.

--
Berg
Jun 27 '08 #8
On May 23, 7:45*pm, Bergamot <berga...@visi. comwrote:
mehstg1319 wrote:
Have almost got it working now, seems to break in Safari and Opera now

re:http://www.fuzzcube.com/

You need to get rid of the fixed heights. What do you expect to happen
when there is more text than will fit in height:500px? All you have to
do is bump up the text size a couple times and it all spills out.

You also don't need to make a separate div for every image, or use empty
paragraphs to space things out. Make use of margin, padding and
background images better and you can get rid of a lot of bloat.

Use the cube image as a background for the left column, move some of
those styles to other elements and trim the HTML.

#left-nav {
background: #ff0 url(../img/cube.jpg) center top no-repeat;
padding-top: 180px; /* img height + some padding */}

#left-nav ul {
border-top: 1px solid #fff;

}

<div id="left-nav">
<ul><li><a href="http://www.fuzzcube.co m/index.php?id=1" >Home </a></li>
...
</ul>
</div>

Likewise, use the silhouette as a background image for the #bodytxt
area. Apply padding right to keep the text clear of the image. No need
for an empty div for this.

--
Berg
Berg

Right, cut as much of the cr*p code out as much as I can (correct me
if I have missed any).

I don't really want to remove the height of the content pane (white
box) as the whole design of the site is that it all sits in that box
in the centre. If anything, I would want the overflow on the bodytext
div to scroll if necessary.

If there any way of doing this it would be great, if not, back to the
drawing board!!

Also, now I have removed the heights, the right image and bgcolour of
the left nav do not fill the whole content pane anymore. Any ideas on
how to fix this?

Cheers

Paul
Jun 27 '08 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
24741
by: Richard | last post by:
I am filling a TEXTAREA with text and links from a database. I need to display the <a href....> code in the TEXTAREA as a clickable link with _blank targetting. I realise I could simply use a TD but a closed table design and limited space require me to scroll the data loaded from the database. I need to avoid LAYERS for the sake of cross browser compatability (some 3rd world users) so would really like to stick to the TEXTAREA.
5
2469
by: D. Alvarado | last post by:
Hello, DOes anyone have a recommendation for some free code to send out HTML-formatted emails? The code does not have to be cross-browser compatible. Thanks for any advice, - Dave
7
4732
by: Jonas Smithson | last post by:
Hello all, I have an absolute positioned parent div, and nested inside it is an absolute positioned child div -- I mean the div *code* is nested inside, but the child is physically positioned so that it's completely outside the parent div (to the left of its parent, in a left-side margin area). The child div contains hyperlinks. Explorer 6 (on Windows) has no problem with this. However, in Netscape 6, the links are unclickable. I...
4
3434
by: frogman042 | last post by:
My daughter is playing around trying to learn JavaScript and she wrote a small program that prints out a message in increasing and decreasing font size and color changes. She is using document write and it works fine until she puts it into a function and then calls the function from a button with onClick. This also seems to work OK, with the exception that the page is cleared, and the curser changes (and stays) as an hourglass. In...
2
3511
by: Steven T. Hatton | last post by:
I'm still not completely sure what's going on with C++ I/O regarding the extractors and inserters. The following document seems a bit inconsistent: http://gcc.gnu.org/onlinedocs/libstdc++/27_io/howto.html#1 Copying a file: WRONG WAY: #include <fstream> std::ifstream IN ("input_file"); std::ofstream OUT ("output_file");
3
1339
by: Clint MacDonald | last post by:
Hello, I am trying to create a small application that creates labels and I have purchased a thermal transfer label printer. Now I need to be able to print the formatted label to the printer without the browser header/footer and without margins or borders.... Any starting ideas or links to resources that may help me... Thanks Clint
3
2325
by: Aaron Gray | last post by:
I need to print formatted decimal numbers to a set number of decimal places. Is there a way to do this with JavaScript ? If not is there any existing/"library" functions to do this ? Many thanks in advance, Aaron
3
1676
by: Chris F.A. Johnson | last post by:
On 2008-05-25, mehstg1319 wrote: .... What if my window is less than 500px high? Like many people, I find having to scroll sections of a page annoying, but you can do it with: overflow: auto; --
1
4597
by: robnoper | last post by:
XP SP2, access and outlook 2003 I have a form with 3 command buttons on that when one is pressed it opens up a html email for the user to send. Two of the emails work fine and open with the full colour and size formatted text but one of them just shows the html code in the body with no formatting. The vba code for the command button is as follows: Private Sub cmdUpdateEmail_Click() Dim HTMLReminderEmail As String Dim Subject As String...
0
9607
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10407
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10424
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10140
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9224
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7684
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5706
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4358
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3030
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.