Coding Kuuro Javascript

Reset jQuery UI Dialog Position on Open

If you have a jQuery UI dialog and wanted to reset its position every time the dialog is re-opened, you can add custom function to reset its position in the open event. This can be useful if you use the close method to close the dialog instance and intend to re-use the dialog box without re-initializing it again, i.e:  myCustomDialog.dialog("open") , as the instance is not removed and the next time you re-opened the dialog its last position will be retained to the position before you close the dialog box.