Impromptu


Many of the questions for Impromptu are concerning how exactly to use Impromptu as a confirm to remove an element from a list(database or just the dom). Its actually pretty easy, and so I whipped up an example of removing users from a database. Each user has a userid which I pass to the php file, the php file passes back true/false if it was successful. Then we remove the user from the html dom or either throw an error message. The examples can be found here, just view the source for the code:

Delete users from a list

http://www.trentrichardson.com/Impromptu/demos/demo1.html

Edit users from a list

http://www.trentrichardson.com/Impromptu/demos/demo2.html

Does anyone out there think they have a cool Impromptu design?  I’ll be the first to admit the design in the doc’s isn’t exactly eye-catching.  That being said I would like to make an Impromptu Design Repository.  Within there we could share images of other’s Impromptus or even CSS.  If you have a design you would like to share let me know, reply on this post with your CSS, a link to your image, or send me an email with your image.  Also if you are requiring other plugins to achieve your look, please include information on the plugin’s name/location(or if you had to do any other js to make it work).  Don’t forget to include a link to your site or name if you want to be referenced!
It should be exciting to see what others have come up with!

Well now its officially available. Check it out for yourself. No real big new features just some of the ones we talked about before. Now you can optionally declare global settings so you dont have to declare them every time:

$.SetImpromptuDefaults({ opacity:0.9, prefix:’myclass’ });

Don’t worry, there is more to come, I just felt this was an important feature that needed to be added asap. I’m not leaving anyone out!

Just thought I’d give everyone a shot to request any more features for Impromptu? Currently on my list is to make the options more global so you don’t have to declare your custom show method everytime.. unless thats what makes you happy :). So with this next release you might say something like…

$.ImpromptuOptions = { show: ‘mycustomeffect’, prefix: ‘myprompt’ };

Now you can just $.prompt() with just a message. Again this wont be required and may not be the exact syntax, but this is what I’m shooting for along with being completely backwards compatible. I wont be releasing this one for a while yet to try and get some feedback. So what do you think??

Finally a new version of jQuery Impromptu has been released. This release in my opinion has a few new cool features. First off you can now control the speed of the fade and the prompt box. Also you can now set which jQuery effect to use to bring in the prompt(show, fadeIn, slideDown, or your own custom effect).

Now to the good stuff. Now you can have a submit function. Just as you have form.submit(), you now can have the same function which operates about the same. You can validate your fields and determine whether to proceed sending the data and closing the prompt or not(returning true or false accordingly). Then you will still have your separate callback to be called after the prompt completely closes.

I hope this is of some use to someone, I know I’ve already used it several times!  There are examples of these new features on the Impromptu site.

Well I gave it a go at the jQuery plugin deal, and well.. I dont think version 0.1 turned out too darn bad.  jQuery Impromptu as I’m calling it is a nice little plugin to simulate a nice css/js alert or prompt You may also add forms custom forms and elements to your prompts as well.   A few of the options allows you to narrow the allert down to an html element on the page(given it is relative or absolutely positioned) and create as many buttons on your prompt as you wish! A callback function lets you process your forms.   Please give it a shot on my examples page and please let me know if you have suggestions or constructive criticism or any other comments.

« Previous Page