aspose file tools*
The moose likes HTML, CSS and JavaScript and the fly likes Jquery Problems : Jquery Dialog Box 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 Problems : Jquery Dialog Box " Watch "Jquery Problems : Jquery Dialog Box " New topic
Author

Jquery Problems : Jquery Dialog Box

ankita sarma
Greenhorn

Joined: Nov 13, 2012
Posts: 25
Hi Fellow Programmers,

I am trying to work on jQuery and working on jQuery dialogs. I am facing certain problems as mentioned below

1. I am using jQuery version 1.9.4. Dialog cancel button is not working

I have tried with

Due to some constraints I cannot put the whole code but i can try to Explain all the things I have done.

In most of the cases I have seen on net people have done something like this


Instead of doing like this I have simply done



2. In a dialogue box I am including one jsp which has a table with data. but this jsp doesnt take up whole pop up space and lot of blank space around the table remains.What settings do I need to do so that the table takes up the whole space

Note : I apologise for not being able to post the whole code due to some reasons.



J. Kevin Robbins
Bartender

Joined: Dec 16, 2010
Posts: 1003
    
  13

As far as I know, the buttons need to be setup in the initialization for the dialog like so:


As for the second problem, I can't even begin to guess without seeing the html and css.


"The good news about computers is that they do what you tell them to do. The bad news is that they do what you tell them to do." -- Ted Nelson
ankita sarma
Greenhorn

Joined: Nov 13, 2012
Posts: 25
Hie Kevin

Thanks for your reply.

I am doing the same way as you have done here with some changes


usually you would call this $deleteDialog in

but instead what i have done is


And



so in my case is not working. I was wondering is it because of the fact that instead of putting that line (I have commented above)
autoOpen : false and then calling I am simply opening it on the button click.

J. Kevin Robbins
Bartender

Joined: Dec 16, 2010
Posts: 1003
    
  13

Is delFunction() declared outside the document.ready() function? Does the dialog box display automatically when the page loads? Is there an error in the javascript console when you click the button that calls the delFunction()?
ankita sarma
Greenhorn

Joined: Nov 13, 2012
Posts: 25
Hi Kevin,

yes thats outside document.ready()
and I am calling that on a buttons click event

("#element_name").dialog("close")

has solved my problem
ankita sarma
Greenhorn

Joined: Nov 13, 2012
Posts: 25
I have checked in google chromes sricpt editor there is no error
 
wood burning stoves
 
subject: Jquery Problems : Jquery Dialog Box