Skip to content

Commit

Permalink
fix Undefined property: stdClass::$studentfeedbackurl (line 282) and …
Browse files Browse the repository at this point in the history
…stdClass::$cellcontent2 (line 1081) in mod\hotpot\lib.php
  • Loading branch information
gbateson committed Jan 21, 2008
1 parent 96be763 commit 4855134
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions mod/hotpot/lib.php
Expand Up @@ -279,11 +279,8 @@ function hotpot_set_form_values(&$hotpot) {
$hotpot->errors['reference']= get_string('error_nofilename', 'hotpot'); $hotpot->errors['reference']= get_string('error_nofilename', 'hotpot');
} }


if ($hotpot->studentfeedbackurl=='http://') { if (empty($hotpot->studentfeedbackurl) || $hotpot->studentfeedbackurl=='http://') {
$hotpot->studentfeedbackurl = ''; $hotpot->studentfeedbackurl = '';
}

if (empty($hotpot->studentfeedbackurl)) {
switch ($hotpot->studentfeedback) { switch ($hotpot->studentfeedback) {
case HOTPOT_FEEDBACK_WEBPAGE: case HOTPOT_FEEDBACK_WEBPAGE:
$ok = false; $ok = false;
Expand Down Expand Up @@ -1076,9 +1073,15 @@ function hotpot_print_recent_mod_activity($activity, $course, $detail=false) {


global $CFG, $THEME, $USER; global $CFG, $THEME, $USER;


if (isset($THEME->cellcontent2)) {
$bgcolor = ' bgcolor="'.$THEME->cellcontent2.'"';
} else {
$bgcolor = '';
}

print '<table border="0" cellpadding="3" cellspacing="0">'; print '<table border="0" cellpadding="3" cellspacing="0">';


print '<tr><td bgcolor="'.$THEME->cellcontent2.'" class="forumpostpicture" width="35" valign="top">'; print '<tr><td'.$bgcolor.' class="forumpostpicture" width="35" valign="top">';
print_user_picture($activity->user->userid, $course, $activity->user->picture); print_user_picture($activity->user->userid, $course, $activity->user->picture);
print '</td><td width="100%"><font size="2">'; print '</td><td width="100%"><font size="2">';


Expand Down

0 comments on commit 4855134

Please sign in to comment.