mirror of
https://github.com/moodle/moodle.git
synced 2025-05-15 04:36:13 +02:00
Small fix for admin menu layout and also print_table
This commit is contained in:
parent
8e62501630
commit
5889c1bb64
@ -366,12 +366,12 @@
|
||||
print_simple_box_end();
|
||||
}
|
||||
|
||||
$table->tablealign = "right";
|
||||
$table->tablealign = "center";
|
||||
$table->align = array ("right", "left");
|
||||
$table->wrap = array ("nowrap", "nowrap");
|
||||
$table->cellpadding = 5;
|
||||
$table->cellspacing = 0;
|
||||
$table->width = '100%';
|
||||
$table->width = '40%';
|
||||
|
||||
$configdata = '<div class="adminlink"><a href="config.php">'.get_string('configvariables', 'admin').
|
||||
'</a> - <span class="explanation">'.get_string('adminhelpconfigvariables').'</span></div>';
|
||||
|
@ -2910,6 +2910,7 @@ function print_png($url, $sizex, $sizey, $returnstring, $parameters='alt=""') {
|
||||
* <li>$table->wrap - An array of "nowrap"s or nothing
|
||||
* <li>$table->data[] - An array of arrays containing the data.
|
||||
* <li>$table->width - A percentage of the page
|
||||
* <li>$table->tablealign - Align the whole table
|
||||
* <li>$table->cellpadding - Padding on each cell
|
||||
* <li>$table->cellspacing - Spacing between cells
|
||||
* </ul>
|
||||
@ -2950,6 +2951,10 @@ function print_table($table) {
|
||||
$table->width = '80%';
|
||||
}
|
||||
|
||||
if (empty($table->tablealign)) {
|
||||
$table->tablealign = 'center';
|
||||
}
|
||||
|
||||
if (empty($table->cellpadding)) {
|
||||
$table->cellpadding = '5';
|
||||
}
|
||||
@ -2964,8 +2969,7 @@ function print_table($table) {
|
||||
|
||||
$tableid = empty($table->id) ? '' : 'id="'.$table->id.'"';
|
||||
|
||||
print_simple_box_start('center', $table->width, '#ffffff', 0);
|
||||
echo '<table width="100%" border="0" align="center" ';
|
||||
echo '<table width="'.$table->width.'" border="0" align="'.$table->tablealign.'" ';
|
||||
echo " cellpadding=\"$table->cellpadding\" cellspacing=\"$table->cellspacing\" class=\"$table->class\" $tableid>\n";
|
||||
|
||||
$countcols = 0;
|
||||
@ -3011,7 +3015,6 @@ function print_table($table) {
|
||||
}
|
||||
}
|
||||
echo '</table>'."\n";
|
||||
print_simple_box_end();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user