Adding array validation

skala
Julio Montoya 16 years ago
parent ce6c8e8618
commit cc36283250
  1. 6
      main/social/profile.php

@ -603,8 +603,10 @@ echo '<div id="social-profile-wrapper">';
// Images uploaded by course
$file_list = '';
foreach ($course_list_code as $course) {
$file_list.= UserManager::get_user_upload_files_by_course($user_id,$course['code']);
if (is_array($course_list_code) && count($course_list_code)>0) {
foreach ($course_list_code as $course) {
$file_list.= UserManager::get_user_upload_files_by_course($user_id,$course['code']);
}
}
if (!empty($file_list)) {

Loading…
Cancel
Save