Forums | Mahara Community

Developers /
MNET profile pic


anonymous profile picture
Account deleted
Posts: 13

25 January 2013, 13:56

Hello, 

After googling a bit, it looks like if I set up a mahoodle to SSO from mahara->moodle, mahara won't send over the profile pic. I was wondering how hard it would be to program this? Its already sending over other fields from the db, why not just send over the image id, and then have the moodle profile page create a img src tag that inserts  "http://localhost/mahara/htdocs/thumb.php?type=profileiconbyid&maxwidth=60&maxheight=60&id=" . $idnumber from mahara db.  

I wouldn't mind changing some moodle core code on my instance to accomplish this. Would this work in theory?

Kristina Hoeppner's profile picture
Posts: 4717

03 March 2013, 19:55

Hello Dave,

Did you take a look at how Moodle sends the profile picture to Mahara? Maybe you can implement something similar for Mahara to Moodle since it also uses the MNet protocol and I assume that this implementation is similar to what Moodle does.

I keep my fingers crossed.

Cheers

Kristina

Aaron Wells's profile picture
Posts: 896

07 March 2013, 11:47

MNet can be a little tricky to hack. Kristina's suggested approach of looking at how the Mahara -> Moodle direction works, is a good first step.

I think in the latest versions of Moodle the code that prints user profile pics is the "get_url()" function of the "user_picture" class in lib/outputcomponents.php. Maybe you could add some code in there that checks to see if the user is an mnet user, and if so, generate the link to their Mahara user profile image.

Cheers,

Aaron

3 results