Ver código fonte

Sysops that doesn't want to enable css changer at user level only have to
clean css folder.

philippe_mingo 23 anos atrás
pai
commit
0737e6acfe
1 arquivos alterados com 11 adições e 7 exclusões
  1. 11 7
      src/options_display.php

+ 11 - 7
src/options_display.php

@@ -57,13 +57,17 @@ function load_optpage_data_display() {
 	}	
 	closedir($handle);
     
-    $optvals[SMOPT_GRP_GENERAL][] = array(
-        'name'    => 'custom_css',
-        'caption' => _("Custom Stylesheet"),
-        'type'    => SMOPT_TYPE_STRLIST,
-        'refresh' => SMOPT_REFRESH_ALL,
-        'posvals' => $css_values
-    );
+    if ( count( $css_values > 1 ) ) {
+    
+        $optvals[SMOPT_GRP_GENERAL][] = array(
+            'name'    => 'custom_css',
+            'caption' => _("Custom Stylesheet"),
+            'type'    => SMOPT_TYPE_STRLIST,
+            'refresh' => SMOPT_REFRESH_ALL,
+            'posvals' => $css_values
+        );
+    
+    }
     
     $language_values = array();
     foreach ($languages as $lang_key => $lang_attributes) {