Administration hacks
From MoodleDocs
Here are some hacks or tweaks to Moodle code that administrators have found useful on their sites to fill specific needs.
Preventing Welcome to the course emails
You can stop moodle sending enrolment emails by changing two lines in the file /enrol/enrol.class.php
The line (occuring twice in the file!) reads:
email_to_user($USER, $teacher, $subject, $message);
It must be changed to:
// email_to_user($USER, $teacher, $subject, $message);
That way, moodle ignores the e-mail-command until you change back to the original line. The setting works for all courses at the same time. It does not affect other e-mails being sent (e.g. the login confirmation).