简体   繁体   中英

Pop-up window while creating a webpage

I'm using Visual Studio 2010, and i'm creating a website using C#. I'm opening a pop-up when user clicks a button.

Now i want to perform the task mentioned below:

  • When a pop-up opens i do not want user to click anywhere else. I mean he should be able to click or do any activity in the pop-up window ONLY, whereas he shouldn't be able to do anything in the parent window until and unless he closes the pop-up.

How to achieve this?

Depends on how you are creating the website. C# is the server-side language and can be used in ASP.Net websites as well as MVC.

If ASP.Net, Ajax Control Toolkit has a modal popup:

http://www.asp.net/ajaxlibrary/ajaxcontroltoolkitsamplesite/modalpopup/modalpopup.aspx

If MVC, jQuery has a modal popup:

http://jqueryui.com/dialog/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM