You can provide any HTML as a title parameter, for example:
$("#dialog").dialog({ title: '<img src="myImage.jpg" />' });
Here you can see an example.
Or, as another demo, to annoy the hell out of your users, you could do this :
$("<div />").dialog({ title: '<marquee>Hello</marquee>' });
source share