Just wondered if anyone knew how I would be able to dynamically rotate the profile pics and merge it with a default pic? As i want to frame the profile pic with another PNG file and rotate the combined image through 45 degress? i've tried imagerotate but I don't seem to be able to get it working? I'm using the Aarkvark theme and in the profileblock.php page it has the following to display the current user's profile pic:
echo '<a href="'.$CFG->wwwroot.'/user/view.php?id='.$USER->id.'&course='.$COURSE->id.'"><img src="'.$CFG->wwwroot.'/user/pix.php?file=/'.$USER->id.'/f1.jpg" width="80px" height="80px" title="'.$USER->firstname.' '.$USER->lastname.'" alt="'.$USER->firstname.' '.$USER->lastname.'" /></a>';
Any ideas how I can change the img src to to allow me to merge and rotate?
wesleyw (2nd June 2011)
Found it's really easy to use CSS to rotate the image as well as overlay it.
filter: progidXImageTransform.Microsoft.Matrix(sizingMethod='aut o expand',M11=0.866, M12=-0.5, M21=0.5, M22=0.866);
-ms-filter: "progidXImageTransform.Microsoft.Matrix(sizingMethod='aut o expand',M11=0.866, M12=-0.5, M21=0.5, M22=0.866)";
Each of these rotates the picture by 30 degrees however MS and Firefox don't agree with each other as to the final location (IE looks much better actually, seems to be keeping the image proportions which makes the image sharper).
There are currently 1 users browsing this thread. (0 members and 1 guests)