diff --git a/forms/ConfirmedPasswordField.php b/forms/ConfirmedPasswordField.php
index 530e2a732..c74169b28 100644
--- a/forms/ConfirmedPasswordField.php
+++ b/forms/ConfirmedPasswordField.php
@@ -117,6 +117,8 @@ class ConfirmedPasswordField extends FormField {
}
foreach($this->children as $field) {
+ $field->setDisabled($this->isDisabled());
+ $field->setReadonly($this->isReadonly());
$content .= $field->FieldHolder();
}
diff --git a/forms/PasswordField.php b/forms/PasswordField.php
index 2df9000a1..e02d6e466 100755
--- a/forms/PasswordField.php
+++ b/forms/PasswordField.php
@@ -25,13 +25,15 @@ class PasswordField extends FormField {
function Field() {
+ $disabled = $this->isDisabled()?"disabled=\"disabled\"":"";
+ $readonly = $this->isReadonly()?"readonly=\"readonly\"":"";
if($this->maxLength) {
return "id() .
"\" name=\"{$this->name}\" value=\"" . $this->attrValue() .
- "\" maxlength=\"$this->maxLength\" size=\"$this->maxLength\"/>";
+ "\" maxlength=\"$this->maxLength\" size=\"$this->maxLength\" $disabled $readonly />";
} else {
return "id() .
- "\" name=\"{$this->name}\" value=\"" . $this->attrValue() . "\" />";
+ "\" name=\"{$this->name}\" value=\"" . $this->attrValue() . "\" $disabled $readonly />";
}
}