Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
register({
name: 'moodle.domain.com',
url: 'http://moodle.domain.com/',
icon: 'http://moodle.domain.com/theme/mytheme/favicon.ico',
domains: [ 'moodle.domain.com' ],
sessionCookieNames: [ 'MoodleSession', 'MoodleSessionTest' ],
identifyUser: function() {
var site = this.httpGet('http://moodle.domain.com/user/view.php');
this.userName = site.body.querySelector('div.logininfo a').text;
this.userAvatar = site.body.querySelector('img.userpicture').src;
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.