Archive for March, 2009

jpg not displaying in nokia browser

March 30, 2009

Ok so I’m doing a mobile website. When my application receives a GET request for an image, it uses wurfl to check the User-Agent header and figure out what phone the user has, then resizes the image accordingly (with caching, obviously).

It seemed to work fine on every phone in the office except my own – on mine (a basic nokia 2600) the image seemed to download, but just wouldn’t display (I was left with a correctly-sized blank instead). I could see the image was being generated and cached, and I could even save it on the phone, but when I tried to look at it it wouldn’t display.

Discovered it worked ok for gifs, and eventually I figured out the problem was jpeg image interlacing. The phone doesn’t seem to support it – turned it off and it works fine.

Advertisements

li bullets displaying in wrong place in IE

March 13, 2009

If the bullets are showing at the bottom rather than the top of your list items in Internet Explorer and ok in Firefox, then most likely your <li> items have a property called “layout”. The hasLayout property gets set by IE depending on the css and can’t be changed directly – the few times it’s happened to me (with css written by someone else), I’ve fixed it by removing “li { display: inline-block; }” from the css.

You can find a detailed explanation of the hasLayout property on http://www.satzansatz.de/cssd/onhavinglayout.html