We have a situation where we would like students to self register, but before they are sent a confirmation email we would like an administrator to be able to check that they are who they say they are and that they are eligible to access the course, then for the confirmation email to be sent.
I cannot see that Moodle currently does this - or that there is an extension to this effect, does anyone have any suggestions?
I know several people have added a line of code in the past to send a duplicate of the registration email to the administrator of the platform. This way, the admin is always notified of new registrations and can keep an eye on them, and optionally disable/delete those registrations.
I know this doesn't exactly fit your requirements, but this is just one addional line of code, instead of a more invasive change to the way Moodle currently works.
If you are interested in this, just edit .../lib/moodlelib.php and search for function send_confirmation_email (around line 3629 in 1.8.4+, current as of today), and at the end of the function there is a line that reads:
return email_to_user($user, $from, $subject, $message, $messagehtml);
Just before that line, add a line like this:
email_to_user($from, $from, $subject, $message, $messagehtml);
My idea was to go to the line where the email is sent when the user performs the register and comment it out.
Then, go to the line where the Administrator can confirm a user registration, and insert the send email confirmation code there instead.
However, although I have searched (a lot), I cannot find the point from where the send_confirmation_email method is called...
If anyone knows, could you give me some hint?
I want an email address to get a notice of a self enrollment in a 1.9.9+ Moodle.
I think my line in moodlelib.php is around 4539 which says:
return email_to_user($user, $supportuser, $subject, $message, $messagehtml);
I assume I should add
return email_to_user($supportuser, $supportuser, $subject, $message, $messagehtml);
Is it possible for me to add a language string which will contain the email address of where the notice would also go? How would I modify the code and where would I put the string so that it could be found in the language? Would this present a security issue?
Hope someone would help