File upload issues


Posted on 16th Feb 2014 07:03 pm by admin

Hi Guys,

Can anyone see any issues with this code:
Code: [Select]$setImage= 'productimages/' . date(U) . $HTTP_POST_FILES['setImage']['name'][0];
Did you know?Explore Trending and Topic pages for more stories like this.
copy($HTTP_POST_FILES['setImage']['tmp_name'][0], $setImage);
Its stripping the original file name (including the extension) fromt he end of the image and just giving it a unix timestamp for a name. Looking at the code I think I can see why its doing that but I can't see how to fix it.

Any help would be most appreciated
No comments posted yet

Your Answer:

Login to answer
153 Like 31 Dislike
Previous forums Next forums
Other forums

DB2 for z/OS, LUW, iSeries
Hello, In this forum a lot of threads related to other members of the DB2 family than DB2 for z/OS

Filtering an Array Based on Value
I have a very simple script set up that pulls data from a database and is output using this code:

How can use this array as a key?
Say I have this array for example:


print_r($array);

Prints:
Code: [Select]Array

Simultaneous select/update/insert
Hi

How would I need to go about when 2 users update a single row simultaneous? And how would

How to display objects in a row
I have 7 codes that i want to display in a row one next to another.
The first is {$ads->ad

New Login Script
Hi all, i attempted to create a whole new login script witch isnt working for some reason i dont kno

Feed Maker
Hi all.
First of all I must say I am not a php developer so I am afraid I don't know much about i

Working with Global Variables
hi, I'm not really sure why the following code is returning a "Call to a member function getBan

frames get header location..
i have two frames, one top, one bottom. how do i do a form on the bottom frame that gives me the ur

webpage with (simple) login & mysql-db
Hi all,

What I was looking for before was a multi-user password manager, web-based! The offer

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash