Better fix for bug 36049, now using isset() rather than !empty()
authorawjrichards <arichards@wikimedia.org>
Fri, 20 Apr 2012 23:18:50 +0000 (16:18 -0700)
committerawjrichards <arichards@wikimedia.org>
Fri, 20 Apr 2012 23:18:50 +0000 (16:18 -0700)
for textarea placeholder attribute in case the attribute value
is '0'.

Change-Id: I139abff427d7342fc3283ed3428d0a538331d2b5

includes/HTMLForm.php

index ec1507c..505a26f 100644 (file)
@@ -1306,7 +1306,7 @@ class HTMLTextAreaField extends HTMLFormField {
                        $attribs['readonly'] = 'readonly';
                }
 
-               if ( !empty( $this->mParams['placeholder'] ) ) {
+               if ( isset( $this->mParams['placeholder'] ) ) {
                        $attribs['placeholder'] = $this->mParams['placeholder'];
                }