Solved

How to center my dialog window inside a div?

Posted on 2013-05-10
2
183 Views
Last Modified: 2013-05-13
Hello guys

I have a div that is the container of my html code. Something like this:

body
  <div id="container">
     all my html code is here
   
  </div>
</body>

Open in new window


When I call the dialog, I want it to open in the center of the div container

I use dialog Widget, this code

http://api.jqueryui.com/dialog/#option-position

How can I do this?
0
Comment
Question by:hidrau
2 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
Comment Utility
.dialog({ position:  { my: "center", at: "center", of: "#container" } });
0
 
LVL 1

Author Closing Comment

by:hidrau
Comment Utility
thanks very much friend
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

I found this questions asking how to do this in many different forums, so I will describe here how to implement a solution using PHP and AJAX. The logical flow for the problem should be: Write an event handler for the first drop down box to get …
Introduction JSON is an acronym for JavaScript Object Notation.  It is a text-string data transport mechanism, capable of representing simple or complex data structures in a consistent and easy-to-read manner.  Similar in concept to XML, but more e…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now