[FLOW3-general] password recheck

Thomas Plessis t.plessis at totemnumerique.com
Wed Nov 30 11:45:15 CET 2011


Hi guys,

Solution found!

Correct annotation is like that :

/**
* @param \Totem\Lewin\Domain\Model\Member $newMember A new member to add
* @param array $password The member password
* @return void
* 
* @FLOW3\Validate(value="password", type="\Totem\Lewin\Validation\Validator\PasswordValidator")
*/
public function createAction(\Totem\Lewin\Domain\Model\Member $newMember, $password) {

…

}

Class "PasswordValidator" is similar to the one proposed by Thomas Layh : http://www.layh.com/work/flow3-fluid/tutorials/flow3-password-validator.html (maybe you can update your tutorial thomas?)

regards,	

Thomas Plessis
Développeur multimédia
--
TOTEMnumerique
9, Place St Étienne
31000 Toulouse
T. 05 61 14 64 54
F. 05 61 14 64 55

Le 25 nov. 2011 à 17:00, Thomas Plessis a écrit :

> Hmmm ok but it still not working… I got the following error :
> 
> Invalid validate annotation in Totem\Lewin\Controller\MemberController->createAction(): Could not resolve class name for validator "Password". 
> 
> Here is my annotation :
> 
> * @FLOW3\Validate(value="password", type="Password", options={ "minimum"=6 })
> 	 */
> 	public function createAction(\Totem\Lewin\Domain\Model\Member $newMember, $password) {	
> and i use the passwordValidator of Thomas Layh : http://www.layh.com/work/flow3-fluid/tutorials/flow3-password-validator.html
> 
> any ideas?
> 
> regards,
> 
> Thomas Plessis
> Développeur multimédia
> --
> TOTEMnumerique
> 9, Place St Étienne
> 31000 Toulouse
> T. 05 61 14 64 54
> F. 05 61 14 64 55
> 
> Le 21 nov. 2011 à 14:23, Thomas Layh a écrit :
> 
>> Hi together,
>> 
>> I had the same problem some time ago and I started with writing a password
>> validator.  I wrote a tutorial about that on my homepage:
>> http://www.layh.com/work/flow3-fluid/tutorials/flow3-password-validator.html
>> 
>> I am not sure if this is a good solution but it worked for me. But this way
>> you can not set the password directly.
>> 
>> Feedback about this solution is welcome.
>> 
>> Greetings,
>> Thomas
>> 
>> 
>> On Mon, Nov 21, 2011 at 14:11, Thomas Plessis
>> <t.plessis at totemnumerique.com>wrote:
>> 
>>> Hi guys,
>>> 
>>> I've the same question like Dawid. Does someone have a solution without
>>> creating two fields?
>>> 
>>> regards,
>>> 
>>> Thomas Plessis
>>> Développeur multimédia
>>> --
>>> TOTEMnumerique
>>> 9, Place St Étienne
>>> 31000 Toulouse
>>> T. 05 61 14 64 54
>>> F. 05 61 14 64 55
>>> 
>>> Can you say something more about @transient ?
>>> 
>>> But manual check is good for me. Can you paste an example ?
>>> 
>>> Best regards,
>>> Dawid Pacholczyk
>>> 
>>> W dniu 2011-09-19 15:17, Peter Niederlag pisze:
>>>> Hello,
>>>> 
>>>> Am 16.09.2011 21:41, schrieb Dawid Pacholczyk:
>>>>> Hello List,
>>>>> How can I create 2 passwords field to check if the user wrote the same
>>>>> password in both with out creating 2 fields in db ? Cause - if I`m not
>>>>> wrong - when I create 2 fields in form I`ll get exception that the field
>>>>> is not in model
>>>> 
>>>> IMO you can flag it as '@transient' or use a second simple string
>>>> argument and perform a manual check in the initFooAction().
>>>> 
>>>> That's at least how I am doing it in "extbase". ;)
>>>> 
>>>> Greets and hth,
>>>> Peter
>>> 
>>> _______________________________________________
>>> FLOW3-general mailing list
>>> FLOW3-general at lists.typo3.org
>>> http://lists.typo3.org/cgi-bin/mailman/listinfo/flow3-general
>>> 
>> _______________________________________________
>> FLOW3-general mailing list
>> FLOW3-general at lists.typo3.org
>> http://lists.typo3.org/cgi-bin/mailman/listinfo/flow3-general
> 
> _______________________________________________
> FLOW3-general mailing list
> FLOW3-general at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/flow3-general



More information about the FLOW3-general mailing list