I am working with JQueryUI and Asp.net and encounter a dynamic content problem:
<div id="content" title="" style="color: #F7A356">
<%=ContentLabel.Text%>
</div>
function OpenDialog() {
// alert(document.getElementById("content").innerHTML);
var $dialog = $('<div style="color: #F7A356"></div>')
.html($("#content").text())
.dialog({
autoOpen: false,
modal: true,
height: 150,
});
$dialog.dialog('open');
}
I would like to open a dialog when I click on a control and show the content.. but it failed with the above method....
it doesn't work even I just some a simple javascript alert function with the innerHTML.....It return nothing as well