$value
\n"; } // Grab some other details. username, displayname, uid, etc. $username = $_GET['username']; //echo "username = ".$username."
\n"; $display_name = $_GET['urn:mace:dir:displayName']; //echo "display_name = ".$display_name."
\n"; // Can't grab loginid for some reason. Not sure why at the moment. mjarrell 01-19-10. //$login_id = $GET['urn:sungardhe:dir:loginId']; //echo "login_id = ".$login_id."
\n"; // Get Class Climate links! $opts = array('trace' => TRUE); // for debugging only - when __getLast* are used \\ $auth_URL = '[class climate server URL]/classclimate/services/soapserver-v4.wsdl'; try { $soapClient = new SoapClient($auth_URL, $opts); // Set the SOAP-headers for authentication $header_input = array('Login' => "[web services username]", 'Password' => "[web services password]"); $soapHeaders = new SoapHeader('soapserver-v4.wsdl', 'Header', $header_input); $soapClient->__setSoapHeaders($soapHeaders); // Obtain the open online survey links for the presented email address $result = $soapClient->GetPswdsByParticipant($username ."@my.apsu.edu"); // Build the links... echo "Please use the links below to evaluate your recent courses at [school name]:
\n"; echo "';
//print_r($result);
//echo '';
// OTHER FUNCTIONS IN THE API:
// Display the obtained online survey links
//$this->displayOpenOnlineSurveys($result);
// Display all subunits:
//$result = $soapClient->GetSubunits();
// Display survey details for a particular survey id:
// Note: umfid can be determined by hovering over survey name inside of Class Climate admin GUI.
//$result = $soapClient->GetSurveyById('59500');
// Display all available passwords for a given survey id:
//$result = $soapClient->GetPswdsBySurvey('59500');
// Display all survey links for a particular survey and particular email address:
//$result = $soapClient->GetOnlineSurveyLinkByEmail('59500', 'jarrellm@apsu.edu');
// for debugging \\
/*echo "\n\n" . htmlentities($soapClient->__getLastRequestHeaders() . $soapClient->__getLastRequest()) . "\n\n"; echo "\n\n
" . htmlentities($soapClient->__getLastResponseHeaders() . $soapClient->__getLastResponse()) . "\n\n"; echo "\n\n\n
Error: No Pswds for the given participant found.
\n"; echo "Thank you for using Class Climate to help us evaluate [school name] courses.
You don't appear to have any active surveys to fill out at the current time. Please check back again when your next class comes to an end.
Error: Incomplete input parameters.
\n"; } else { echo "" . htmlentities($soapClient->__getLastRequestHeaders() . $soapClient->__getLastRequest()) . "\n\n"; echo "\n\n
" . htmlentities($soapClient->__getLastResponseHeaders() . $soapClient->__getLastResponse()) . "\n\n"; echo "\n\n\n
" . htmlentities($soapClient->__getLastRequestHeaders() . $soapClient->__getLastRequest()) . "\n\n"; echo "\n\n
" . htmlentities($soapClient->__getLastResponseHeaders() . $soapClient->__getLastResponse()) . "\n\n"; echo "\n\n\n
Error: This page must be viewed within the [school name] portal. If you need further assistance, please email [admin@yourschool.edu].
\n"; } ?>