PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me

The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.

Go Back   Dev Shed ForumsProgramming LanguagesPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old December 30th, 1999, 09:34 PM
BeebleBrox
Guest
Dev Shed Newbie (0 - 499 posts)
 
Posts: n/a  
Time spent in forums:
Reputation Power:
The html code below for uploading ONE file works. The variable $ADDIMAGE was set (checked using phpinfo() ):

<INPUT NAME="ADDIMAGE" TYPE="file" VALUE="NONE">
__________________________
But a similar version for multiple uploads as documented in the php docu doesn't work. The array $ADDIMAGE was not set (checked using phpinfo() as well as actually checking that the temp upload dir was empty):

<INPUT NAME="ADDIMAGE[]" TYPE="file" VALUE="NONE"> ...repeated 3 times

Thnx for the help

Reply With Quote
  #2  
Old January 3rd, 2000, 12:58 PM
SneakyDave SneakyDave is offline
Registered User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Dec 1999
Posts: 3 SneakyDave User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
I've never got the PHP upload feature to work with arrays.

I've done something like this, that seems to work well:
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">code:</font><HR><pre>
<INPUT TYPE=FILE NAME=file1 TYPE=FILE>
<INPUT TYPE=FILE NAME=file2 TYPE=FILE>
[/code]

Then use something like:
<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">code:</font><HR><pre>
$x=1;
eval('$name = $file'.$x.'_name;');
eval('$size = $file'.$x.'_size;');
eval('$type = $file'.$x.'_type;');
while($name)
{
whatever it is you want to do with $name, $type, and $size
$x++;
eval('$name = $file'.$x.'_name;');
eval('$size = $file'.$x.'_size;');
eval('$type = $file'.$x.'_type;');
}
[/code]

[This message has been edited by SneakyDave (edited January 03, 2000).]

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesPHP Development > Multiple File upload prob

Developer Shed Advertisers and Affiliates



Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.

© 2003-2013 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap