Reply to Re: Upload error message display

Your name:

Reply:


Posted by James Barrett on 10/04/07 12:06

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Ming wrote:
> Hi there,
>
> Is there a handy way to show error message instead of error code when
> uploading?
>
> For example, if I get error code 3 (UPLOAD_ERR_PARTIAL), I can
> directly show users that 'Only part of the file was uploaded.' instead
> of if $errorCode==3 then print 'Only part of the file was uploaded.',
> which is time-consuming.
>
> Thanks,
>

What's wrong with $errorCode==3?

I would probable create an array of all error messages, where each
element index corresponds to an error number. Then you could simple say
something like;

echo $errorArray[3];


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)

iD8DBQFHBNdJQuDJiZ/QrH0RAm4/AKCp4B9VokQ2RtzMaazNuihRwZoX6wCgm2Ig
n6LUlFaglf/D/g2bBNqc/jY=
=Q4ot
-----END PGP SIGNATURE-----

[Back to original message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация