|
@@ 3300-3305 (lines=6) @@
|
| 3297 |
|
if ($this->debug > 0) { |
| 3298 |
|
error_log('New LP - In learnpath::get_link('.$type.','.$item_id.')', 0); |
| 3299 |
|
} |
| 3300 |
|
if (empty($item_id)) { |
| 3301 |
|
if ($this->debug > 2) { |
| 3302 |
|
error_log('New LP - In learnpath::get_link() - no item id given in learnpath::get_link(), using current: '.$this->get_current_item_id(), 0); |
| 3303 |
|
} |
| 3304 |
|
$item_id = $this->get_current_item_id(); |
| 3305 |
|
} |
| 3306 |
|
|
| 3307 |
|
if (empty($item_id)) { |
| 3308 |
|
if ($this->debug > 2) { |
|
@@ 3307-3315 (lines=9) @@
|
| 3304 |
|
$item_id = $this->get_current_item_id(); |
| 3305 |
|
} |
| 3306 |
|
|
| 3307 |
|
if (empty($item_id)) { |
| 3308 |
|
if ($this->debug > 2) { |
| 3309 |
|
error_log('New LP - In learnpath::get_link() - no current item id found in learnpath object', 0); |
| 3310 |
|
} |
| 3311 |
|
//still empty, this means there was no item_id given and we are not in an object context or |
| 3312 |
|
//the object property is empty, return empty link |
| 3313 |
|
$item_id = $this->first(); |
| 3314 |
|
return ''; |
| 3315 |
|
} |
| 3316 |
|
|
| 3317 |
|
$file = ''; |
| 3318 |
|
$lp_table = Database::get_course_table(TABLE_LP_MAIN); |