diff msitegen.inc.php @ 771:cd8a29647c09

Change the API of stGetFormStart().
author Matti Hamalainen <ccr@tnsp.org>
date Thu, 20 Nov 2014 13:54:18 +0200
parents be0f465de86c
children ff6e6c6200a4
line wrap: on
line diff
--- a/msitegen.inc.php	Thu Nov 20 12:52:47 2014 +0200
+++ b/msitegen.inc.php	Thu Nov 20 13:54:18 2014 +0200
@@ -264,12 +264,13 @@
 }
 
 
-function stGetFormStart($name, $action = "", $method = "post", $extra = "")
+function stGetFormStart($name, $action = FALSE, $method = FALSE, $extra = FALSE)
 {
   $str =
-    "<form name=\"".$name."\" action=\"".
-    ($action != "" ? $action : $name).
-    "\" method=\"".$method."\"".$extra.">\n";
+    "<form name=\"".$name."\"".
+    ($action !== FALSE ? " action=\"".$action."\"" : "").
+    " method=\"".($method !== FALSE ? $method : "post")."\"".
+    ($extra !== FALSE ? " ".$extra : "").">\n";
 
   if (($csrfID = stGetSessionItem("csrfID", FALSE)) !== FALSE)
     $str .= stGetFormHiddenInput("csrfID", $csrfID)."\n";