aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes JQuery Dialog Box Positioning and Replacing X with Close Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "JQuery Dialog Box Positioning and Replacing X with Close" Watch "JQuery Dialog Box Positioning and Replacing X with Close" New topic
Author

JQuery Dialog Box Positioning and Replacing X with Close

James Dekker
Ranch Hand

Joined: Dec 09, 2006
Posts: 215
Am very new to JavaScript... Am using JQuery to create a custom dialog box.

Question(s):

1. How to position the dialog box to anywhere I want on the screen using specific (X,Y) coordinates (or some other mechanism)? Do not want it to appear in the middle.

2. How to replace the X with "Close"?

Have this but this just makes the dialog box's titlebar disappear:



3. How to set it so it can not be dragged or moved by the end user?

Any help would be most appreciated...

Thank you for taking the time to read this,

James
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61420
    
  67

1 and 3 answered here.

2 may be solvable with closeText. You'll need to play with it.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
pay? think there was a little typo.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61420
    
  67

Fixed.

James Dekker
Ranch Hand

Joined: Dec 09, 2006
Posts: 215
Bear,

Thank you so much for responding... Yes, I had researched JQueryUI before posting this post. I just am so new to JQuery that I don't know the basic code structure or syntax so JQueryUI was somewhat confusing.

Well, I got it to work by doing this:



The Close is underlined and is in the center of the dialog box's title. It would be nice to remove the underline and have it in the top right hand corner of the dialog box.

Thanks for taking the time to read this...
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61420
    
  67

You'll need to take a look at the structure of the header (Firebug in Firefox, or the built-in debugger of Safari/Chrome) and add CSS accordingly.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JQuery Dialog Box Positioning and Replacing X with Close