function fp_get_student_name
Search API
7.x db.inc | fp_get_student_name($cwid, $bool_include_cwid = FALSE) |
6.x db.inc | fp_get_student_name($cwid, |
4.x db.inc | fp_get_student_name($cwid) |
5.x db.inc | fp_get_student_name($cwid) |
14 calls to fp_get_student_name()
- alerts_advisees_alerts_form in modules/
alerts/ alerts.module - Displays alerts for our various advisees.
- alerts_display_advisee_activities_page in modules/
alerts/ alerts.module - Display all advisee activities since the beginning of time, thanks to pager query.
- audit_popup_edit_approval_form in modules/
audit/ audit.module - This is the actual form that will be used to change an audit approval for a student.
- calendar_build_custom_calendar in modules/
calendar/ calendar.module - Actually renders the HTML for the calendar.
- calendar_confirm_cancel_appointment_form_submit in modules/
calendar/ calendar.module
File
- includes/
db.inc, line 664 - This file contains mostly db shortcuts.
Code
function fp_get_student_name($cwid, $bool_include_cwid = FALSE) {
if (is_numeric($cwid) && ($cwid === 0 || $cwid === '0')) {
return t("Anonymous");
}
// Already cached?
if (isset($GLOBALS ['fp_cache_get_student_name'][$cwid][intval($bool_include_cwid)])) {
return $GLOBALS ['fp_cache_get_student_name'][$cwid][intval($bool_include_cwid)];
}
$db = get_global_database_handler();
$name = $db->get_student_name($cwid, $bool_include_cwid);
if (!$name) {
$name = t("Unknown Student");
}
$GLOBALS ['fp_cache_get_student_name'][$cwid][intval($bool_include_cwid)] = $name;
return $name;
}