2012-12-05 52 views
1

我是JQuery的新手。我需要弹出消息框使用JQuery。请帮助如何做到这一点,或请给我提供链接,我如何获得这个。使用jquery弹出消息框

我正在使用梅西,但我无法得到所需的结果。

<html xmlns="http://www.w3.org/1999/xhtml"> 
    <head runat="server"> 
    <title></title> 
    <link rel="stylesheet" href="files/messi.min.css" /> 
    </head> 
    <body> 
    <script src="files/messi.min.js">  
     new messi('This is a message with Messi.', { title: 'Title' }); 
    </script> 
    <form id="form1" runat="server"> 
    <div> 
     <asp:Button ID="Button1" runat="server" Text="click" /> 
    </div> 
    </form> 
    </body> 
</html> 
+0

这里是什么梅西?它是一个jQuery插件,你正在使用? – ryadavilli

+0

@ryadavilli你提到https://github.com/marcosesperon/Messi – Nirmala

回答

4

您可以轻松通过使用jQuery用户界面做了。

HTML

<a href="#" id="contactUs">Contact Us</a>     
<div id="dialog" title="Contact form"> 
    <p>appear now</p> 
</div> 

您需要初始化对话框

$(function() { 
    // this initializes the dialog (and uses some common options that I do) 
    $("#dialog").dialog({autoOpen : false, modal : true, show : "blind", hide : "blind"}); 

    // next add the onclick handler 
    $("#contactUs").click(function() { 
    $("#dialog").dialog("open"); 
    return false; 
    }); 
}); 

大链接对话框弹出式菜单Link 1 另外一个Link 2

我从Here得到这个

希望这会有所帮助。好运。