You need a font containing Unicode dice characters to see this demonstration as intended, e.g. Symbola, Code2000, or DejaVu Sans.
View the source code of this page to see how the demo has been implemented. The JavaScript code is directly embedded into the HTML document.