It depends what you want to do. If you have a Wordpress blog there are plugins which do a great job of doing this for you. If you have a custom HTML site then I think these options would be a bit hit and miss. The key thing is whatever you use, it shows the information that you need to display. This is why a custom solution is sometimes better.
You could use something like this to detect and redirect users. This solution uses PHP.
http://detectmobilebrowsers.mobi/
Another consideration is that recently JS Frameworks have started to support mobiles which present a load of new options for phones.
http://jquerymobile.com/