Reputation: 13436
Trying to use jQuery dialogs, but they don't seem to load :(
HTML:
<p><a href="javascript:void(null);" onclick="showDialog()">Open</a></p>
<div id="dialog-modal" title="Basic modal dialog" style="display: none;"></div>
Javascript:
function showDialog()
{
alert('Alert not showing');
$("#dialog-modal").dialog(
{
width: 600,
height: 400,
open: function(event, ui)
{
var textarea = $('<textarea style="height: 276px;">');
$(textarea).redactor({
focus: true,
autoresize: false,
initCallback: function()
{
this.set('<p>Lorem...</p>');
}
});
}
});
}
Another example:
What's the problem here ?
Upvotes: 0
Views: 84
Reputation: 10994
First of all you have to include jQuery UI
for dialog to work. In JSfiddle you have to include your functions
in head
. But better yet use jQuery's click()
.
Upvotes: 0
Reputation: 6141
.click(...)
from jQuery : http://jsfiddle.net/techunter/Kat7G/Upvotes: 0