-
Notifications
You must be signed in to change notification settings - Fork 0
/
qualifications.php
49 lines (44 loc) · 1.4 KB
/
qualifications.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
<?php
/**
* Created by JetBrains PhpStorm.
* User: dattwood
* Date: 17/06/11
* Time: 16:25
* Displays the students qualifications using the XML server results
*/
//try {
// $resultStudent = $client->getQualsById($student_number);
//}
//
//catch (SoapFault $e) {
// // handle issues returned by the web service
// echo '<br/>';
// echo "No MIS records found for user " . $CFG->name;
// echo " either the there is a problem with MIS or more likely the Student isn't enrolled for this year";
// echo '<br/>Please wait a few moments and refresh the page';
//}
$resultStudent = $client->__soapCall("getQualsById",array($student_number));
accord_first('Current Courses');
//var_dump($resultStudent);
echo '<table>';
foreach ($resultStudent as $key => $item) {
// Echo the titles
$class = 'lightblue';
foreach ($item as $iKey => $iItem) {
if ($iKey == 'Name') {
echo '<tr class="darkblue"><th colspan="2">', replaceUnderScore($iItem), '</th></tr>';
} else {
echo '<tr class="', $class, '"><th>', replaceUnderScore($iKey), '</th><td>', replaceUnderScore($iItem), '</td></tr>';
// Switch the class to allow for stripping
if ($class == 'lightblue') {
$class = 'yellow';
} else {
$class = 'lightblue';
}
}
}
}
echo '</table>';
accord_last();
unset($resultStudent);
?>