Is it possible to change the moodle Administrator Email and Smtp from code editor, not the GUI? I′ve been researching and trying by my own but still not having any reault. Thanks in advance!
You can update DB records, in example:
$admin = $DB->get_record('user',['email'=>'[email protected]']); $admin->email = '[email protected]'; $DB->update_record('user',$admin);
More information can be found here: https://docs.moodle.org/dev/Data_manipulation_API
1.4m articles
1.4m replys
5 comments
57.0k users