Hi,
I am looking to import a set of products that have been put into a csv file.
The node import module should allow me to do this.
I ge the following error: - when I try to perform the import.
The selected file C:\WINDOWS\TEMP\tmp9B4.tmp could not be copied.
Believe the c:\windows\temp is part of my hosted win 2003 + IIS environment and PHP has been set o use this as the temp directory. I "think" the file has been imported to C:\Windows\temp as tmp9b4.tmp but cannot be copied to the asigned drupal temp area.
What do I need to do to progress to a working module??
My hosting provider has confirmed that their "global" php.ini setup has assigned C:\windows\temp as a temp file that only php functions has access to. Due to security issues, this directory has restricted access.
Have set up /files and /files/tmp and also /tmp no success.
Could you please assist?
Thank you in advance.
Comments
Comment #1
E_Maverik commentedI have progressed a bit further..
1. Checked & reset the permission setting of the /files and /files/tmp relative to the installation root. Permission is now set as read, write, delete by all.
2. Now I progressed to the issue bradm raised:
The file has been imported to /files/tmp however the program says it cannot open it!
As per bradm's suggestion, I commented out line 172 in the node import module.
This seems to work, however the process "spits" out about 8 lines of error messages... (not too happy....)!
Line 172 must be there for a reason - Could someone explain what it does and changes for an IIS /windows server environment?
____________________________________
The line of code that is causing the error is line 172,
file_move($file, 'drupal.node_import.'. strtr($base_url, array('http://' => '', '/' => '.')) .'.'. $user->uid, 1);
It might just be the way my site is set up, but like I said, I haven't had any other trouble with uploads of any kind.
Anyway, commenting this out did the trick for me.
_____________________________________
Thank you in advance.
Comment #2
ehowland commentedThis worked for me as well -- thanks tons.
It may be that this line is trying to move the file into the web tree. Sometimes file access above the web root is restricted for security. I am surprised that when it cannot move the file it is still able to find it.