Search code examples
cssmenubardrop-down-menu

Twitter-style user account down arrow


I would like to replicate the down arrow that appears next to a username on several sites such as Twitter.

Twitter

I believe there are two ways of doing this: create a down arrow image and set it as some sort of background image, or use CSS to create the arrow. I believe Google uses the CSS approach for their top bar.

Which option is preferred and how would I go about doing it?


Solution

  • Twitter is using the ↓ html entity (appending it with css content property). In combination with an image sprite, see here: http://jsfiddle.net/HAZGr/

    enter image description here

    My advice would be to use an image, it keeps it simple and that way you know it will look the same on all browsers.