Replacing 40 with the new constant + minor style fixes see #4548

skala
Julio Montoya 14 years ago
parent 56751cf036
commit c3f14c54ae
  1. 8
      main/create_course/add_course.php

@ -49,7 +49,6 @@ function setFocus(){
setFocus(); setFocus();
}); });
function advanced_parameters() { function advanced_parameters() {
if(document.getElementById(\'options\').style.display == \'none\') { if(document.getElementById(\'options\').style.display == \'none\') {
document.getElementById(\'options\').style.display = \'block\'; document.getElementById(\'options\').style.display = \'block\';
@ -78,16 +77,11 @@ if (!api_is_allowed_to_create_course()) {
exit; exit;
} }
global $_configuration;
//$dbnamelength = strlen($_configuration['db_prefix']);
// Ensure the database prefix + database name do not get over 40 characters.
$maxlength = 40;
// Build the form. // Build the form.
$form = new FormValidator('add_course'); $form = new FormValidator('add_course');
// Form title // Form title
$form->addElement('header', '', $tool_name); $form->addElement('header', $tool_name);
// Title // Title
$form->addElement('text', 'title', array(get_lang('CourseName'), get_lang('Ex')), array('class' => 'span6', 'id' => 'title')); $form->addElement('text', 'title', array(get_lang('CourseName'), get_lang('Ex')), array('class' => 'span6', 'id' => 'title'));

Loading…
Cancel
Save