To expand on toomanyairmiles' answer, geo-IP-based language detection can cause problems for certain people (e.g. travelers, those choosing to browse the web using a non-local language, and regions with multiple local languages). You can pick up cues from the Accept-Language header, which can even supply multiple preferred languages, but this only tells you what language the browser and possibly the OS is in (the user could be on a public computer).
It's better to use user behavior to detect language. So instead of automatically switching languages, you simply create different subsites (en.example.com, fr.example.com, cn.example.com, etc.) and let the search engines handle it. If the user's primary language is French, they'll probably be searching from Google France, which will show them the French site. If they're using Google US in France, then that tells you they probably still want to browse in US English.
What you could do is use Geo-IP and/or Accept-Language to suggest alternate languages to the user just in case—so long as you don't force it on them. A good way to do this might be surface a "translate to $lang" link in the header or reorder the languages menu based on suspected user language(s).
Any hosted CMS that supports multilingual sites can be used for behavior-based language selection. To access the Accept-Language header or use Geo-IP, you typically need server-side scripting access, which pretty much no hosted CMS allows, though there's no reason why a JavaScript-enabled web service couldn't supply this capability.