$current = $this->get_setting();
}
return format_admin_setting('text', $this->name, $this->visiblename,
- '<input type="text" size="50" id="id_s_'.$this->name.'" name="s_'.$this->name.'" value="'.$current.'" />',
+ '<input type="text" size="50" class="form-text" class="form-text" id="id_s_'.$this->name.'" name="s_'.$this->name.'" value="'.$current.'" />',
$this->description);
}
$current = $this->get_setting();
}
return format_admin_setting('checkbox', $this->name, $this->visiblename,
- '<input type="checkbox" size="50" id="id_s_'.$this->name.'" name="s_'. $this->name .'" value="1" ' . ($current == true ? 'checked="checked"' : '') . ' />',
+ '<input type="checkbox" size="50" class="form-checkbox" id="id_s_'.$this->name.'" name="s_'. $this->name .'" value="1" ' . ($current == true ? 'checked="checked"' : '') . ' />',
$this->description);
}
} else {
$current = $this->get_setting();
}
- $return = '<select id="id_s_'.$this->name.'" name="s_' . $this->name .'">';
+ $return = '<select class="form-select" id="id_s_'.$this->name.'" name="s_' . $this->name .'">';
foreach ($this->choices as $key => $value) {
$return .= '<option value="'.$key.'"'.($key==$current ? ' selected="selected"' : '').'>'.$value.'</option>';
}
} else {
$currentsetting = $this->get_setting();
}
- $return = '<select id="id_s_'.$this->name.'h" name="s_' . $this->name .'[h]">';
+ $return = '<select class="form-select" id="id_s_'.$this->name.'h" name="s_' . $this->name .'[h]">';
foreach ($this->choices as $key => $value) {
$return .= '<option value="' . $key . '"' . ($key == $currentsetting['h'] ? ' selected="selected"' : '') . '>' . $value . '</option>';
}
- $return .= '</select> <select id="id_s_'.$this->name.'m" name="s_' . $this->name . '[m]">';
+ $return .= '</select> <select class="form-select" id="id_s_'.$this->name.'m" name="s_' . $this->name . '[m]">';
foreach ($this->choices2 as $key => $value) {
$return .= '<option value="' . $key . '"' . ($key == $currentsetting['m'] ? ' selected="selected"' : '') . '>' . $value . '</option>';
}
} else {
$currentsetting = $this->get_setting();
}
- $return = '<select id="id_s_'.$this->name.'" name="s_' . $this->name .'[]" size="10" multiple="multiple">';
+ $return = '<select class="form-select" id="id_s_'.$this->name.'" name="s_' . $this->name .'[]" size="10" multiple="multiple">';
foreach ($this->choices as $key => $value) {
$return .= '<option value="' . $key . '"' . (in_array($key,$currentsetting) ? ' selected="selected"' : '') . '>' . $value . '</option>';
}
}
$return = '';
for ($i = 0; $i < count($this->choices) - 1; $i++) {
- $return .='<select id="id_s_'.$this->name.'" name="s_' . $this->name .'[]">';
+ $return .='<select class="form-select" id="id_s_'.$this->name.'" name="s_' . $this->name .'[]">';
foreach ($this->choices as $key => $value) {
$return .= '<option value="' . $key . '"' . ($key == $currentsetting[$i] ? ' selected="selected"' : '') . '>' . $value . '</option>';
}
$return = '';
for ($i = 0; $i < count($currentsetting) / 2; $i++) {
- $return .= '<input type="text" name="s_editorfontlist[k' . $i . ']" value="' . $currentsetting['k' . $i] . '" size="20" />';
+ $return .= '<input type="text" class="form-text" name="s_editorfontlist[k' . $i . ']" value="' . $currentsetting['k' . $i] . '" size="20" />';
$return .= ' ';
- $return .= '<input type="text" name="s_editorfontlist[v' . $i . ']" value="' . $currentsetting['v' . $i] . '" size="40" /><br />';
+ $return .= '<input type="text" class="form-text" name="s_editorfontlist[v' . $i . ']" value="' . $currentsetting['v' . $i] . '" size="40" /><br />';
}
- $return .= '<input type="text" name="s_editorfontlist[k' . $i . ']" value="" size="20" />';
+ $return .= '<input type="text" class="form-text" name="s_editorfontlist[k' . $i . ']" value="" size="20" />';
$return .= ' ';
- $return .= '<input type="text" name="s_editorfontlist[v' . $i . ']" value="" size="40" /><br />';
- $return .= '<input type="text" name="s_editorfontlist[k' . ($i + 1) . ']" value="" size="20" />';
+ $return .= '<input type="text" class="form-text" name="s_editorfontlist[v' . $i . ']" value="" size="40" /><br />';
+ $return .= '<input type="text" class="form-text" name="s_editorfontlist[k' . ($i + 1) . ']" value="" size="20" />';
$return .= ' ';
- $return .= '<input type="text" name="s_editorfontlist[v' . ($i + 1) . ']" value="" size="40" />';
+ $return .= '<input type="text" class="form-text" name="s_editorfontlist[v' . ($i + 1) . ']" value="" size="40" />';
return format_admin_setting('editorfontlist', $this->name, $this->visiblename, $return, $this->description);
}
}
$return .= ($value == '' ? get_string($key,'editor') : '<img width="18" height="18" src="' . $CFG->wwwroot . '/lib/editor/htmlarea/images/' . $value . '" alt="' . get_string($key,'editor') . '" title="' . get_string($key,'editor') . '" />') . ' ';
- $return .= '<input type="checkbox" value="1" id="id_s_'.$this->name.$key.'" name="s_' . $this->name . '[' . $key . ']"' . (in_array($key,$currentsetting) ? ' checked="checked"' : '') . ' /> ';
+ $return .= '<input type="checkbox" class="form-checkbox" value="1" id="id_s_'.$this->name.$key.'" name="s_' . $this->name . '[' . $key . ']"' . (in_array($key,$currentsetting) ? ' checked="checked"' : '') . ' /> ';
$count++;
if ($count % 15 != 0) {
$return .= '<br /><br />';
get_string('monday', 'calendar') . ' </div></td><td><div align="center"> ' . get_string('tuesday', 'calendar') . ' </div></td><td><div align="center"> ' .
get_string('wednesday', 'calendar') . ' </div></td><td><div align="center"> ' . get_string('thursday', 'calendar') . ' </div></td><td><div align="center"> ' .
get_string('friday', 'calendar') . ' </div></td><td><div align="center"> ' . get_string('saturday', 'calendar') . ' </div></td></tr><tr>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'u" name="s_'. $this->name .'[u]" value="1" ' . (substr($currentsetting,0,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'m" name="s_'. $this->name .'[m]" value="1" ' . (substr($currentsetting,1,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'t" name="s_'. $this->name .'[t]" value="1" ' . (substr($currentsetting,2,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'w" name="s_'. $this->name .'[w]" value="1" ' . (substr($currentsetting,3,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'r" name="s_'. $this->name .'[r]" value="1" ' . (substr($currentsetting,4,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'f" name="s_'. $this->name .'[f]" value="1" ' . (substr($currentsetting,5,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'s" name="s_'. $this->name .'[s]" value="1" ' . (substr($currentsetting,6,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'u" name="s_'. $this->name .'[u]" value="1" ' . (substr($currentsetting,0,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'m" name="s_'. $this->name .'[m]" value="1" ' . (substr($currentsetting,1,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'t" name="s_'. $this->name .'[t]" value="1" ' . (substr($currentsetting,2,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'w" name="s_'. $this->name .'[w]" value="1" ' . (substr($currentsetting,3,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'r" name="s_'. $this->name .'[r]" value="1" ' . (substr($currentsetting,4,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'f" name="s_'. $this->name .'[f]" value="1" ' . (substr($currentsetting,5,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'s" name="s_'. $this->name .'[s]" value="1" ' . (substr($currentsetting,6,1) == '1' ? 'checked="checked"' : '') . ' /></div></td>' .
'</tr></table>';
return format_admin_setting('backupdays', $this->name, $this->visiblename, $return, $this->description);
get_string('monday', 'calendar') . ' </div></td><td><div align="center"> ' . get_string('tuesday', 'calendar') . ' </div></td><td><div align="center"> ' .
get_string('wednesday', 'calendar') . ' </div></td><td><div align="center"> ' . get_string('thursday', 'calendar') . ' </div></td><td><div align="center"> ' .
get_string('friday', 'calendar') . ' </div></td><td><div align="center"> ' . get_string('saturday', 'calendar') . ' </div></td></tr><tr>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'u" name="s_'. $this->name .'[u]" value="1" ' . ($currentsetting['u'] ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'m" name="s_'. $this->name .'[m]" value="1" ' . ($currentsetting['m'] ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'t" name="s_'. $this->name .'[t]" value="1" ' . ($currentsetting['t'] ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'w" name="s_'. $this->name .'[w]" value="1" ' . ($currentsetting['w'] ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'r" name="s_'. $this->name .'[r]" value="1" ' . ($currentsetting['r'] ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'f" name="s_'. $this->name .'[f]" value="1" ' . ($currentsetting['f'] ? 'checked="checked"' : '') . ' /></div></td>' .
- '<td><div align="center"><input type="checkbox" id="id_s_'.$this->name.'s" name="s_'. $this->name .'[s]" value="1" ' . ($currentsetting['s'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'u" name="s_'. $this->name .'[u]" value="1" ' . ($currentsetting['u'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'m" name="s_'. $this->name .'[m]" value="1" ' . ($currentsetting['m'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'t" name="s_'. $this->name .'[t]" value="1" ' . ($currentsetting['t'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'w" name="s_'. $this->name .'[w]" value="1" ' . ($currentsetting['w'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'r" name="s_'. $this->name .'[r]" value="1" ' . ($currentsetting['r'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'f" name="s_'. $this->name .'[f]" value="1" ' . ($currentsetting['f'] ? 'checked="checked"' : '') . ' /></div></td>' .
+ '<td><div align="center"><input type="checkbox" class="form-checkbox" id="id_s_'.$this->name.'s" name="s_'. $this->name .'[s]" value="1" ' . ($currentsetting['s'] ? 'checked="checked"' : '') . ' /></div></td>' .
'</tr></table>';
return format_admin_setting('calendarweekend', $this->name, $this->visiblename, $return, $this->description);
$currentsetting = $this->get_setting();
}
- $return = '<input type="checkbox" size="50" id="id_s_'.$this->name.'" name="s_'. $this->name .'" value="1" ' . ($currentsetting == 15 ? 'checked="checked"' : '') . ' />';
+ $return = '<input type="checkbox" size="50" class="form-checkbox" id="id_s_'.$this->name.'" name="s_'. $this->name .'" value="1" ' . ($currentsetting == 15 ? 'checked="checked"' : '') . ' />';
return format_admin_setting('checkbox', $this->name, $this->visiblename, $return, $this->description);
}
function format_admin_setting($class, $name, $title='', $form='', $description='') {
return "\n".
- '<div class="adminsetting form-'.$class.'">'."\n".
+ '<div class="form-item admin-'.$class.'">'."\n".
'<label for="id_s_'.$name.'">'.$title."\n".
' <span class="form-shortname">'.$name.'</span>'."\n".
'</label>'."\n".