android - My website doesnt scale properly on Iphones -


i'm designing responsive website , works on devices. use 2 different resolution monitors, lenovo tablet, , 2 android phones (galaxy s4 , sony xperia). on these looks great

galaxy screenshot

sony screenshot

however, on iphones, layout breaks in 2 ways.

  1. the menu doesnt scale last option 'contact' breaks new line. doesnt on other phone, why on iphones?

iphone screenshot of menu

  1. it creates blank line on right side of site. cant explain here screenshot

iphone screenshot of blank bar

it both these issues on iphone 4 simulator dont think 1 phone im testing on.

here link website

here view port im using

<meta name="viewport" content="width=device-width, initial-scale=1"> 

what causing this?

edit - media queries using

    /*center logo when on mobile*/     @media , (min-width: 0px) , (max-width: 989px){         #logo{             text-align:center;         }     }             /*add margin top on desktops*/             @media , (min-width: 990px){                 #navigationpages li{                     margin-top:25px;                 }             }              /*remove margin top when on mobile*/             @media , (min-width: 0px) , (max-width: 989px){                 #navigationpages li{                     margin-top:5px;                 }             }                /*change font size of navigation on mobile*/             @media screen , (max-width: 468px) {                 #navigationpages li {                       font-size: .85em;                 }                 #navigationpages li {                      padding: 0.75em 0.6em;                 }             }      /*float icons right on medium sized screens*/     @media , (min-width: 628px) , (max-width: 989px){         #headericons img{             display:block;             float:right;             margin-left:15px;          }     }       /*float left again phones*/     @media , (min-width: 0px) , (max-width: 627px){         #headericons img{             display:block;             float:left;             margin-left:15px;          }     }                      /*change font size of navigation on mobile*/                 @media screen , (max-width: 814px) {                     #citybackground p {                     font-size: 25px;                     text-justify:inter-word;                     }                 }             /*change font size of navigation on mobile*/                 @media screen , (max-width: 623px) {                     #citybackground p {                     font-size: 17px;                     text-justify:inter-word;                     }                 } /*reduce button sizes on mobile*/ @media , (max-width: 989px){     #buttonholder img{         width:30%;         display:block;         margin-left: auto;         margin-right: auto;     } }   /*center icons on mobile*/ @media , (min-width: 0px) , (max-width: 989px){     #icon1 img{          display:block;         margin-left:auto;         margin-right:auto;         min-width:162px;     } }       /*center titles on mobile*/     @media , (min-width: 0px) , (max-width: 989px){         .whowhatwhytitles{            text-align:center;            margin-top:25px;            font-size:32px;            margin-right:35px;         }     }       /*remove padding of text on mobile*/         @media , (min-width: 0px) , (max-width: 989px){             #whoweare p{                 margin-top:5px;                 font-size:20px;                  padding-left:0;                 width:99%;                 text-align:center;              }         }       /*remove padding of text on mobile*/         @media , (min-width: 0px) , (max-width: 989px){             #whatwedo p{                 margin-top:5px;                 font-size:20px;                 padding-left:0;                 width:99%;                 text-align:center;              }         }       /*remove padding of text on mobile*/         @media , (min-width: 0px) , (max-width: 989px){             #whychooseus p{                 margin-top:5px;                 font-size:20px;                  padding-left:0;                 width:99%;                 text-align:center;              }         }       /*remove padding of text on mobile*/         @media , (min-width: 0px) , (max-width: 623px){             #footerthin p{                 margin-left:0;             }         }  

what's going on

the reason screen going wide header isn't changing @ all. why it's going off screen on iphone shot. news don't need media query @ all. can set have max-width of 100% of screen. add code below stylesheet , let me know if fixes it.

code

css:

#logo img {     max-width:100%;     height:auto; } 

css alternative 1: (this give little bit of padding on each side).

#logo img {     max-width:96%;     margin:0 auto;     height:auto; } 

screenshots

current:

enter image description here

with new css:

enter image description here

with alternative css:

enter image description here

also, need add height:auto learn more , started buttons, prevent them being stretched.

edit comments

you asked menu going 2 lines. if change padding, should fix that.

current css:

#navigationpages li {     display: block;     padding: 0.75em 1.5em; } 

working css:

#navigationpages li {     display: block;     padding: 0.75em 1em; } 

Comments

Popular posts from this blog

basic authentication with http post params android -

vb.net - Virtual Keyboard commands -

How to get multiresult with multicondition in Sql Server -