JQuery : ساختن يك پنجره‌ی Dialog برای صفحات وب با قابليت جابجايی

• برای ساختن چنين پنجره‌ی محاوره‌ای، ابتدا سه فايل زير را دانلود كرده و در محل ذخيره‌ی فايل HTML قرار دهيد.

jquery-ui.js
jquery-1.9.1.js
jquery-ui.css

• سپس كدهای زير را در صفحه‌ی HTML كپی كنيد ...

<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8" />
<title>jQuery UI Dialog - Default functionality</title>
<link rel="stylesheet" href="jquery-ui.css" />
<script src="jquery-1.9.1.js"> </script>
<script src="jquery-ui.js"> </script>
<script>
$(function() {
$( "#dialog" ).dialog();
});
</script>
</head>
<body>
<div id="dialog" title="Basic dialog">
<p>This is the default dialog which is useful for displaying information. The dialog window can be moved, resized and closed with the 'x' icon.</p>
</div>
</body>
</html>

دانلود سورس اين آموزش - اندازه‌ی فايل : 171 كيلوبايت - (نمايش نمونه كار)