Adding the teacher name to the grade.php and grades.php files

Adding the teacher name to the grade.php and grades.php files

by Luis Lebron -
Number of replies: 2

I would like to add the name of the teacher(s) to the grade report. I have been looking at the moodle code and I know that I need the following functions:

$teachers = get_course_teachers($course->id);
$strteachers = get_string("teachers");

Teachers of course is a multi-dimensional array with teacher "objects" that I can access like so:

foreach($teachers as $teacher)
  {
     echo $teacher->firstname." ".$teacher->lastname;
  }

So far so good. Now how could I actually print this information in the grades table, let say in rows below the top row (the one that says Grades)

Thanks,

Luis

In reply to Luis Lebron

Re: Adding the teacher name to the grade.php and grades.php files

by Michael Penney -
Hi Luis, you could also enroll the teacher as a student.
In reply to Michael Penney

Re: Adding the teacher name to the grade.php and grades.php files

by Luis Lebron -

I guess my post was not clear. What I need is for the student to see the name of the teacher in addition to the grades information in the grade.php script.

Luis