JSFiddle - React, Tailwind, and code Playground
HTML
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8 />
<title>dialog buttons badly handled with JQuery 1.3.2</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jqueryui/1.8.11/jquery-ui.min.js"></script>
<link rel="stylesheet" href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.11/themes/smoothness/jquery-ui.css" type="text/css" />
</head>
<body>
</body>
</html>
JavaScript
jQuery(function() {
jQuery('<p>The button below should be labelled "Ok".</p>').dialog({
buttons: {
'Ok': function() { jQuery('<p>This should not appear until you press the "Ok" button in the dialog box.</p>').appendTo('body'); }
}
});
});