authenticate_request(); $sloodle->validate_user(true, true, true); // Request a password reset. $password = $sloodle->user->reset_password(); // Prepare the response $sloodle->response->set_status_code(1); $sloodle->response->set_status_descriptor('OK'); $sloodle->response->add_data_line(array($sloodle->user->get_username(), $password)); // If there are any pending password notifications for this user, then delete them $sloodle->user->purge_password_notifications(); // Output the response data sloodle_debug('
'); $sloodle->response->render_to_output(); sloodle_debug(''); ?>