@@ -80,24 +80,26 @@ function confirmation(name) {
8080
8181if ($ is_allowed_to_edit ) {
8282 $ actionLeft = '' ;
83- $ actionLeft .= Display::url (
84- Display::return_icon (
85- 'new_learnpath.png ' ,
86- get_lang ('LearnpathAddLearnpath ' ),
87- '' ,
88- ICON_SIZE_MEDIUM
89- ),
90- api_get_self ().'? ' .api_get_cidreq ().'&action=add_lp '
91- );
92- $ actionLeft .= Display::url (
93- Display::return_icon (
94- 'import_scorm.png ' ,
95- get_lang ('UploadScorm ' ),
96- '' ,
97- ICON_SIZE_MEDIUM
98- ),
99- '../upload/index.php? ' .api_get_cidreq ().'&curdirpath=/&tool= ' .TOOL_LEARNPATH
100- );
83+ if (!(api_get_configuration_value ('session_hide_lp_creation ' ) === true && (isset ($ sessionId ) && $ sessionId != 0 ))) {
84+ $ actionLeft .= Display::url (
85+ Display::return_icon (
86+ 'new_learnpath.png ' ,
87+ get_lang ('LearnpathAddLearnpath ' ),
88+ '' ,
89+ ICON_SIZE_MEDIUM
90+ ),
91+ api_get_self ().'? ' .api_get_cidreq ().'&action=add_lp '
92+ );
93+ $ actionLeft .= Display::url (
94+ Display::return_icon (
95+ 'import_scorm.png ' ,
96+ get_lang ('UploadScorm ' ),
97+ '' ,
98+ ICON_SIZE_MEDIUM
99+ ),
100+ '../upload/index.php? ' .api_get_cidreq ().'&curdirpath=/&tool= ' .TOOL_LEARNPATH
101+ );
102+ }
101103
102104 if (api_get_setting ('service_ppt2lp ' , 'active ' ) === 'true ' ) {
103105 $ actionLeft .= Display::url (
@@ -200,6 +202,7 @@ function confirmation(name) {
200202$ hideScormExportLink = api_get_setting ('hide_scorm_export_link ' );
201203$ hideScormCopyLink = api_get_setting ('hide_scorm_copy_link ' );
202204$ hideScormPdfLink = api_get_setting ('hide_scorm_pdf_link ' );
205+ $ hideLpCopyInSession = (api_get_configuration_value ('session_hide_lp_copy ' ) === true && (isset ($ sessionId ) && $ sessionId != 0 ));
203206$ options = learnpath::getIconSelect ();
204207$ cidReq = api_get_cidreq ();
205208
@@ -925,7 +928,7 @@ function confirmation(name) {
925928 $ dsp_disk = null ;
926929 }
927930
928- if ($ hideScormCopyLink === 'true ' ) {
931+ if ($ hideScormCopyLink === 'true ' || $ hideLpCopyInSession ) {
929932 $ copy = null ;
930933 }
931934
0 commit comments