Detect screen size?
How do I detect and use a phone's screen size?
I want to have two different versions of my website -- one for small cellphones and one for large ones, but I don't know how to about desiging that.
You can't detect screen size
You could use UA Profiles but it is very complicated to discover a mobile has a 128x128 screen resolution.
And IF you find that out.
It does not indicate the addressable size of the browser window.
It does not tell you how much text you can fit on the screen.
It tells you very little.
Just make sure your homepage is to the point.
Device INDEPENDENT. Not dependent. You should never create two versions of the same content.
Mine looks fine in any standards compliant browser.
Beside UAPRof you can also use WURFL
A WURL record will also tell you about the usabel screen width in the display section for a specific device
btw. I would not agree, that developing differnet versions for different device classes is a bad idea.