Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Sep 2006
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    How can I define the size of line breaks?

    Hello, I'm trying to format my site to work better with browsers other than Internet Explorer. One of the things I noticed is that different browsers seem to interpret the <br> tags differently, or at least the amount of space they consist of. I was wondering if it's possibly to specify the height of a line break using css to a certain number of pixels that'd display similar results with different browsers. Any help would be greatly appreciated. Thanks.

  • #2
    Senior Coder coothead's Avatar
    Join Date
    Jan 2004
    Location
    chertsey, a small town 25 miles south west of london, england.
    Posts
    1,736
    Thanks
    0
    Thanked 241 Times in 236 Posts
    Hi there JoshF,

    and a warm welcome to these forums.

    You have at least 85 errors that need to be attended to....
    ....before it is posible to address your problem.

    coothead

  • #3
    New to the CF scene
    Join Date
    Sep 2006
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks for the reply.

    Okay, I've gotten a practice page to 54 errors is that good enough?

    For some reason when I look at this page in Firefox now the main content frame doesn't stretch to the bottom of the screen.

    I don't know if this matters but the page is shtml not xhtml.

  • #4
    Regular Coder
    Join Date
    Sep 2006
    Location
    Vermont, USA
    Posts
    154
    Thanks
    0
    Thanked 6 Times in 6 Posts
    Try adding something like:

    html, body{
    height:100%
    }

    to your styles. I haven't looked at your page, but this may help.
    Active PHP/MySQL application developer available for immediate work.
    syosoft.com mavieo.com - Remote Web Site Administration Suite - Reseller Ready

  • #5
    New to the CF scene
    Join Date
    Sep 2006
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    That's whats weird, I already have that, and it seems to work in IE but not Firefox.

  • #6
    Senior Coder Arbitrator's Avatar
    Join Date
    Mar 2006
    Location
    Splendora, Texas, United States of America
    Posts
    3,372
    Thanks
    32
    Thanked 286 Times in 280 Posts
    Quote Originally Posted by JoshF View Post
    One of the things I noticed is that different browsers seem to interpret the <br> tags differently, or at least the amount of space they consist of.
    The size of line-breaks is relative to either the font size, the line-height, or both. If the font size varies, of course, the size of line-breaks will vary too. If you're using line-break elements to do anything other than break some text to the next line, i.e., using them to create vertical space, then you shouldn't be though; margin, padding, and other CSS properties are more suitable for that.

    Quote Originally Posted by JoshF View Post
    Okay, I've gotten a practice page to 54 errors is that good enough?
    Considering how easy most of those errors are to fix I don't see why you shouldn't take the trouble. You're using deprecated attributes; missing required attributes; have unescaped ampersands; have attribute values that are not delimited by quotation marks (invalid XHTML); have unclosed elements (again, invalid XHTML); and have elements that don't exist under the XHTML 1.0 Strict DTD (iframe, font). It looks like there's also some ineffective JavaScript; why would you use JavaScript to document.write a reference to more JavaScript? Then again that poorly written script and the iframes may be the fault of some poorly engineered ad-insertion by your host, in which case you can't be blamed. I would at least switch to a transitional doctype so that the iframes, and other code which you may be required to have, are valid though.

    Quote Originally Posted by JoshF View Post
    For some reason when I look at this page in Firefox now the main content frame doesn't stretch to the bottom of the screen.
    Your problem in Firefox may be related to the fact that Firefox is rendering your page in quirks mode. I'm not sure why though since the doctype declaration that you're using (XHTML 1.0 Strict) should be activating standards-compliance mode. Maybe it has something to do with this SHTML thing? You can find some more information about layout modes at http://hsivonen.iki.fi/doctype/.
    For every complex problem, there is an answer that is clear, simple, and wrong.


  •  

    Posting Permissions

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