From d2f8afc0b72473bf4a73eb6cae03ba4ecddc29be Mon Sep 17 00:00:00 2001 From: Ivan Tcholakov Date: Wed, 14 Jul 2010 19:36:59 +0300 Subject: [PATCH] Visual theme admin page - a minor visual improvement about the "Save settings" button. --- main/admin/settings.lib.php | 39 +++++++++++++++++++------------------ 1 file changed, 20 insertions(+), 19 deletions(-) diff --git a/main/admin/settings.lib.php b/main/admin/settings.lib.php index ea0b6bf81b..7c28dcacab 100755 --- a/main/admin/settings.lib.php +++ b/main/admin/settings.lib.php @@ -5,7 +5,7 @@ * * @author Julio Montoya * @author Guillaume Viguier -* +* * @since Chamilo 1.8.7 * @package chamilo.admin */ @@ -282,10 +282,10 @@ function handle_stylesheets() '; echo '
"; //echo ''.$show_name.''; } else { @@ -318,12 +318,13 @@ function handle_stylesheets() @closedir($handle); } //Sort styles in alphabetical order - asort($list_of_names); + asort($list_of_names); foreach($list_of_names as $style_dir=>$item) { echo $list_of_styles[$style_dir]; } - - echo '
'; + + //echo '
'; + echo '  '; //var_dump($list_of_names); if ($is_style_changeable){ echo ''; @@ -350,7 +351,7 @@ function upload_stylesheet($values,$picture) { mkdir(api_get_path(SYS_CODE_PATH).'css/'.$style_name.'/', api_get_permissions_for_new_directories()); } - + $info = pathinfo($picture['name']); if($info['extension'] == 'zip') { // Try to open the file and extract it in the theme @@ -361,7 +362,7 @@ function upload_stylesheet($values,$picture) $valid = true; $single_directory = true; $invalid_files = array(); - + for($i =0; $i < $numFiles; $i++) { $file = $zip->statIndex($i); if(substr($file['name'], -1) != "/") { @@ -371,7 +372,7 @@ function upload_stylesheet($values,$picture) $invalid_files[] = $file['name']; } } - + if(strpos($file['name'], "/") === false) { $single_directory = false; } @@ -393,7 +394,7 @@ function upload_stylesheet($values,$picture) for($i = 0; $i < $numFiles; $i++) { $entry = $zip->getNameIndex($i); if ( substr($entry, -1) == '/') continue; - + $pos_slash = strpos($entry, '/'); $entry_without_first_dir = substr($entry, $pos_slash + 1); // If there is still a slash, we need to make sure the directories are created @@ -403,21 +404,21 @@ function upload_stylesheet($values,$picture) @mkdir($extraction_path.dirname($entry_without_first_dir), $mode = 0777, true); } } - + $fp = $zip->getStream($entry); $ofp = fopen( $extraction_path. dirname($entry_without_first_dir).'/'.basename($entry), 'w'); - + while ( ! feof($fp)) { fwrite($ofp, fread($fp, 8192)); } - + fclose($fp); fclose($ofp); } } } $zip->close(); - + } else { Display::display_error_message(get_lang('ErrorReadingZip')); } @@ -949,9 +950,9 @@ function select_timezone_value() { /** * Returns an array containing the list of options used to populate the gradebook_number_decimals variable - * + * * @return array List of gradebook_number_decimals options - * + * * @author Guillaume Viguier */ function select_gradebook_number_decimals() { @@ -961,9 +962,9 @@ function select_gradebook_number_decimals() { /** * Updates the gradebook score custom values using the scoredisplay class of the * gradebook module - * + * * @param array List of gradebook score custom values - * + * * @author Guillaume Viguier */ function update_gradebook_score_display_custom_values($values) {