[svn r21043] display error message correctly

display advanced parameters correctly
skala
Patrick Cool 16 years ago
parent 39007b7946
commit cc3cf64ab6
  1. 14
      main/work/work.lib.php
  2. 11
      main/work/work.php

@ -1,4 +1,4 @@
<?php //$Id: work.lib.php 20975 2009-05-25 18:09:56Z cvargas1 $
<?php //$Id: work.lib.php 21043 2009-05-28 14:35:45Z pcool $
/* For licensing terms, see /dokeos_license.txt */
/**
* @package dokeos.work
@ -6,7 +6,7 @@
* @author Patrick Cool <patrick.cool@UGent.be>, Ghent University - ability for course admins to specify wether uploaded documents are visible or invisible by default.
* @author Roan Embrechts, code refactoring and virtual course support
* @author Frederic Vauthier, directories management
* @version $Id: work.lib.php 20975 2009-05-25 18:09:56Z cvargas1 $
* @version $Id: work.lib.php 21043 2009-05-28 14:35:45Z pcool $
*/
/**
* Displays action links (for admins, authorized groups members and authorized students)
@ -37,7 +37,7 @@ function display_action_links($cur_dir_path, $always_show_tool_options, $always_
}
if (! $always_show_tool_options && api_is_allowed_to_edit() && $origin != 'learnpath') {
// Create dir
$display_output .= '<a href="'.api_get_self().'?'.api_get_cidreq().'&amp;toolgroup='.Security::remove_XSS($_GET['toolgroup']).'&amp;curdirpath='.$cur_dir_path.'&amp;createdir=1&origin='.$origin.'&gradebook='.$gradebook.'"><img src="../img/folder_new.gif" border="0" alt="'.get_lang('CreateAssignment').'" title ="'.get_lang('CreateAssignment').'" /> '.get_lang('CreateAssignment').' </a>';
$display_output .= '<a href="'.api_get_self().'?'.api_get_cidreq().'&amp;toolgroup='.Security::remove_XSS($_GET['toolgroup']).'&amp;curdirpath='.$cur_dir_path.'&amp;createdir=1&origin='.$origin.'&gradebook='.$gradebook.'">'.Display::return_icon('folder_new.gif', get_lang('CreateAssignment')).' '.get_lang('CreateAssignment').' </a>';
// Options
$display_output .= "<a href=\"".api_get_self()."?".api_get_cidreq()."&curdirpath=".$cur_dir_path."&amp;origin=".$origin."&amp;display_tool_options=true&amp;origin=".$origin."&amp;gradebook=".$gradebook."\">".Display::return_icon('acces_tool.gif', get_lang("EditToolOptions")).' ' . get_lang("EditToolOptions") . "</a>";
}
@ -65,11 +65,11 @@ function display_action_links($cur_dir_path, $always_show_tool_options, $always_
if ($columnStatus['Default'] == 1) {
$display_output .= "<a href=\"".api_get_self()."?".api_get_cidreq()."&curdirpath=".$cur_dir_path."&amp;origin=$origin&amp;gradebook=$gradebook&amp;make_invisible=all\">".
Display::return_icon('visible.gif', get_lang('Visible')).' '.get_lang('MakeInvisible').
Display::return_icon('invisible.gif', get_lang('MakeAllPapersInvisible')).' '.get_lang('MakeAllPapersInvisible').
"</a>\n";
} else {
$display_output .= "<a href=\"".api_get_self()."?".api_get_cidreq()."&amp;curdirpath=".$cur_dir_path."&amp;origin=$origin&amp;gradebook=$gradebook&amp;make_visible=all\">".
Display::return_icon('invisible.gif', get_lang('Invisible')).' '.get_lang('MakeVisible').
Display::return_icon('visible.gif', get_lang('MakeAllPapersVisible')).' '.get_lang('MakeAllPapersVisible').
"</a>\n";
}
}
@ -1181,10 +1181,10 @@ function to_javascript_work() {
function plus() {
if(document.getElementById(\'options\').style.display == \'none\') {
document.getElementById(\'options\').style.display = \'block\';
document.getElementById(\'plus\').innerHTML=\'&nbsp;<img src="../img/div_hide.gif" alt="" />&nbsp;'.addslashes(get_lang('AdvancedParameters')).'\';
document.getElementById(\'plus\').innerHTML=\'&nbsp;'.Display::return_icon('div_hide.gif').'&nbsp;'.addslashes(get_lang('AdvancedParameters')).'\';
} else {
document.getElementById(\'options\').style.display = \'none\';
document.getElementById(\'plus\').innerHTML=\'&nbsp;<img src="../img/div_show.gif" alt="" />&nbsp;'.addslashes(get_lang('AdvancedParameters')).'\';
document.getElementById(\'plus\').innerHTML=\'&nbsp;'.Display::return_icon('div_show.gif').'&nbsp;'.addslashes(get_lang('AdvancedParameters')).'\';
}
}

@ -1,4 +1,4 @@
<?php //$Id: work.php 20975 2009-05-25 18:09:56Z cvargas1 $
<?php //$Id: work.php 21043 2009-05-28 14:35:45Z pcool $
/* For licensing terms, see /dokeos_license.txt */
/**
* @package dokeos.work
@ -6,7 +6,7 @@
* @author Patrick Cool <patrick.cool@UGent.be>, Ghent University - ability for course admins to specify wether uploaded documents are visible or invisible by default.
* @author Roan Embrechts, code refactoring and virtual course support
* @author Frederic Vauthier, directories management
* @version $Id: work.php 20975 2009-05-25 18:09:56Z cvargas1 $
* @version $Id: work.php 21043 2009-05-28 14:35:45Z pcool $
*
* @todo refactor more code into functions, use quickforms, coding standards, ...
*/
@ -1271,12 +1271,12 @@ function draw_date_picker($prefix,$default='') {
$new_folder_text .= '<div class="row"><div class="form_header">'.get_lang('CreateAssignment').'</div></div>';
$new_folder_text .= '<input type="hidden" name="curdirpath" value="' . Security :: remove_XSS($cur_dir_path) . '"/>';
$new_folder_text .= '<input type="hidden" name="sec_token" value="'.$stok.'" />';
$new_folder_text .= '<div id="msg_error1" style="display:none;color:red"></div>';
$new_folder_text .= '<div class="row">
<div class="label">
<span class="form_required">*</span>'.get_lang('AssignmentName').'
<span class="form_required">*</span> '.get_lang('AssignmentName').'
</div>
<div class="formw">
<div id="msg_error1" style="display:none;color:red"></div>
<input type="text" name="new_dir" onfocus="document.getElementById(\'msg_error1\').style.display=\'none\';"/>
</div>
</div>';
@ -1323,8 +1323,9 @@ function draw_date_picker($prefix,$default='') {
$new_folder_text .= '<div class="row">
<div class="label">
<a href="#" onclick=" return plus();"><span id="plus">'.Display::return_icon('div_show.gif',get_lang('AdvancedParameters')).' '.get_lang('AdvancedParameters').'</span></a><br />
</div>
<div class="formw"><br /><a href="#" onclick=" return plus();"><span id="plus">'.Display::return_icon('div_show.gif',get_lang('AdvancedParameters')).' '.get_lang('AdvancedParameters').'</span></a><br />
<div class="formw">
'.$addtext.'
</div>
</div>';

Loading…
Cancel
Save