diff --git a/main/lp/learnpath.class.php b/main/lp/learnpath.class.php
index 22394047c0..dcd452d042 100755
--- a/main/lp/learnpath.class.php
+++ b/main/lp/learnpath.class.php
@@ -3111,12 +3111,11 @@ class learnpath
'dir'
);
}
-
/**
* Uses the table generated by get_toc() and returns an HTML-formatted string ready to display
* @return string HTML TOC ready to display
*/
- public function get_html_toc($toc_list = null)
+ public function getListArrayToc($toc_list = null)
{
if ($this->debug > 0) {
error_log('In learnpath::get_html_toc()', 0);
@@ -3124,81 +3123,75 @@ class learnpath
if (empty($toc_list)) {
$toc_list = $this->get_toc();
}
- $html = '
';
- $html .= '
";
- return $html;
+
+ return $arrayList;
}
/**
diff --git a/main/lp/lp_view.php b/main/lp/lp_view.php
index 901e1285a2..d29bda333f 100755
--- a/main/lp/lp_view.php
+++ b/main/lp/lp_view.php
@@ -540,10 +540,7 @@ $template->assign(
$template->assign('lp_author', $_SESSION['oLP']->get_author());
$template->assign('lp_mode', $_SESSION['oLP']->mode);
$template->assign('lp_title_scorm', $_SESSION['oLP']->name);
-$template->assign(
- 'lp_html_toc',
- $_SESSION['oLP']->get_html_toc($get_toc_list)
-);
+$template->assign('data_list', $_SESSION['oLP']->getListArrayToc($get_toc_list));
$template->assign('lp_id', $_SESSION['oLP']->lp_id);
$template->assign('lp_current_item_id', $_SESSION['oLP']->get_current_item_id());
diff --git a/main/template/default/learnpath/scorm_list.tpl b/main/template/default/learnpath/scorm_list.tpl
new file mode 100644
index 0000000000..2e0bc046cd
--- /dev/null
+++ b/main/template/default/learnpath/scorm_list.tpl
@@ -0,0 +1,26 @@
+{% if data_list is not empty %}
+
+
+
{{ lp_title_scorm }}
+
+
+
+{% endif %}
+{{ accorden_toc }}
\ No newline at end of file
diff --git a/main/template/default/learnpath/view.tpl b/main/template/default/learnpath/view.tpl
index 63733b2a91..f92cfc70f0 100644
--- a/main/template/default/learnpath/view.tpl
+++ b/main/template/default/learnpath/view.tpl
@@ -65,11 +65,8 @@
{# TOC layout #}
-
-
{{ lp_title_scorm }}
- {{ lp_html_toc }}
+ {% include template ~ '/learnpath/scorm_list.tpl' %}
-
{# end TOC layout #}