Skip to content

Instantly share code, notes, and snippets.

@donnfelker
Created March 3, 2010 19:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save donnfelker/320931 to your computer and use it in GitHub Desktop.
Save donnfelker/320931 to your computer and use it in GitHub Desktop.
var loadingUx = '<img src="<%=Url.Content("~/Images/ajax-loader.gif")%>" /> Loading';
$("#my-button-id").click(function () {
// Add loading gif to let user know some kind of party is going on while they wait
$(this).hide();
$(this).parent().append(loadingUx); // Button is in a div of its own
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment