[TYPO3-50-general] Discussion of MVC with validation error messages

Bastian Waidelich bastian at typo3.org
Mon Jul 6 11:15:08 CEST 2009


Sebastian Kurfürst wrote:

Hi Sebastian,

> First: Inside the ActionController, there is a method called 
> "initializeActionMethodArguments" [...]
 > If no method parameter has been set [...] "Text" is being used.[...]
> What do you think of throwing an exception in case no type has been 
> specified?

+1
I prefer to throw exceptions in case of an error instead of trying to be 
smarter than the developer ;)
And unlike Christopher I don't think it's necessary to allow 
invalid/missing annotations as they're part of the code in FLOW3..

Imagine this example:

/**
  * param $foo integer
*/
public function($foo) {
	// $foo is an integer?
}

note the missing "@" for the param annotation.. In this case I'd like 
the framework to tell me about it..


> Second: Concerning Validation and the default errorAction: If I got it 
> correctly, the __referrer is evaluated for referring back to the 
> originating page where the error occured. Additionally, the _current_ 
> arguments are being passed onto the _last_ action.

another issue might be, that the referrer hidden fields are not 
prefixed/namespaced..
Would it work to have multiple forms on one page now?

Bastian


More information about the TYPO3-project-5_0-general mailing list