Yes, and they serve important function -- leveling the playing field in case of strong imbalance between the parties.
Consider for example employment -- in many cases, employers have stronger bargaining position against singular employees or candidates, and could strong-arm individuals into one-sided deals. Thus most countries have certain degree of regulation of employment, providing some basic standard for the employment deals.
Having said that, I still can't reconcile with the idea of every website being subject to local laws of every country it is accessed from, merely by the fact that somebody visited the site from within this particular country.
In case of using a website, the active party is the user, and the website operator is the passive party. If anything, local law should bind the users, not the operators.
How about the German government went instead, ``Under penalty of XYZ, citizens ((of Germany)) may not use social networking website which require disclosure of real names as a precondition''? While this apparently puts pressure on users alone, Facebook would have to weight the real-name policy vs. losing a large, country-wide market.