Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums CSS IPhone browser resolution / div problem Reply To: IPhone browser resolution / div problem

#169108
JamesBarnsley
Participant

Ok,

I cannot do this with width and height of 100%. I have different stylesheets for different phone resolutions. This stylesheet I am doing now is for the IPhone 5.

The specs say IPhone 5 has a resolution of …

1136px by 640px

But when using this code and viewing it in the IPhones browser …

html {

    height: 1136px;
    width: 640px;
    border: 1px solid white;

}

The white box it produces is smaller than the viewport area. About 1 third smaller each way, width and height.

“Doesn’t the iPhone 5 have a viewport size of 320×568? ”

It might do, but then why is the white box smaller and not larger than that area?

It is strange.

James.