From 335d662cf4619ca0640e4b337c3854c6790dcb93 Mon Sep 17 00:00:00 2001 From: Julio Montoya Date: Thu, 28 Aug 2008 01:05:17 +0200 Subject: [PATCH] [svn r16089] Lp Improvements FS#2841 --- main/css/public_admin/scorm.css | 10 ++--- main/newscorm/display_audiorecorder.php | 37 ++++-------------- main/newscorm/learnpath.class.php | 8 +++- main/newscorm/lp_author_image.php | 44 +++++++++++++++++++++ main/newscorm/lp_header.php | 4 +- main/newscorm/lp_nav.php | 4 +- main/newscorm/lp_view.php | 51 ++++++++++--------------- 7 files changed, 89 insertions(+), 69 deletions(-) create mode 100644 main/newscorm/lp_author_image.php diff --git a/main/css/public_admin/scorm.css b/main/css/public_admin/scorm.css index 8097419d02..1db98e0af4 100644 --- a/main/css/public_admin/scorm.css +++ b/main/css/public_admin/scorm.css @@ -96,9 +96,9 @@ .inner_lp_toc .scorm_title { font-weight: bold; - background:#305582; - font-size: 12px; - color: #fff; + background:#ccc; + font-size: 14px; + color: #444; } .inner_lp_toc .scorm_title_text @@ -134,7 +134,7 @@ } /*.scormpage .menu */ .lp_navigation_elem .progresstext{ - margin-top: -15px; + margin-top: -20px; margin-left: 5em; font-size: normal; } @@ -180,7 +180,7 @@ #preview_image { - padding-left: 17px; + text-align:center; } #msg_div_id{ diff --git a/main/newscorm/display_audiorecorder.php b/main/newscorm/display_audiorecorder.php index fdad706257..aefb7b0b22 100644 --- a/main/newscorm/display_audiorecorder.php +++ b/main/newscorm/display_audiorecorder.php @@ -31,38 +31,17 @@ $lp_theme_css=$_SESSION['oLP']->get_theme(); $scorm_css_header=true; include_once('../inc/reduced_header.inc.php'); - echo ' '; -$html=''; - -if ($_GET['show_audio']) -{ - echo '
'."\n"; - if ($_SESSION['oLP']->get_preview_image()!='') - echo ''.$_SESSION['oLP']->get_author().'get_preview_image().'>'; - else - echo Display::display_icon('unknown.jpg',$_SESSION['oLP']->get_author()); - echo '
'; - echo '
'; - $audio_recorder_studentview = 'true'; - $audio_recorder_item_id = $_SESSION['oLP']->current; - if(api_get_setting('service_visio','active')=='true'){ - include('audiorecorder.inc.php'); - } - echo '
'; - // end of audiorecorder include -} -else -{ - echo '
'."\n"; - if ($_SESSION['oLP']->get_preview_image()!='') - echo ''.$_SESSION['oLP']->get_author().'get_preview_image().'>'; - else - echo Display::display_icon('unknown.jpg',$_SESSION['oLP']->get_author()); - echo '
'; -} + echo '
'; + $audio_recorder_studentview = 'true'; + $audio_recorder_item_id = $_SESSION['oLP']->current; + if(api_get_setting('service_visio','active')=='true'){ + include('audiorecorder.inc.php'); + } + echo '
'; + // end of audiorecorder include echo ''; ?> \ No newline at end of file diff --git a/main/newscorm/learnpath.class.php b/main/newscorm/learnpath.class.php index ee6748c24f..47292d541b 100644 --- a/main/newscorm/learnpath.class.php +++ b/main/newscorm/learnpath.class.php @@ -1912,9 +1912,10 @@ class learnpath { * @param string Mode in which we want the values * @param integer Progress value to display (optional but mandatory if used in abstract context) * @param string Text to display near the progress value (optional but mandatory in abstract context) + * @param boolean true if it comes from a Diplay LP view * @return string HTML string containing the progress bar */ - function get_progress_bar($mode='',$percentage=-1,$text_add='') + function get_progress_bar($mode='',$percentage=-1,$text_add='',$from_lp=false) { global $lp_theme_css; @@ -1937,7 +1938,10 @@ class learnpath { //Default progress bar config $factor=1.5; - $progress_height='16'; + if ($from_lp) + $progress_height='25'; + else + $progress_height='16'; $size = str_replace('%','',$percentage); $output = '' diff --git a/main/newscorm/lp_author_image.php b/main/newscorm/lp_author_image.php new file mode 100644 index 0000000000..18240c887d --- /dev/null +++ b/main/newscorm/lp_author_image.php @@ -0,0 +1,44 @@ +encoding; +$lp_theme_css=$_SESSION['oLP']->get_theme(); + +*/ +$scorm_css_header=true; +include_once('../inc/reduced_header.inc.php'); + +echo ' + '; +echo '
'; +if ($_SESSION['oLP']->get_preview_image()!='') + echo ''.$_SESSION['oLP']->get_author().''; +else + echo Display::display_icon('unknown.jpg',$_SESSION['oLP']->get_author()); +echo '
'; + +?> + + \ No newline at end of file diff --git a/main/newscorm/lp_header.php b/main/newscorm/lp_header.php index 894319b201..50f9a3f720 100644 --- a/main/newscorm/lp_header.php +++ b/main/newscorm/lp_header.php @@ -59,9 +59,9 @@ $interbreadcrumb[] = array("url"=>"./lp_controller.php?action=view&lp_id=".$path $noPHP_SELF = true; $lp_theme_css=$_SESSION['oLP']->get_theme(); include('../inc/reduced_header.inc.php'); -echo '
'; +echo '
'; echo ''.get_lang('CourseHomepageLink').''; -echo '
'; +echo '
'; ?> \ No newline at end of file diff --git a/main/newscorm/lp_nav.php b/main/newscorm/lp_nav.php index 20841afb6a..5f2876f891 100644 --- a/main/newscorm/lp_nav.php +++ b/main/newscorm/lp_nav.php @@ -58,7 +58,9 @@ if(isset($_SESSION['lpobject'])) $lp_theme_css=$my_style; } - $progress_bar = $_SESSION['oLP']->get_progress_bar(); + //$progress_bar = $_SESSION['oLP']->get_progress_bar(); + $progress_bar = $_SESSION['oLP']->get_progress_bar('',-1,'',true); + $navigation_bar = $_SESSION['oLP']->get_navigation_bar(); } session_write_close(); ?> diff --git a/main/newscorm/lp_view.php b/main/newscorm/lp_view.php index f32605da4a..065b427711 100644 --- a/main/newscorm/lp_view.php +++ b/main/newscorm/lp_view.php @@ -174,39 +174,30 @@ else //set flag to ensure lp_header.php is loaded by this script (flag is unset in lp_header.php) $_SESSION['loaded_lp_view'] = true; $audio_record_width=''; - if ($displayAudioRecorder || $_SESSION['oLP']->get_preview_image()!='') - { - if ($displayAudioRecorder) - $audio_record_width='170,'; - else - $audio_record_width='120,'; - } + + if ($displayAudioRecorder) + $audio_record_width='120,'; else - { - $audio_record_width=''; - } + $audio_record_width='120,'; + + ?> - - - - get_preview_image()!='') - { - if($displayAudioRecorder) //if audio recorder is required (set a few lines above) - echo ''; - else - echo ''; - } - ?> - - - - - - - - + + + + + '; + ?> + + + + + + + This page relies heavily on frames. If your browser doesn't support frames, please try to find a better one. Some are available for free and run on multiple platforms. We recommend you try <a href="http://www.mozilla.com/firefox/">Firefox</a>. Get it from its official website by clicking the link.