JQUERY MODEL DIALOG POSITION NOT FIXED

Takeshi Okada

Total Post:89

Points:629
Posted by  Takeshi Okada
 2833  View(s)
Ratings:
Rate this:

Hi Everyone!

I'm working on MVC 4 project. In this project I have used model dialog that provide by MVC 4. This model dialog scroll with screen. I want to fixed model dialog in screen center.

I have used below line of css and jQuery.

 <link href="@Url.Content("~/Content/themes/base/minified/jquery-ui.min.css")" rel="stylesheet" type="text/css" />
 <script src="@Url.Content("~/Scripts/jquery-1.7.1.min.js")" type="text/javascript"></script>
 <script src="@Url.Content("~/Scripts/jquery-ui-1.8.20.min.js")" type="text/javascript"></script>

Please help me!

Thanks in advance!

  1. AVADHESH PATEL

    Post:604

    Points:4228
    Re: JQuery model dialog position not fixed

    Hi Takeshi!

    If I'm right, then you are using MVC JQuery and CSS for creating this model popup.
    Hence, for fixing position of model popup, open "jquery-ui.min.css" file from Content\themes\base\minified folder and change ".ui-dialog" class position

    absolute to fixed as following.

    .ui-dialog
    {
    position: fixed;
    }

    I hope it resolve your problem.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!