@@ 9381-9393 (lines=13) @@ | ||
9378 | $my_item->appendChild($my_masteryscore); |
|
9379 | ||
9380 | // Attach this item to the organization element or its parent if there is one. |
|
9381 | if (!empty($item->parent) && $item->parent != 0) { |
|
9382 | $children = $organization->childNodes; |
|
9383 | for ($i = 0; $i < $children->length; $i++) { |
|
9384 | $item_temp = $children->item($i); |
|
9385 | if ($item_temp -> nodeName == 'item') { |
|
9386 | if ($item_temp->getAttribute('identifier') == 'ITEM_'.$item->parent) { |
|
9387 | $item_temp -> appendChild($my_item); |
|
9388 | } |
|
9389 | } |
|
9390 | } |
|
9391 | } else { |
|
9392 | $organization->appendChild($my_item); |
|
9393 | } |
|
9394 | ||
9395 | $my_file_path = 'link_'.$item->get_id().'.html'; |
|
9396 | $sql = 'SELECT url, title FROM '.Database :: get_course_table(TABLE_LINK).' |
|
@@ 9445-9457 (lines=13) @@ | ||
9442 | $my_item->appendChild($my_masteryscore); |
|
9443 | ||
9444 | // Attach this item to the organization element or hits parent if there is one. |
|
9445 | if (!empty($item->parent) && $item->parent != 0) { |
|
9446 | $children = $organization->childNodes; |
|
9447 | for ($i = 0; $i < $children->length; $i++) { |
|
9448 | $item_temp = $children->item($i); |
|
9449 | if ($item_temp -> nodeName == 'item') { |
|
9450 | if ($item_temp->getAttribute('identifier') == 'ITEM_'.$item->parent) { |
|
9451 | $item_temp -> appendChild($my_item); |
|
9452 | } |
|
9453 | } |
|
9454 | } |
|
9455 | } else { |
|
9456 | $organization->appendChild($my_item); |
|
9457 | } |
|
9458 | ||
9459 | // Get the path of the file(s) from the course directory root |
|
9460 | //$my_file_path = $item->get_file_path('scorm/'.$this->path.'/'); |