height attribute

Discussion in 'CSS' started by drew68, Jun 17, 2014.

  1. #1
    not sure where the height is being specified in my css. I'm not specifying the height but for some reason, every page has a height attribute…for example this page http://papanastasatoschristos.wp.hobbsherder.com has a height of 1232px;

    where is this coming from???
     
    drew68, Jun 17, 2014 IP
  2. COBOLdinosaur

    COBOLdinosaur Active Member

    Messages:
    515
    Likes Received:
    123
    Best Answers:
    11
    Trophy Points:
    95
    #2
    With all the crap that is stuffed into it and the 35 validation errors the height could coming from anywhere but it looks like the body height is set to 100% in the style.css file. However the scripting junk could be changing it and it would not show in the inspector. The page looks alright for a cookie cutter WP site, but technically is is crap and the code needs some serious repair, because junk like that will jump up and bite you every time you touch it.
     
    COBOLdinosaur, Jun 17, 2014 IP
  3. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #3
    It almost sounds like you are assuming height has to be declared, when in GOOD layouts it isn't...

    NOT that that's a good layout with the fixed width, fixed metric (px) fonts, design elements not really compatible with modern layout concepts like responsiveness, and markup that -- to be brutally frank -- is a relic of late '90's methodologies that should be tossed in it's entirety.

    Though, what are you trying to accomplish? What are you using to find out the element has a 'height' attribute? If you're using firebug, dragonfly or some other 'element inspector' every object will report a 'height' in the calculated section, even when set to auto; that's just telling you what it is, NOT what's declared as a style.
     
    deathshadow, Jun 17, 2014 IP
  4. drew68

    drew68 Well-Known Member

    Messages:
    582
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    128
    #4
    wow…a bit taken back by the criticism. i get it…the 35 validation errors are minor errors that i'll fix up. thnx for bringing that to my attention.

    i just want that height not to interfere.
     
    drew68, Jun 18, 2014 IP
  5. drew68

    drew68 Well-Known Member

    Messages:
    582
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    128
    #5
    i fixed it. specified html height to be 75% instead of at 100%
     
    drew68, Jun 18, 2014 IP
  6. COBOLdinosaur

    COBOLdinosaur Active Member

    Messages:
    515
    Likes Received:
    123
    Best Answers:
    11
    Trophy Points:
    95
    #6
    Why would you be surprised that junk gets criticized? Most people looking for help in forums are hoping to find an experienced professional to help them, but experienced professionals have a very low tolerance for code that has been slopped and trashed. It is for your benefit. Either you have enough pride in your work to learn how to do it right; or you don't care. If you don't care; why should we care?

    I've been programming for 50 years, and one of the first things I learned was "garbage in; garbage out". If you want to spend, hours, days, weeks screwing around with problems that should be a 5 minute fix then don't worry about, errors, best practices or standards;technical quality is probably overrated anyway.
     
    COBOLdinosaur, Jun 19, 2014 IP
    kk5st likes this.
  7. kk5st

    kk5st Prominent Member

    Messages:
    3,497
    Likes Received:
    376
    Best Answers:
    29
    Trophy Points:
    335
    #7
    Generally speaking, if you have to specify a height without compelling prior reason for doing so, you've likely already screwed up. If it's required to 'fix' something, you definitely screwed something up.
     
    kk5st, Jun 22, 2014 IP