Just spent the last hour trying multiple upload directories (Drupal setup) and have hit a brick wall -- I can't figure out why this isn't working.
Whenever I try to import content, I get the error message:
* The selected file /path/to/drupal/temp/file.txt could not be copied.
* Could not detect the file format.
I get that the 2nd message is as a result of it not being able to find the file -- yet the file IS uploaded just fine -- directories all along path are 777. Again, no matter which directory I set up in Drupal, this module can't work with it. I have no trouble with any other module that uploads or uses the temporary directory.
Any ideas? This one's driving me nuts.
Comments
Comment #1
BradM commentedThe 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.
Comment #2
rossymole commentedI am having the same issue, it works on other test sites for the same app and has worked for me in the past on this branch. very weird.
Comment #3
djflux commentedCommenting out that line does not work for me. My Drupal test site is one folder deep under my website (i.e. http://example.com/mydrupaltest/). Not sure if that makes any difference.
Anyway, I'm trying to figure out into which folder the file is trying to be copied so I can check permissions, or finding out what code is actually trying to copy the file if I've commented out that line.
Any ideas?
FYI I'm running Drupal 5.8, PHP 5.1.6
Comment #4
ricsmo commentedI am having the same difficulty. Safari is the only browser that can open a file, but then it times out after 60 seconds. Netscape, Camino, and Opera all can't open up the file. Commenting out the line above only made Safari not be able to find the file either.
Great concept for a module, though. This would really help me.
Comment #5
beekerstudios commentedI concur, had the same issue, and commented out the line, except it's line 204 in node_import.module