WordPress.org

Ready to get started?Download WordPress

Forums

Leaf
Fixed size for image header? (2 posts)

  1. edonl
    Member
    Posted 11 months ago #

    Hi,

    Is it possible to give the header image a fixed size for all devices? It looks like on tablets and smartphones the image is resized to a bigger width which makes it look unsharp.

    Tx!

  2. W.P. Ginfo
    Member
    Posted 11 months ago #

    It's a good idea to be aware of the following when designing for multiple devices:

    When using fixed values, the site may not display as required.
    Whenever possible it's a good practice to use 'relative values'.
    This results in a set of values that start with the device's default and varies from that device-default as / when set in the css.

    EXAMPLE

    Reset:
    * {font-size:1em;
       margin:0;
       padding:0;
       clear:all;
    }

    Then for the elements:

    h1{font-size:2em;}
    h2{font-size:1.6em;}
    h3{font-size:1.2em;}
    p{font-size:1em; line-height:1.05em;}

    layout:

    #wrapper{width:100%;}
    #content{width:67%;}
    #aside{width:30%}
    etc.

    Result is that each device will calculate a value, suitable for that device, instead of using a fixed value it has difficulty displaying.

    Is the result always good?
    Well no! This is the internet ;) Life is messy...

Reply

You must log in to post.

About this Theme

About this Topic