The other answers show you how to add the button, but not how to get jQuery Mobile to enhance it.
If you are using jQM 1.4, call enhanceWithin()
on the container:
var content = '<button data-icon="delete">Delete</button>';
$("#box1").append(content).enhanceWithin();
If you are using 1.3, call button()
on the button object:
var content = '<button data-icon="delete">Delete</button>';
$("#box1").append(content);
$("#box1 button").button();
NOTE: in my example I use append()
to add the content, you can still use html()
if you prefer.