Here you go:
var items = document.getElementById( 'items' ), divs = document.getElementsByClassName( 'count' ); [].slice.call( divs ).forEach(function ( div ) { div.innerHTML = items.innerHTML; });
Live demo: http://jsfiddle.net/MGqGe/
I use this [].slice.call( divs ) to convert a NodeList to a regular array so that I can call it forEach .
Btw, be careful with innerHTML . I personally would use a library (e.g. jQuery) to clone the content.
source share