diff options
author | Michael Klier <chi@chimeric.de> | 2009-11-17 10:21:14 +0100 |
---|---|---|
committer | Michael Klier <chi@chimeric.de> | 2009-11-17 10:21:14 +0100 |
commit | b4033556bb721349b00671fe7fe7db2d474e1e71 (patch) | |
tree | e6396f4b2d9cc1704009da86fe770f7e6e198d3b /inc/form.php | |
parent | 76ec546799e5b8919a22548e7559aba7f50cd78b (diff) | |
download | rpg-b4033556bb721349b00671fe7fe7db2d474e1e71.tar.gz rpg-b4033556bb721349b00671fe7fe7db2d474e1e71.tar.bz2 |
form method should be lowercase and action should be set always
darcs-hash:20091117092114-23886-69852bb75c1a5d630797741c736159b726dfd334.gz
Diffstat (limited to 'inc/form.php')
-rw-r--r-- | inc/form.php | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/inc/form.php b/inc/form.php index 56afd3fec..4e245c93a 100644 --- a/inc/form.php +++ b/inc/form.php @@ -63,14 +63,20 @@ class Doku_Form { if(!is_array($params)) { $this->params = array('id' => $params); if ($action !== false) $this->params['action'] = $action; - if ($method !== false) $this->params['method'] = $method; + if ($method !== false) $this->params['method'] = strtolower($method); if ($enctype !== false) $this->params['enctype'] = $enctype; } else { $this->params = $params; } if (!isset($this->params['method'])) { - $this->params['method'] = 'POST'; + $this->params['method'] = 'post'; + } else { + $this->params['method'] = strtolower($this->params['method']); + } + + if (!isset($this->params['action'])) { + $this->params['action'] = ''; } $this->addHidden('sectok', getSecurityToken()); |