FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » FUDforum Installation Issues » File Upload problem
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
File Upload problem [message #18853] Mon, 14 June 2004 07:14 Go to next message
jctan is currently offline  jctan   Malaysia
Messages: 3
Registered: June 2004
Karma: 0
Junior Member
Hi all,

Great piece of software. However i'm currently having problem with file attachment. Have use the php.net upload example and it work fine. Using FUD Forum there is an error message of :-

[ERR] unable to move uploaded file test

I try to trap the error message in the post.php module and here
is the problem.

$source variable : [ERR] C:WINDOWSTEMPphp870.tmp

as you can see, it suppose to be C:\Windows\Temp\php870.tmp right? How can i ammend it?

OS : WinXP
Apache 2
PHP 4.3.6

Thanks in advance for your help.
Re: File Upload problem [message #18858 is a reply to message #18853] Mon, 14 June 2004 12:47 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
You need to modify the GLOBALS.php inside the include/ directory of the forum and make sure that the directory for FILE_STORE variable is:

C:\\Windows\\Temp\\


FUDforum Core Developer
Re: File Upload problem [message #18860 is a reply to message #18853] Mon, 14 June 2004 12:56 Go to previous messageGo to next message
jctan is currently offline  jctan   Malaysia
Messages: 3
Registered: June 2004
Karma: 0
Junior Member
thanks Ilia,

sorry for not clarifying clearly.
the error dump is like this:-

$source = C:WINDOWSTEMPphp87C.tmp
$loc = C:/Apache/Apache2/FData/Files/96.atch

as i understand the source is tmp file that created by php.
so when move_uploaded_file($source,$loc) raise an error of "[ERR] unable to move uploaded file" because the $source directory structure is truncated "/" no longer there.

This this will help you understand better.

Thanks in advance and you kind response.
Re: File Upload problem [message #18862 is a reply to message #18860] Mon, 14 June 2004 13:17 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Yes, you are correct. Check your PHP.ini file settings to make sure that if the temporary file path has \ they are written in \\ form. If you are using Apache you may nee to restart the webserver to have the changes take effect.
Also, do you have magic quotes GPC turned on?


FUDforum Core Developer
Re: File Upload problem [message #18865 is a reply to message #18853] Mon, 14 June 2004 16:03 Go to previous message
jctan is currently offline  jctan   Malaysia
Messages: 3
Registered: June 2004
Karma: 0
Junior Member
hi Ilia,

Thanks for the info. got it working finally!
Just an info. for other if they face problem.

The php.ini reside in C:\Windows\System32 but PHP read the .ini
in C:\Windows. So make a copy into C:\Windows directory. Works!

Note: My apache required that php.ini to be reside in C:\Windows\System32 don't really know why!

Best regards to all. Thanks again!
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Error: Could not open database...
Next Topic: Table 'fudforum.fud26_read' doesn't exist
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Mon Dec 02 21:52:18 GMT 2024

Total time taken to generate the page: 0.02084 seconds