Saturday, April 11, 2009

Dynamic Website Gotchas

List of things I found out trying to create xsiding.com, when I chose to eschew flash and go with fancy DHTML.
  1. ie7 has some problem with embedded sound, so use SoundManager2 (a javascript triggered flash player) to do your sounds reliably.
  2. Firefox doesn't allow negative z-index settings if you put it on a css class. Instead use an id (#layeredDiv) and you are OK.
  3. Firefox doesn't like backgroundPositionX or Y (which is actually correct since it is some IE monstrosity that Safari implements as well). You have to use backgroundPosition and set both x and y.
  4. Everyone is ok with .cur files for custom cursors, so don't bother trying png or something else. A .cur file is just an .ico file renamed. Works great with the .ico Photoshop plugin. Actually has better transparency than gif.
  5. Conditional ie code using the [if IE] or [if IE 6] thing can be very helpful since css positioning is frequently off on IE. You can improve the situation by turning off quirks mode with a strict doctype.
  6. If you set the target="_top" on an href with an onclick handler, IE ignores the onclick (IE 6,7,8)
More to come as I hit em... Notice I don't have any complaints about Safari. If anything they seem to really try to be compatible with everything... Great job Apple!

0 comments: