Ultrashock Forums > Flash > Data Communication
flash upload + php

You are currently viewing our website as a guest which gives you limited access to forums, files and other resources.

Click here to join now for free, and start interacting with our members, download files and much more!

Click here if you are looking for our Flash files and other professional assets.
 
Post Reply | View first unread | Rate Thread Search this Thread | Thread Tools | Display Modes

#1
Bookmark and Share!
flash upload + php
Old 2009-03-16

hello, I have this app wich uploads images using file.upload() method.
My problem is that once the php is called it only executes these tasks:

Code:
move_uploaded_file($_FILES['Filedata']['tmp_name'],  "./../../uploaded/original/".$_FILES['Filedata']['name']);
chmod("./../../uploaded/original/".$_FILES['Filedata']['name'],  0777);
and completely ignores the other commands.
any ideas?

thanks.
databhi.it | beatomatic.net

the more you dance, the more you romance!
postbit arrow 4 comments | 759 views postbit arrow Reply: with Quote   
Moderator
databhi is offline Moderator
seperator
Posts: 5,327
2001-03-02
Age: 31
databhi lives in Italy
databhi's Avatar
seperator

Ultrashock Member Comments:
Nutrox's Avatar Nutrox Nutrox is offline Super Moderator Nutrox lives in United Kingdom 17 Creative Assets 2009-03-16 #2 Old  
What are the other commands that are being ignored, and have you made sure the file is being moved/chmod? PHP could be failing on the chmod, or it could be failing on the command directly after that.
Reply With Quote  
databhi's Avatar databhi databhi is offline Moderator databhi lives in Italy 2009-03-16 #3 Old  
php does move/chmode without problems, but then we call functions that resize the image to create a preview and they are not executed. if we call the same php file outside flash all the scripts work.
Reply With Quote  
databhi's Avatar databhi databhi is offline Moderator databhi lives in Italy 2009-03-16 #4 Old  
ouch, sorry for bothering, we fired the bug. it was just a permissions issue. thank you.
Reply With Quote  
Nutrox's Avatar Nutrox Nutrox is offline Super Moderator Nutrox lives in United Kingdom 17 Creative Assets 2009-03-18 #5 Old  
I didn't get an email telling me about your last reply so I've just been looking into this again for you.

What I was going to suggest is to listen for the UPLOAD_COMPLETE_DATA event and then, assuming the data length isn't massive, just trace() the returned data. That data will contain any errors that were spat out by PHP after it received the upload data, as long as you have PHP error reporting turned on of course.

Good to know you found the problem though.
Reply With Quote  
Thread Tools
Display Modes Rate This Thread
Rate This Thread: