You are here

Ajaxifying Drupal forms

Sometimes you may want the login form or a contact form to be displayed in a more dynamic way. It could be in modal window and using ajax to submit the form for better user experience.

Example modules

The example modules attached to this post crates a block with a link that displays the user login form in a modal window using jQuery UI and submits the credentials through an ajax callback. You don't need a block to use the technique used here, but it's a convenient way to get a link with a class that can be target by jQuery and used to trigger a modal window.

The modules have been documented in-line, so please download them and read the documentation will learning this technique.

Required modules

The modules here requires that you have the following module downloaded and enabled.

  • jQuery Update
  • jQuery UI (D6 only)
  • Libraries



Drupal 7 Drupal 6 jQuery UI forms

Add new comment