Link to home
Start Free TrialLog in
Avatar of curiouswebster
curiouswebsterFlag for United States of America

asked on

jquery: Need to position this pop-up

I have a jquery plug-in which creates a pop-up thusly:

 $('<div>',
                                                {
                                                    'class': 'modal-body config-selector-dialog-body',
                                                    'append': [
                                                        $('<div>',
                                                                {
                                                                    'class': 'alert alert-danger cs-confirm-save cs-confirm',
                                                                    'append': [
                                                                        $('<span>',
                                                                            {
                                                                                'text':
                                                                                    'Would you like to save your changes? '
                                                                            }),
                                                                        $('<a>',
                                                                            {
                                                                                'text': 'Yes',
                                                                                'click': function (event) {
                                                                                    self.onListAction('Update', event, self);
                                                                                    self.finalizeTabChange(event);
                                                                                }
                                                                            }),
                                                                        $('<a>',
                                                                            {
                                                                                'text': 'No',
                                                                                'click': function (event) {
                                                                                    self.finalizeTabChange(event);
                                                                                }
                                                                            })
                                                                    ]
                                                                }).hide(),
                                                            $('<div>',
                                                            {
                                                                'class': 'tabbable',
                                                                'append': self.renderBodyChildren(self)
                                                            })                                                            
                                                     ]
                                                }),              

Open in new window


There is not HTML for this, just what is created by this code. That's because this plug-in runs strictly using javascript and generated HTML.


I need to change the styling to look like the attached image.

Clearly, I need to query the X,Y and width of parent window...

What else do I need for a centered dialog, no title and nothing special?

How?
ASKER CERTIFIED SOLUTION
Avatar of Tom Beck
Tom Beck
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of curiouswebster

ASKER

thanks
need to change the styling to look like the attached image
Image?