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!
Related posts:


4 Responses
trent
16|Oct|2007I’ve added a couple new themes to the docs page as examples 12 and 13:
http://trentrichardson.com/Impromptu/
Please feel free to send in your designs if you would like to share. Show off your CSS flexibility!
Chris
28|Oct|2007Trent,
Just like to say great stuff here. I’m new with JQuery and I was looking for a nice modal pop-up window to integrate with a new web app we’re creating and this fits the bill nicely.
Quick Question…
In my web app I have a page that will list out say users and for each user there would be a delete link beside them which when clicked would bring up the modal pop-up window.
Issue is when the window comes up and the user for instance clicks “yes” to delete something I need to somehow capture that action and perform the necessary deletion in the dbase.
Im assuming the page I use to spawn the modal window needs some sort of listener to listen for a particular action whcih would come from the modal pop-up window. Other issue is how do I take the javascript action and actually do the deletion of a specific record utilizing php?
This might not be the correct forum for this but I’ve looked high and low for answers but I cannot seem to find anything.
I’d appreciate any help you might be able to offer or any links to a tutorial that might deal with this.
trent
28|Oct|2007Hi Chris,
This plugin is exactly what you need for such as this. First off take a look at question and answer 10 and 11 on this page:
http://trentrichardson.com/?p=23
and my example 8 here
http://www.trentrichardson.com/Impromptu/
This is how you would want to start out. For your prompt you will want to use two buttons, Delete and Cancel:
buttons:{Delete:true,Cancel:false},
and the callback. (look at question and answer 10 and 11 on the first link above) If Delete was clicked( if(v){…} ) you will want to do an ajax post. jQuery ajax docs here:
http://docs.jquery.com/Ajax
How do you get the database user id for each user? When printing out your delete buttons for the users I would include an html input element within the prompt text where the value is the userid. Now we can get the value of the user of the delete button that is clicked. so to get the value from the prompt that was clicked might look like…
function myCallback(v,m){
if(v){
uid = m.find(‘input.userid’).val();
jQuery.post(‘removeuser.php’,{user:uid},removedcallback);
}
else{}
}
After this successfully posts, it will call the removecallback() function. Here you will want to remove the user(consider we just removed user 3 from your list of users..
removecallback = function(){
$(‘div.userid3′).remove();
}
Hope this helps, I will try to whip up a simple example of such sometime today!
trent
28|Oct|2007Chris,
I come up with an example to help you out!
http://www.trentrichardson.com/Impromptu/demos/demo1.html