Creating an element and attaching it dynamically to the DOM - creating dynamic html

Creating an element and appending it to the DOM - dynamic html - the principle

function php
CLICK the button below (sneak peek) to peek at the code.
//no Jscript, no loading time
submit to reddit

Sneak peek of the server side code