I got this to work - Thanks to David on the lift list. I'll start converting the auxillary pages this weekend. Means we will lose the tabs = cleaner UI.
I'll also move popular links and messages to modal dialogs as well. D. On Wed, Mar 24, 2010 at 8:51 AM, Richard Hirsch <[email protected]>wrote: > I just deployed a new version on stax. > > If you look at > http://esmecloudserverapache.dickhirsch.staxapps.net/track_view/, you will > see my first attempts at creating modal dialog. Right now, I'm stuck on > submitting the dialog via jquery. > > Here is the script (dialog_test.js). If anybody has any ideas how to solve > the problem that would be great. > > $("#dialog-form").dialog({ > autoOpen: false, > height: 200, > width: 350, > modal: true, > buttons: { > 'Create a new track': function() { > var bValid = true; > allFields.removeClass('ui-state-error'); > > bValid = bValid && > checkLength(tracking_input,"tracking_input",3,16); > > bValid = bValid && > checkRegexp(tracking_input,/^[a-z]([0-9a-z_])+$/i,"Track may consist of a-z, > 0-9, underscores, begin with a letter."); > > if (bValid) { > //$('button[type=submit] .default').click(); > this.ownerDocument.forms[1].submit(); > > $(this).dialog('close'); > } > }, > Cancel: function() { > $(this).dialog('close'); > } > }, > close: function() { > allFields.val('').removeClass('ui-state-error'); > } > }); >
