yeah.  unlike most of the ui components, the available callbacks for
Dialog are not listed on the options tab of the
documentation....what's the deal?

--adam

On Aug 28, 5:42 pm, "Jaime Ochoa Malagón" <[EMAIL PROTECTED]> wrote:
> I suggest to do it in the docs like php, with the advantage of the wiki...
>
> On 8/28/08, Chris Jordan <[EMAIL PROTECTED]> wrote:
>
>
>
> > I agree. :o)
>
> > On Thu, Aug 28, 2008 at 10:51 AM, Fontzter <[EMAIL PROTECTED]> wrote:
>
> > > That makes me think that it would be nice if we could have a more
> > > organized repository for code snippets.  I know the plugins handle a
> > > lot of this; but there are always little things like this that would
> > > be handy.  It would be nice if there were a place to store, browse and
> > > search through code snippets that do various little things like this.
>
> > > On Aug 27, 4:03 pm, "Chris Jordan" <[EMAIL PROTECTED]> wrote:
> > > > lol! I wrote one of those a while back and posted it to the group too...
> > > > small world. :o)
>
> > > > Chris
>
> > > > On Wed, Aug 27, 2008 at 1:35 PM, Fontzter <[EMAIL PROTECTED]> wrote:
>
> > > > > Thanks Richard.  I threw this into a function if anyone is interested:
>
> > > > > function prettyAlert(p_message, p_title)
> > > > > {
> > > > >  p_title = p_title || "";
> > > > >  $("<div>" + p_message + "</div>").dialog({
> > > > >    title: p_title,
> > > > >    resizable: false,
> > > > >     modal : true,
> > > > >    overlay: { backgroundColor: "#000", opacity: 0.5 },
> > > > >     buttons: { "Okay": function() { $(this).dialog("close"); } },
> > > > >     close: function(ev, ui) { $(this).remove(); }
> > > > >   });
> > > > > }
>
> > > > > On Aug 27, 11:57 am, "Richard D. Worth" <[EMAIL PROTECTED]> wrote:
> > > > > > Yes, provide a close callback in the options, like so:
>
> > > > > > $('<div>jQuery is great!</div>').dialog({
> > > > > >   ...
> > > > > >   close: function(ev, ui) {
> > > > > >     $(this).remove();
> > > > > >   }
> > > > > >   ...
> > > > > >   });
>
> > > > > > The 'this' is thedialogcontent element, the same on which you
> > called
> > > > > > .dialog(). When you .remove() it, it will destroy thedialog.
>
> > > > > > - Richard
>
> > > > > > On Wed, Aug 27, 2008 at 11:42 AM, Fontzter <[EMAIL PROTECTED]>
> > wrote:
>
> > > > > > > Hi,
>
> > > > > > > I want to emulate a custom alert message using thedialog.  Here's
> > an
> > > > > > > example:
>
> > > > > > >          $('<div>jQuery is great!</div>').dialog({
> > > > > > >            title: "I love jQuery",
> > > > > > >            modal : true,
> > > > > > >            overlay: {
> > > > > > >              backgroundColor: '#000',
> > > > > > >              opacity: 0.5
> > > > > > >            },
> > > > > > >            buttons: {
> > > > > > >              'Okay': function() {
> > > > > > >                $(this).dialog('close').remove();
> > > > > > >                return false;
> > > > > > >              }
> > > > > > >            }
> > > > > > >          });
> > > > > > >        }
>
> > > > > > > One thing I realized though, is that if the user clicks the X
> > rather
> > > > > > > than a button, thedialoggets closed but not removed.  Is there a
> > way
> > > > > > > to not show the X or to destroy thedialogwhen it is closed via
> > the
> > > > > > > X?  I guess I could add a close function to the options; but I
> > wasn't
> > > > > > > sure exactly what the function would look like to get thedialog
> > > > > > > element.  Also, I was wondering if there was a better way to do
> > this
> > > > > > > that I am not seeing.
>
> > > > > > > Thanks,
>
> > > > > > > Dave
>
> > > > --http://cjordan.us
>
> > --
> >http://cjordan.us
>
> --
> Perhaps the depth of love can be calibrated by the number of different
> selves that are actively involved in a given relationship.
>
>                                         Carl Sagan (Contact)
>
>                                         Jaime Ochoa Malagón
>                                         Arquitecto de Soluciones
>                                         Cel: +52 (55) 1021 0774
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"jQuery UI" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/jquery-ui?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to