SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Wizard
    Join Date
    Aug 2002
    Location
    N.Ireland
    Posts
    1,046
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Divs workaround needed

    I'm working on this site http://www.boundarycommission.org.uk/test/index.asp using divs for my layout. The pages render fine in IE, Moz and Opera but not Netscape.
    Problem 1 - in Netscape it's not recognizing the width, is there any kind of work around?
    Problem 2 - if my content is only a couple of lines eg http://www.boundarycommission.org.uk...blications.asp the footer image renders in the wrong place. I can get round this by specifying the div height to force it where it should go but then if I do that in Mozilla, where a page is longer than the height it renders the footer at the bottom with the content carrying on underneath - eg http://www.boundarycommission.org.uk...statistics.asp

    How can I work around these two problems?

  2. #2
    ☆★☆★ silver trophy vgarcia's Avatar
    Join Date
    Jan 2002
    Location
    in transition
    Posts
    21,235
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)
    Which netscape?

  3. #3
    Team SitePoint AlexW's Avatar
    Join Date
    Apr 2000
    Location
    Melbourne
    Posts
    832
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Daz
    I'm working on this site http://www.boundarycommission.org.uk/test/index.asp using divs for my layout. The pages render fine in IE, Moz and Opera but not Netscape.
    Problem 1 - in Netscape it's not recognizing the width, is there any kind of work around?
    Problem 2 - if my content is only a couple of lines eg http://www.boundarycommission.org.u...ublications.asp the footer image renders in the wrong place. I can get round this by specifying the div height to force it where it should go but then if I do that in Mozilla, where a page is longer than the height it renders the footer at the bottom with the content carrying on underneath - eg http://www.boundarycommission.org.u.../statistics.asp

    How can I work around these two problems?

    IF you're talking about NS4, you're in for a bit of a battle.

    Two tips with NS 4.
    It works better with classes better than IDs for some reason.
    It freaks out with inline styles more than linked or head based styles.
    Alex Walker
    SitePoint Developer
    SitePoint - Learnable

  4. #4
    SitePoint Wizard
    Join Date
    Aug 2002
    Location
    N.Ireland
    Posts
    1,046
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Sorry guys, I should've said, yep its NS4.7 To be honest tho I'm more concerned about the problems with Mozilla and when I try to specify a div height. IE and Opera are fine with it, they force the height rendering the footer below the menu but Mozilla places the footer after where the div height ends and the content carries on underneath it.

    Of course I could increase the div height but that would be pointless as some pages will be longer/shorter than others.

  5. #5
    Team SitePoint AlexW's Avatar
    Join Date
    Apr 2000
    Location
    Melbourne
    Posts
    832
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    With problem 1, what I said above applies.

    The only Netscape 4 CSS layouts that work (and there are a few out there) seem to force you to make all sorts of structural and semantic compromises to make them work, which sort of defeats the purpose. One of the great things about CSS-P is the underlying documents have a structure that imbues them with much more meaning than normal, table-based layout.

    Problem 2 is probably the #1 layout issue with CSS layout: Making sure the footer renders below the content columns, regardless of what is in them. There are a handful of ways to approach this.

    The solution we used with SitePoint was:
    1. Use javascript to determine the heights of both the nav and main column.
    2. Compare the column heights and if the main column is shorter, overwrite it's DIV height with that of the nav column.

    We used Mike Foster's DHTML X library to do this sort of stuff, mainly because if works identically across IE, NS, Opera and Mozilla (Konquerer and Mac's Safari are an issue still). After linking the 'x.js' library, getting the columns heights is as simple as 'var col1h = xHeight("col1" );'


    Pretty reliable method, and only ever misses when the user has Javscript turned off AND the nav column is longer than the main body content (fairly rare occurances similtanaeously).
    Last edited by AlexW; Mar 16, 2003 at 17:59.
    Alex Walker
    SitePoint Developer
    SitePoint - Learnable


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •