I am trying to add a simple compact fshare button on my website. The only code I found was this one:
<div style="float:left;padding:4px;">
<a expr:share_url='data:post.url' name='fb_share' rel='nofollow' type='button_count'/>
<script type="text/javascript" src="http://static.ak.fbcdn.net/connect.php/js/FB.Share"/>
</div>
Which should render as

But it is not redering correct. It seems it is trying to create multiple buttons and “crashes” all the page. It corrupts the HTML, change the background of a entire div and so on…

Why is that? Is this the correct code?
Facebook is not recommending the use of the share button anymore, instead you should use the like button. Here is what they say on their website:
With the like button, you can add it using javascript OR iframe, so you can see which one works best for you. Read more about the like button here.