[svn r10303] Better display in the edit menu for the audiorecorder and the edit links

increase the height of the audiorecorder frame
skala
Eric Marguin 19 years ago
parent eeefdd3a24
commit d6ec2c010b
  1. 2
      main/newscorm/audiorecorder.inc.php
  2. 116
      main/newscorm/learnpath.class.php
  3. 2
      main/newscorm/learnpath.css
  4. 2
      main/newscorm/lp_view.php

@ -11,7 +11,7 @@
$params = "?lzt=swf&lzr=swf8&document_id=".$audio_recorder_item_id."&dbName=".$_SESSION["_course"]["dbName"]."&user_id=".$_SESSION["_user"]["user_id"].'?studentview='.$audio_recorder_studentview ; $params = "?lzt=swf&lzr=swf8&document_id=".$audio_recorder_item_id."&dbName=".$_SESSION["_course"]["dbName"]."&user_id=".$_SESSION["_user"]["user_id"].'?studentview='.$audio_recorder_studentview ;
list($width, $height) = $audio_recorder_studentview ? array(220, 75) : array(220,140); list($width, $height) = $audio_recorder_studentview ? array(220, 185) : array(220,140);
$path_to_lzx = api_get_setting('service_ppt2lp','path_to_lzx'); $path_to_lzx = api_get_setting('service_ppt2lp','path_to_lzx');

