mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merged revisions 51249 via svnmerge from
svn://svn.silverstripe.com/silverstripe/modules/sapphire/branches/2.2.0-mesq ........ r51249 | ischommer | 2008-03-18 11:58:39 +1300 (Tue, 18 Mar 2008) | 1 line added $titleConfirmField as fallback to localized default ........ git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@52413 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
109a9da3af
commit
f7aa3ac61a
@ -60,12 +60,18 @@ class ConfirmedPasswordField extends FormField {
|
||||
* @param mixed $value
|
||||
* @param Form $form
|
||||
* @param boolean $showOnClick
|
||||
* @param string $titleConfirmField Alternate title (not localizeable)
|
||||
*/
|
||||
function __construct($name, $title = null, $value = "", $form = null, $showOnClick = false) {
|
||||
function __construct($name, $title = null, $value = "", $form = null, $showOnClick = false, $titleConfirmField = null) {
|
||||
// naming with underscores to prevent values from actually being saved somewhere
|
||||
$this->children = new FieldSet(
|
||||
new PasswordField("{$name}[_Password]", (isset($title)) ? $title : _t('Member.PASSWORD')),
|
||||
new PasswordField("{$name}[_ConfirmPassword]",_t('Member.CONFIRMPASSWORD', 'Confirm Password'))
|
||||
new PasswordField(
|
||||
"{$name}[_Password]",
|
||||
(isset($title)) ? $title : _t('Member.PASSWORD')),
|
||||
new PasswordField(
|
||||
"{$name}[_ConfirmPassword]",
|
||||
(isset($titleConfirmField)) ? $titleConfirmField : _t('Member.CONFIRMPASSWORD', 'Confirm Password')
|
||||
)
|
||||
);
|
||||
|
||||
$this->showOnClick = $showOnClick;
|
||||
|
Loading…
Reference in New Issue
Block a user