For Programmers: Free Programming Magazines  


Home > Archive > PHP Pear > January 2005 > QF File-Element rule does noch work









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author QF File-Element rule does noch work
Mirco Blitz

2005-01-29, 3:56 am

Hi,

when I try to add a rule to the file elemet with mimetype every filetype
runs through without an error.

Is there an error. Only jpg files should get to the server.



Here my code.



$form-> addElement('file','datei','Logo',$classf
ormtxt);

$form->addRule('datei', 'Bitte eine jpg Datei auswählen', 'mimetype',
array('image/jpeg', 'image/jpeg', 'image/pjpeg') );



Thanks for your help in advance.

Mirco Blitz


Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com