[TYPO3-core] RFC: Mailform doesn't work with image submit buttons #1374

Ingmar Schlecht ingmar at typo3.org
Sun Apr 30 23:03:27 CEST 2006


Karsten Dambekalns schrieb:
> On Sunday 30 April 2006 12:12, rupert germann wrote:
>> assume that mybutton_y exists, too. Also making a double check for
>> isset($_POST['data']) && is_array($_POST['data']) makes no sense in my eyes
>> because if the var is already an array it *is* set ;-)
> 
> <assumption>
> Yes, but in PHP5 trying to access $_POST['data'] trying to check whether it is 
> an array produces a fatal error if it isn't set. The whole story about using 
> ridiculous amounts of isset() calls is revolving around that problem...
> </assumption>

In this case this is not a problem, because $_POST is always an array
(TYPO3 doesn't work if it isn't), so calling is_array($_POST['data']
without previously calling isset($_POST['data']) is fine.

cheers
Ingmar



More information about the TYPO3-team-core mailing list