@ -2647,7 +2647,7 @@ class learnpath {
//if(empty($parent)){$parent = $this->ordered_items[$this->items[$this->current]->get_previous_index()];} //if(empty($parent)){$parent = $this->ordered_items[$this->items[$this->current]->get_previous_index()];}
$html .= '<div class="inner_lp_toc">'."\n" ; $html .= '<div class="inner_lp_toc">'."\n" ;
if($_SESSION["is_courseAdmin"]==1){ if($_SESSION["is_courseAdmin"]==1){
$html.="<a style='font-size: 11px' href='lp_controller.php?cidReq=".$_SESSION['_cid']."&action=admin_view&lp_id=".$this->lp_id."' target='_parent'>".get_lang("BasicOverview")."</a>-<a href='lp_controller.php?cidReq=".$_SESSION['_cid']."&action=build&lp_id=".$this->lp_id."' style='font-size: 11px' target='_parent'>".get_lang("Advanced")."</a><br><br>"; $html.="<a style='font-size: 11px' href='lp_controller.php?cidReq=".$_SESSION['_cid']."&action=admin_view&lp_id=".$this->lp_id."' target='_parent'>".get_lang("BasicOverview")."</a> - <a href='lp_controller.php?cidReq=".$_SESSION['_cid']."&action=build&lp_id=".$this->lp_id."' style='font-size: 11px' target='_parent'>".get_lang("Advanced")."</a><br><br>";
} }
// " onchange=\"javascript:document.getElementById('toc_$parent').focus();\">\n"; // " onchange=\"javascript:document.getElementById('toc_$parent').focus();\">\n";
require_once('resourcelinker.inc.php'); require_once('resourcelinker.inc.php');
@ -4572,9 +4572,9 @@ class learnpath {
$return .= $msg; $return .= $msg;
$return .= '<p class="lp_title">' . stripslashes($row['title']) . '</p>'; $return .= '<p class="lp_title">' . stripslashes($row['title']) . '</p>';
$return .= '<p class="lp_text">' . ((trim($row['description']) == '') ? 'no description' : stripslashes($row['description'])) . '</p>'; //$return .= '<p class="lp_text">' . ((trim($row['description']) == '') ? 'no description' : stripslashes($row['description'])) . '</p>';
$return .= '<hr />'; //$return .= '<hr />';
if($row['item_type'] == TOOL_DOCUMENT) if($row['item_type'] == TOOL_DOCUMENT)
$return .= $this->display_document($row['path'], true, true); $return .= $this->display_document($row['path'], true, true);
@ -4755,7 +4755,7 @@ class learnpath {
$row_doc = Database::fetch_array($res_doc); $row_doc = Database::fetch_array($res_doc);
if($show_title) if($show_title)
$return .= '<p class="lp_title">' . $row_doc['title'] . ($edit_link ? ' [ <a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=add_item&amp;type=' . TOOL_DOCUMENT . '&amp;file=' . $_GET['file'] . '&amp;edit=true&amp;lp_id=' . $_GET['lp_id'] . '">Edit this document</a> ]' : '') . '</p>'; //$return .= '<p class="lp_title">' . $row_doc['title'] . ($edit_link ? ' [ <a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=add_item&amp;type=' . TOOL_DOCUMENT . '&amp;file=' . $_GET['file'] . '&amp;edit=true&amp;lp_id=' . $_GET['lp_id'] . '">Edit this document</a> ]' : '') . '</p>';
//TODO: add a path filter //TODO: add a path filter
if($iframe) if($iframe)
@ -5928,59 +5928,75 @@ class learnpath {
*/ */
function display_manipulate($item_id, $item_type = TOOL_DOCUMENT) function display_manipulate($item_id, $item_type = TOOL_DOCUMENT)
{ {
$return = '<div class="lp_manipulate">'; $return = '<div class="lp_manipulate"><table border="0" width="100%"><tr><td valign="top" width="400">';
switch($item_type) switch($item_type)
{ {
case 'dokeos_chapter': case 'dokeos_chapter':
case 'chapter': case 'chapter':
$lang = get_lang('TitleManipulateChapter');
break;
case 'dokeos_module':
case 'module':
$lang = get_lang('TitleManipulateModule');
break;
case TOOL_DOCUMENT:
$lang = get_lang('TitleManipulateDocument');
break;
case TOOL_LINK: $lang = get_lang('TitleManipulateChapter');
case 'link': break;
$lang = get_lang('TitleManipulateLink');
break;
case TOOL_QUIZ: case 'dokeos_module':
case 'module':
$lang = get_lang('TitleManipulateQuiz');
break;
case TOOL_STUDENTPUBLICATION: $lang = get_lang('TitleManipulateModule');
$lang = get_lang('TitleManipulateStudentPublication'); break;
break; case TOOL_DOCUMENT:
}
$lang = get_lang('TitleManipulateDocument');
$return .= '<p class="lp_title">' . $lang . '</p>';
break;
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=edit_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="Edit the current item"><img align="absbottom" alt="Edit the current item" src="../img/edit.gif" title="Edit the current item" /> '.get_lang("Edit").'</a>'; case TOOL_LINK:
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=move_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="Move the current item"><img align="absbottom" alt="Move the current item" src="../img/deplacer_fichier.gif" title="Move the current item" /> '.get_lang("Move").'</a>'; case 'link':
$lang = get_lang('TitleManipulateLink');
break;
if($item_type != 'chapter' && $item_type != 'dokeos_chapter' && $item_type != 'module' && $item_type != 'dokeos_module') case TOOL_QUIZ:
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=edit_item_prereq&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="'.get_lang("langEditPrerequisites").'"><img align="absbottom" alt="'.get_lang("langEditPrerequisites").'" src="../img/asterisk_prerequisites.gif" title="'.get_lang("langEditPrerequisites").'" /> '.get_lang("Prerequisites").'</a>';
$lang = get_lang('TitleManipulateQuiz');
break;
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=delete_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" onclick="return confirmation(\'' . $row['title'] . '\');" title="Delete the current item"><img alt="Delete the current item" align="absbottom" src="../img/delete.gif" title="Delete the current item" /> '.get_lang("Delete").'</a>'; case TOOL_STUDENTPUBLICATION:
$lang = get_lang('TitleManipulateStudentPublication');
break;
}
$tbl_lp_item = Database::get_course_table('lp_item');
$sql = "
SELECT
description
FROM " . $tbl_lp_item . " as lp
WHERE
lp.id = " . $item_id;
$result = api_sql_query($sql, __FILE__, __LINE__);
$s_description=mysql_result($result,0,0);
$return .= '<p class="lp_title">' . $lang . '</p>';
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=edit_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="Edit the current item"><img align="absbottom" alt="Edit the current item" src="../img/edit.gif" title="Edit the current item" /> '.get_lang("Edit").'</a>';
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=move_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="Move the current item"><img align="absbottom" alt="Move the current item" src="../img/deplacer_fichier.gif" title="Move the current item" /> '.get_lang("Move").'</a>';
if($item_type != 'chapter' && $item_type != 'dokeos_chapter' && $item_type != 'module' && $item_type != 'dokeos_module')
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=edit_item_prereq&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" title="'.get_lang("langEditPrerequisites").'"><img align="absbottom" alt="'.get_lang("langEditPrerequisites").'" src="../img/asterisk_prerequisites.gif" title="'.get_lang("langEditPrerequisites").'" /> '.get_lang("Prerequisites").'</a>';
$return .= '<a href="' . $_SERVER['PHP_SELF'] . '?cidReq=' . $_GET['cidReq'] . '&amp;action=delete_item&amp;view=build&amp;id=' . $item_id . '&amp;lp_id=' . $this->lp_id . '" onclick="return confirmation(\'' . $row['title'] . '\');" title="Delete the current item"><img alt="Delete the current item" align="absbottom" src="../img/delete.gif" title="Delete the current item" /> '.get_lang("Delete").'</a>';
$return .= '<br><br><p class="lp_text">' . ((trim($s_description) == '') ? ''.get_lang("NoDescription").'' : stripslashes(nl2br($s_description))) . '</p>';
$return.="</td><td valign='top'>";
// get the audiorecorder. Use of ob_* functions since there are echos in the file // get the audiorecorder. Use of ob_* functions since there are echos in the file
ob_start(); ob_start();
@ -5993,6 +6009,8 @@ class learnpath {
ob_end_clean(); ob_end_clean();
// end of audiorecorder include // end of audiorecorder include
$return.="</td></tr></table>";
$return .= '</div>'; $return .= '</div>';

@ -8,7 +8,7 @@ div.lp_small_form{background:#F8F8F8; border:1px solid #999999; padding:10px;}
div.lp_small_form input{font-size:10px;} div.lp_small_form input{font-size:10px;}
div.lp_manipulate{background:#F8F8F8; border-bottom:1px dotted #999999; margin-bottom:10px; padding:3px 0 3px 10px;} div.lp_manipulate{background:#F8F8F8; border-bottom:1px dotted #999999; margin-bottom:0px; padding:3px 0 3px 10px;}
div.lp_manipulate a{padding-right:10px;} div.lp_manipulate a{padding-right:10px;}

@ -160,7 +160,7 @@ if($_SESSION['oLP']->mode == 'fullscreen'){
<frameset rows="150,600"> <frameset rows="150,600">
<frame id="header" src="lp_header.php" border="0" frameborder="0" /> <frame id="header" src="lp_header.php" border="0" frameborder="0" />
<frameset cols="180,*"> <frameset cols="180,*">
<frameset rows="<?php if($displayAudioRecorder) echo '75,';?>310,150,80,*"> <frameset rows="<?php if($displayAudioRecorder) echo '185,';?>310,150,80,*">
<?php <?php
if($displayAudioRecorder) if($displayAudioRecorder)
echo '<frame id="audiorecorder_id" name="audiorecorder_name" src="display_audiorecorder.php" border="0" frameborder="0" scrolling="no"/>'; echo '<frame id="audiorecorder_id" name="audiorecorder_name" src="display_audiorecorder.php" border="0" frameborder="0" scrolling="no"/>';

Loading…
Cancel
Save