pwdMeter

Introduction

pwdMeter is a small password strength meter plugin for jQuery that provides a neat and easy way to show the user's password strength. At the same time it helps a user to generate and choose a secured password for their account. The footprint is less than 3 KB in size.

Download

Download from GitHub
(requires jQuery 1.3 or above)

Demo


Enter Password:
Very Weak


Installation

Step 1: Include a reference to the jQuery Core library (1.3 or above) and the pwdMeter plugin.
<script language="javascript" src="jquery.js"></script>
<script language="javascript" src="jquery.pwdMeter.js"></script>

Step 2: In your HTML file, provide the markup required by pwdMeter.
	
Very Weak

Step 3: Finally you need to fire a call to the pwdMeter plugin and supply your parameters (if any):
	 <script language="javascript">
		$(document).ready(function(){

			$('#password').pwdMeter();

		});
	</script>
 


pwdMeter accepts the following optional parameters:

minLength: The minimum length of the password.

displayGeneratePassword: If set to true, displays a link to generate random passwords.

generatePassText: You can specify any text that you'd like the "Generate Password" link read.

generatePassClass: This specifies the class for the "Generate Password" link.

randomPassLength: Specifying the length of the random password. Can be any integer for example 8, 10, 15 etc.

Example:
	 <script language="javascript">
		$(document).ready(function(){

			$('#password').pwdMeter({
				minLength: 6,
				displayGeneratePassword: false,
				generatePassText: 'Password Generator',
				generatePassClass: 'GeneratePasswordLink',
				randomPassLength: 13
			});

		});
	</script>