dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a13e752
)
Follow-up r78445: validation errors would never be shown on a GET form
author
Happy-melon
<happy-melon@users.mediawiki.org>
Wed, 15 Dec 2010 20:10:16 +0000
(20:10 +0000)
committer
Happy-melon
<happy-melon@users.mediawiki.org>
Wed, 15 Dec 2010 20:10:16 +0000
(20:10 +0000)
includes/HTMLForm.php
patch
|
blob
|
history
diff --git
a/includes/HTMLForm.php
b/includes/HTMLForm.php
index
cd3dc1f
..
d1a5438
100644
(file)
--- a/
includes/HTMLForm.php
+++ b/
includes/HTMLForm.php
@@
-595,6
+595,10
@@
class HTMLForm {
public function setMethod( $method='post' ){
$this->mMethod = $method;
}
+
+ public function getMethod(){
+ return $this->mMethod;
+ }
/**
* TODO: Document
@@
-850,7
+854,7
@@
abstract class HTMLFormField {
$verticalLabel = true;
}
- if ( $errors === true ||
!$wgRequest->wasPosted(
) ) {
+ if ( $errors === true ||
( !$wgRequest->wasPosted() && ( $this->mParent->getMethod() == 'post' )
) ) {
$errors = '';
} else {
$errors = Html::rawElement( 'span', array( 'class' => 'error' ), $errors );