Don't presume output format
authorpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Sun, 24 Feb 2008 18:13:05 +0000 (18:13 +0000)
committerpdontthink <pdontthink@7612ce4b-ef26-0410-bec9-ea0150e637f0>
Sun, 24 Feb 2008 18:13:05 +0000 (18:13 +0000)
git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@12960 7612ce4b-ef26-0410-bec9-ea0150e637f0

functions/options.php
templates/default/options.tpl

index b42b05b6c0f0762ddb0cea848b6137786930c15d..9c86550d0c4f5b100ae02f7362301eec692df983 100644 (file)
@@ -276,10 +276,12 @@ class SquirrelOption {
     /**
      * Creates fields on option pages according to option type
      *
-     * Function that calls other createWidget* functions.
-     * @return string html formated option field
+     * This is the function that calls all other createWidget* functions.
+     *
+     * @return string The formated option field
+     *
      */
-    function createHTMLWidget() {
+    function createWidget() {
         global $color;
 
         // Use new value if available
@@ -335,7 +337,7 @@ class SquirrelOption {
         }
 
         /* Now, return the created widget. */
-        return ($result);
+        return $result;
     }
 
     /**
index 2ec510859884746380439d8d84743ca61e81abae..e205bbaafa634f634b8ff8bd52cf3fdbbcea983a 100644 (file)
@@ -48,11 +48,11 @@ foreach ($options as $option) {
                    "  ".$opt->caption."\n" .
                    " </td>\n" .
                    " <td class=\"optionValue\">\n" .
-                   "  ".$opt->createHTMLWidget()."\n" .
+                   "  ".$opt->createWidget()."\n" .
                    " </td>\n" .
                    "</tr>\n";
         } else {
-            echo $opt->createHTMLWidget();
+            echo $opt->createWidget();
         }
     }