Merged changes from STABLE
[moodle-linuxchix.git] / auth / email / lib.php
blob6807f268d26e99bc53a5cd29f9d88bd458e0e4e8
1 <?php // $Id$
2 // Standard authentication function
4 function auth_user_login ($username, $password) {
5 // Returns true if the username and password work
6 // and false if they don't
8 global $CFG;
10 if (! $user = get_record('user', 'username', $username)) {
11 return false;
14 return ($user->password == md5($password));