0
<!DOCTYPE html>
<html>
<head>
<title>jQuery Dialog Example</title>
<link rel="stylesheet" href="https://code.jquery.com/ui/1.11.0/themes/smoothness/jquery-ui.css">
<script src="https://code.jquery.com/jquery-1.10.2.js"></script>
<script src="https://code.jquery.com/ui/1.11.0/jquery-ui.js"></script>
</head>
<script>
$(document).ready($(function() {
//Dialog box
$("#dialog").dialog({
autoOpen: false
});
//button to open dialog box
$("#button").click(function(event) {
$("#dialog").dialog("open");
});
});
</script>
<body>
//div containing info about the dialog box
<div id="dialog">
<p>This is supposed to be a calculator</p>
</div>
<input id="button" type="submit" value="Open">
</body>
</html>
只是一個友情提示,您可能需要閱讀過此頁: [The How-To-Ask Guide](https://stackoverflow.com/help/how-to-ask),這樣你就可以確保你的問題很容易回答並且儘可能清楚。一定要包括你爲解決你遇到的問題所做的任何努力,以及當你嘗試修復這些問題時發生了什麼。另外不要忘記你的顯示代碼和任何錯誤信息! –
當我發佈另一個問題時,我意識到自己的錯誤。感謝提示,這個錯誤不會再發生。 –
不要難過。我們是一個很好的社區,可以幫助您學習並幫助解決您的問題。沒有人會因爲你犯了一個錯誤而生氣。我們都在這裏幫助您解決錯誤!歡迎來到社區 –