[svn r12842] Fixed parse error

skala
Yannick Warnier 19 years ago
parent 3acd17f0fa
commit 1b0508eee2
  1. 55
      main/newscorm/learnpath.class.php

@ -6569,32 +6569,20 @@ function display_thread_form($action = 'add', $id = 0, $extra_info = '')
$preq_max = $row['max_score'];
$return = $this->display_manipulate($item_id, TOOL_DOCUMENT);
$return .= '<div style="margin:3px 10px;">';
$return .= '<p class="lp_title">'.get_lang("AddEditPrerequisites").'</p>';
$return .= '<form method="POST">';
$return .= '<table class="lp_form">';
$return .= '<tr>';
$return .= '<th></th>';
$return .= '<th class="exercise">'.get_lang("Minimum").'</th>';
$return .= '<th class="exercise">'.get_lang("Maximum").'</th>';
$return .= '</tr>';
$return .= '<tr>';
$return .= '<td class="radio" colspan="3">';
$return .= '<input checked="checked" id="idNone" name="prerequisites" style="margin-left:0; margin-right:10px;" type="radio" />';
$return .= '<label for="idNone">'.get_lang("None").'</label>';
$return .= '</td>';
$return .= '</tr>';
$sql = "
@ -6604,9 +6592,7 @@ function display_thread_form($action = 'add', $id = 0, $extra_info = '')
lp_id = " . $this->lp_id;
$result = api_sql_query($sql, __FILE__, __LINE__);
$arrLP = array();
while($row = Database::fetch_array($result))
{
$arrLP[] = array(
@ -6633,74 +6619,41 @@ function display_thread_form($action = 'add', $id = 0, $extra_info = '')
{
if($arrLP[$i]['id'] == $item_id)
break;
$return .= '<tr>';
$return .= '<td class="radio"' . (($arrLP[$i]['item_type'] != TOOL_QUIZ) ? ' colspan="3"' : '') . '>';
$return .= '<input' . (($arrLP[$i]['id'] == $preq_id) ? ' checked="checked" ' : '') . (($arrLP[$i]['item_type'] == 'dokeos_module' || $arrLP[$i]['item_type'] == 'dokeos_chapter') ? ' disabled="disabled" ' : ' ') . 'id="id' . $arrLP[$i]['id'] . '" name="prerequisites" style="margin-left:' . $arrLP[$i]['depth'] * 10 . 'px; margin-right:10px;" type="radio" value="' . $arrLP[$i]['id'] . '" />';
$return .= '<img alt="" src="../img/lp_' . $arrLP[$i]['item_type'] . '.png" style="margin-right:5px;" title="" />';
$return .= '<label for="id' . $arrLP[$i]['id'] . '">' . stripslashes($arrLP[$i]['title']) . '</label>';
$return .= '</td>';
$return .= '<td class="radio"' . (($arrLP[$i]['item_type'] != TOOL_HOTPOTATOES) ? ' colspan="3"' : '') . '>';
$return .= '<td class="radio"' . (($arrLP[$i]['item_type'] != TOOL_HOTPOTATOES) ? ' colspan="3"' : '') . ' />';
if($arrLP[$i]['item_type'] == TOOL_QUIZ)
{
$return .= '<td class="exercise">';
$return .= '<input maxlength="3" name="min_' . $arrLP[$i]['id'] . '" type="text" value="' . (($arrLP[$i]['id'] == $preq_id) ? $preq_min : 0) . '" />';
$return .= '</td>';
$return .= '<td class="exercise">';
$return .= '<input maxlength="3" name="max_' . $arrLP[$i]['id'] . '" type="text" value="' . $arrLP[$i]['max_score'] . '" disabled="true" />';
$return .= '</td>';
}
if($arrLP[$i]['item_type'] == TOOL_HOTPOTATOES)
if($arrLP[$i]['item_type'] == TOOL_HOTPOTATOES)
{
$return .= '<td class="exercise">';
$return .= '<input maxlength="3" name="min_' . $arrLP[$i]['id'] . '" type="text" value="' . (($arrLP[$i]['id'] == $preq_id) ? $preq_min : 0) . '" />';
$return .= '</td>';
$return .= '<td class="exercise">';
$return .= '<input maxlength="3" name="max_' . $arrLP[$i]['id'] . '" type="text" value="' . $arrLP[$i]['max_score'] . '" disabled="true" />';
$return .= '</td>';
}
$return .='</tr>';
}
$return .= '<tr>';
$return .= '<td colspan="3">';
$return .= '<input class="button" name="submit_button" type="submit" value="'.get_lang("Ok").'" /></td>' . "\n";
$return .= '</td>';
$return .= '</tr>';
$return .= '</table>';
$return .= '</form>';
$return .= '</div>';
return $return;

Loading…
Cancel
Save