Title: SimpleModal Login
Author: Eric
Published: <strong>December 17, 2009</strong>
Last modified: December 15, 2014

---

Search plugins

This plugin **hasn’t been tested with the latest 3 major releases of WordPress**.
It may no longer be maintained or supported and may have compatibility issues when
used with more recent versions of WordPress.

![](https://s.w.org/plugins/geopattern-icon/simplemodal-login.svg)

# SimpleModal Login

 By [Eric](https://profiles.wordpress.org/emartin24/)

[Download](https://downloads.wordpress.org/plugin/simplemodal-login.1.1.zip)

 * [Details](https://test.wordpress.org/plugins/simplemodal-login/#description)
 * [Reviews](https://test.wordpress.org/plugins/simplemodal-login/#reviews)
 *  [Installation](https://test.wordpress.org/plugins/simplemodal-login/#installation)
 * [Development](https://test.wordpress.org/plugins/simplemodal-login/#developers)

 [Support](https://wordpress.org/support/plugin/simplemodal-login/)

## Description

**SimpleModal Login 1.0 now includes a user registration and password reset feature!**

SimpleModal Login provides a modal Ajax login, registration and password reset feature
for WordPress and utilizes jQuery and the SimpleModal jQuery plugin.

SimpleModal Login allows you to create your own custom themes. See the FAQ for details.

Translations: https://plugins.svn.wordpress.org/simplemodal-login/I18n (check the
version number for the correct file)

## Screenshots

 * [[
 * Login screen with the default theme.
 * [[
 * Register screen with the default theme.
 * [[
 * Reset Password screen with the default theme.
 * [[
 * Activity indicator with the default theme.
 * [[
 * Login screen with the osx theme.
 * [[
 * Register screen with the osx theme.
 * [[
 * Reset Password screen with the osx theme.
 * [[
 * Activity indicator with the osx theme.
 * [[
 * The SimpleModal Login admin settings page

## Installation

_Install and Activate_

 1. Unzip the downloaded SimpleModal Login zip file
 2. Upload the `simplemodal-login` folder and its contents into the `wp-content/plugins/`
    directory of your WordPress installation
 3. Activate SimpleModal Login from Plugins page

_Implement_

There are 3 options for using the SimpleModal Login features:

a) Use `wp_loginout()` or `wp_register()` in your theme. SimpleModal Login will 
use the loginout and register filters to add the `simplemodal-login` class or `simplemodal-
register` class to the respective link.

b) Enable the Keystroke Shortcut option. Once this is enabled, you will be able 
to invoke SimpleModal Login using the `Ctrl+Alt+L` keystroke.

c) Manually add a Log In or Register link. If your theme does not use `wp_loginout()`
and you still want to use this plugin, you can manually edit your theme and add 
a login link as follows:

    ```
    <a href="/wp-login.php" class="simplemodal-login">Log In</a>

    <a href="/wp-login.php?action=register" class="simplemodal-register">Register</a>
    ```

_Configure_

1) Configure the SimpleModal Login settings, if necessary, from the SimpleModal 
Login option in the Settings menu. You can choose from one of the available themes
as well as enable/disable the keystroke shortcut.

2) The styles can be changed with the following methods:

 * Add a CSS file in your theme’s directory and place your custom CSS there. The
   name of the file should be simplemodal-login-THEME.css. For example, `simplemodal-
   login-default.css` or `simplemodal-login-osx.css`.
 * Add your custom CSS to your theme’s `style.css` stylesheet
 * Modify the SimpleModal Login CSS files directly in the simplemodal-login/css 
   directory

_Note:_ The first two options will ensure that SimpleModal Login updates will not
overwrite your custom styles.

## FAQ

  Installation Instructions

_Install and Activate_

 1. Unzip the downloaded SimpleModal Login zip file
 2. Upload the `simplemodal-login` folder and its contents into the `wp-content/plugins/`
    directory of your WordPress installation
 3. Activate SimpleModal Login from Plugins page

_Implement_

There are 3 options for using the SimpleModal Login features:

a) Use `wp_loginout()` or `wp_register()` in your theme. SimpleModal Login will 
use the loginout and register filters to add the `simplemodal-login` class or `simplemodal-
register` class to the respective link.

b) Enable the Keystroke Shortcut option. Once this is enabled, you will be able 
to invoke SimpleModal Login using the `Ctrl+Alt+L` keystroke.

c) Manually add a Log In or Register link. If your theme does not use `wp_loginout()`
and you still want to use this plugin, you can manually edit your theme and add 
a login link as follows:

    ```
    <a href="/wp-login.php" class="simplemodal-login">Log In</a>

    <a href="/wp-login.php?action=register" class="simplemodal-register">Register</a>
    ```

_Configure_

1) Configure the SimpleModal Login settings, if necessary, from the SimpleModal 
Login option in the Settings menu. You can choose from one of the available themes
as well as enable/disable the keystroke shortcut.

2) The styles can be changed with the following methods:

 * Add a CSS file in your theme’s directory and place your custom CSS there. The
   name of the file should be simplemodal-login-THEME.css. For example, `simplemodal-
   login-default.css` or `simplemodal-login-osx.css`.
 * Add your custom CSS to your theme’s `style.css` stylesheet
 * Modify the SimpleModal Login CSS files directly in the simplemodal-login/css 
   directory

_Note:_ The first two options will ensure that SimpleModal Login updates will not
overwrite your custom styles.

  How can I redirect back to the current page after login?

The WordPress `wp_loginout()` function allows for an optional `$redirect` parameter
which is the URL where the user will be sent after a logging in our logging out.

To have the user return to the page they were on, update the code to look like:

    ```
    <?php wp_loginout($_SERVER['REQUEST_URI']); ?>
    ```

If you are using the Meta Widget (Appearance > Widgets), to use this feature, you
may need to delete the Meta Widget and add the code to your sidebar.php file manually.

For example, after you delete the Meta Widget, open sidebar.php (in your theme) 
and add[1] the following code:

    ```
    <ul>
        <?php wp_register(); ?>
        <li><?php wp_loginout(); ?></li>
    </ul>
    ```

[1] Place it wherever you’d like to display and modify the code to fit your needs.

Lastly, if you’ve manually added a log in link, you can change it to:

    ```
    <a href="/wp-login.php?redirect_to=<?php echo $_SERVER['REQUEST_URI']; ?>" class="simplemodal-login">Log In</a>
    ```

  How can I create my own custom theme?

_This is for users familiar with CSS and JavaScript, namely jQuery and SimpleModal._

To create a new theme you’ll need to add two files under the `simplemodal-login`
plugin directory: `css/THEME.css` and `js/THEME.js`. Replace THEME with the name
you would like to use.

I suggest copying one of the existing themes as a template to start with.

  How can I modify the form HTML?

_This is an advanced option for users familiar with HTML, PHP and WordPress._

Starting with SimpleModal Login 1.0, each form (login, register, password reset)
has a filter available that allows you to modify the HTML.

The 3 available filters are:

 * simplemodal_login_form
 * simplemodal_registration_form
 * simplemodal_reset_form

To use the filter, you’ll need to add code to your theme’s functions.php file. For
example:

    ```
    add_filter('simplemodal_login_form', 'mytheme_login_form');
    function mytheme_login_form($form) {
        // $form contains the SimpleModal Login login HTML

        // do stuff here

        // you have to return the code that you want displayed
        return $form;
    }
    ```

You’d probably want to start by copying the form HTML from the appropriate function
in the main plugin file and then modifying to fit your requirements.

Things you’ll need to change:

 1. Change $this->users_can_register (for login and reset forms only)

 * Create a `$users_can_register` variable in your function:
 * $users_can_register = get_option(‘users_can_register’) ? true : false;
 * Replace `$this->users_can_register` with `$users_can_register`

 1. Change $this->options[‘registration’] and $this->options[‘reset’]

 * Create an `$options` variables in your function:
 * $options = get_option(‘simplemodal_login_options’);
 * Replace `$this->options['registration']` with `$options['registration']`
 * Replace `$this->options['reset']` with `$options['reset']`

Here are complete working examples for each of the three filters:

 * simplemodal_login_form: http://pastebin.com/rm3WWWRS
 * simplemodal_registration_form: http://pastebin.com/bVzZBKZf
 * simplemodal_reset_form: http://pastebin.com/jpd1RiP9

_Have a question, comments or feature requests? Be sure to let me know._

## Reviews

![](https://secure.gravatar.com/avatar/396ffd6f1e5f17b7c7ddb3e3632d290eb430b15f222446178636258bce21dd8c?
s=60&d=retro&r=g)

### 󠀁[NOt working with wordpress 5.5.1](https://wordpress.org/support/topic/not-working-with-wordpress-5-5-1-3/)󠁿

 [monzu02](https://profiles.wordpress.org/monzu02/) October 16, 2020

Not working with WordPress 5.5.1. Please dont download

![](https://secure.gravatar.com/avatar/8c87b98e3f3c3b97ca030d14619a0e40bb8fde76d27e6ff1545f48739a7d7c8f?
s=60&d=retro&r=g)

### 󠀁[Absolute Waste Of Time](https://wordpress.org/support/topic/absolute-waste-of-time/)󠁿

 [Todd Farino](https://profiles.wordpress.org/tfarino/) May 21, 2018

The people giving 5 stars to this are either bots or using it site wide. I wanted
this for specific content. There are no instructions at all. Do not waste your time.

![](https://secure.gravatar.com/avatar/e9be113e44eac503ed28f5064878ecc72e69690828584ee96523d82cde213bea?
s=60&d=retro&r=g)

### 󠀁[Very very good !](https://wordpress.org/support/topic/very-very-good-65/)󠁿

 [NicolausX](https://profiles.wordpress.org/nicolausx/) November 26, 2017

Ty for creating it ! But the modal login shows up not login regardless if you are
login or not !

![](https://secure.gravatar.com/avatar/1da5cc402e9c3ca9a9429b4fadf5930c0704584eb088340349f7b4ac840c7503?
s=60&d=retro&r=g)

### 󠀁[Simply working great!](https://wordpress.org/support/topic/simply-working-great/)󠁿

 [Punt](https://profiles.wordpress.org/punthooft/) September 12, 2017

Great plugin. Easy to implement and include!

![](https://secure.gravatar.com/avatar/a7385fe8d2e80b9aba38dfd6a246650e78f1ffde66c3f2c825e97a53059cb4fb?
s=60&d=retro&r=g)

### 󠀁[Email not send](https://wordpress.org/support/topic/email-not-send-9/)󠁿

 [Dhaval Vachhani](https://profiles.wordpress.org/dvpatel/) September 8, 2017

After user registration Email not send in user email-id.

![](https://secure.gravatar.com/avatar/8932edf860ce25f2965475ec3f4882f662a1155aed362d7ffb7719a92ee31f9a?
s=60&d=retro&r=g)

### 󠀁[works great so easy](https://wordpress.org/support/topic/works-great-so-easy/)󠁿

 [jordanmulkey](https://profiles.wordpress.org/jordanmulkey/) September 3, 2016 
3 replies

Ty for much I love how easy it is to set up!!! I love this plugin HINT!!!!! if you
want login popup in the nav menu simply just add <a href="/wp-login.php" class="
simplemodal-login">Login</a> under menu-custom links, the trick is to put the code
under Navigation Label and leave the URL blank. So amazing that is has this feature
really good job saved me countless hours.

 [ Read all 33 reviews ](https://wordpress.org/support/plugin/simplemodal-login/reviews/)

## Contributors & Developers

“SimpleModal Login” is open source software. The following people have contributed
to this plugin.

Contributors

 *   [ Eric ](https://profiles.wordpress.org/emartin24/)
 *   [ StudioFuel ](https://profiles.wordpress.org/studiofuel/)

“SimpleModal Login” has been translated into 4 locales. Thank you to [the translators](https://translate.wordpress.org/projects/wp-plugins/simplemodal-login/contributors)
for their contributions.

[Translate “SimpleModal Login” into your language.](https://translate.wordpress.org/projects/wp-plugins/simplemodal-login)

### Interested in development?

[Browse the code](https://plugins.trac.wordpress.org/browser/simplemodal-login/),
check out the [SVN repository](https://plugins.svn.wordpress.org/simplemodal-login/),
or subscribe to the [development log](https://plugins.trac.wordpress.org/log/simplemodal-login/)
by [RSS](https://plugins.trac.wordpress.org/log/simplemodal-login/?limit=100&mode=stop_on_copy&format=rss).

## Changelog

#### 1.1

 * Plugin ownership transfered to Studio Fuel (http://studiofuel.com)
 * Added TEST_COOKIE check to prevent the WordPress cookie error message when logging
   in
 * Tested plugin against WordPress 4.0.1

#### 1.0.7

 * Upgraded to SimpleModal 1.4.3 (requires jQuery 1.3+)

#### 1.0.6

 * Fix HTML markup bug.

#### 1.0.5

 * Removed “Powered by SimpleModal Login” link and CSS.
 * Fixed “empty_both” bug.
 * Added modal z-index to prevent stacking issues.
 * Upgraded to SimpleModal 1.4.2

#### 1.0.4

 * Added output buffering to the login_form, register_form, and lostpassword_form
   actions. Thanks to @thenbrent for the fix.
 * Fixed ‘Undefined variable’ warning in WordPress DEBUG mode. Thanks to @thenbrent
   for the fix.

#### 1.0.3

 * Upgraded to SimpleModal 1.4.1
 * Updated add_options_page() arguments to prevent deprecation warning. Thanks to
   DanHarrison for reporting and providing a fix.
 * Removed s.modal.update(); from both osx.js and default.js. It was causing issues
   with the dialog height.

#### 1.0.2

 * Changed language domain name from simplemodal_login to simplemodal-login (this
   will affect translation file names)
 * Updated pastebin.com link with language domain name updates
 * Translations can now be found at https://plugins.svn.wordpress.org/simplemodal-
   login/I18n/

#### 1.0.1

 * Added support for the wp_loginout() redirect parameter (See FAQ for usage)

#### 1.0

 * Added Password Reset feature
 * Added Register feature
 * Added support for Peter’s Login Redirect plugin
 * Added activity indicator for better usability
 * Added additional error handling
 * Added Keyboard Shortcut option and feature (Ctrl+Alt+L)
 * Removed the ‘Redirect after login?’ option
 * Updated POT file (I18n/simplemodal-login.pot)
 * Added plugin update logic
 * Upgraded to SimpleModal 1.4
 * Added additional screenshots
 * Added filters for each form (login, register, password reset) output HTML to 
   allow for customization

#### 0.3

 * Added uninstall cleanup code
 * Updated POT file
 * Added the ability to add new themes dynamically
 * Renamed CSS and JS theme files (removed simplemodal-login- prefix)
 * Removed unused code
 * Changed redirect option meaning on the Settings page

#### 0.2

 * Updated POT file

#### 0.1

 * Initial beta release

## Meta

 *  Version **1.1**
 *  Last updated **8 years ago**
 *  Active installations **800+**
 *  WordPress version ** 2.5.0 or higher **
 *  Tested up to **4.0.38**
 *  Languages
 * [Chinese (China)](https://cn.wordpress.org/plugins/simplemodal-login/), [English (US)](https://wordpress.org/plugins/simplemodal-login/),
   [Russian](https://ru.wordpress.org/plugins/simplemodal-login/), [Spanish (Chile)](https://cl.wordpress.org/plugins/simplemodal-login/),
   and [Ukrainian](https://uk.wordpress.org/plugins/simplemodal-login/).
 *  [Translate into your language](https://translate.wordpress.org/projects/wp-plugins/simplemodal-login)
 * Tags
 * [admin](https://test.wordpress.org/plugins/tags/admin/)[ajax](https://test.wordpress.org/plugins/tags/ajax/)
   [login](https://test.wordpress.org/plugins/tags/login/)[modal](https://test.wordpress.org/plugins/tags/modal/)
   [password](https://test.wordpress.org/plugins/tags/password/)
 *  [Advanced View](https://test.wordpress.org/plugins/simplemodal-login/advanced/)

## Ratings

 4 out of 5 stars.

 *  [  21 5-star reviews     ](https://wordpress.org/support/plugin/simplemodal-login/reviews/?filter=5)
 *  [  4 4-star reviews     ](https://wordpress.org/support/plugin/simplemodal-login/reviews/?filter=4)
 *  [  1 3-star review     ](https://wordpress.org/support/plugin/simplemodal-login/reviews/?filter=3)
 *  [  0 2-star reviews     ](https://wordpress.org/support/plugin/simplemodal-login/reviews/?filter=2)
 *  [  7 1-star reviews     ](https://wordpress.org/support/plugin/simplemodal-login/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/simplemodal-login/reviews/#new-post)

[See all reviews](https://wordpress.org/support/plugin/simplemodal-login/reviews/)

## Contributors

 *   [ Eric ](https://profiles.wordpress.org/emartin24/)
 *   [ StudioFuel ](https://profiles.wordpress.org/studiofuel/)

## Support

Got something to say? Need help?

 [View support forum](https://wordpress.org/support/plugin/simplemodal-login/)