Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
Upload problems with files and pictures
Hello
I’ve just installed the actual tp-Version. It seems to be impossible to upload files.
If I try to upload pictures, the I’ll get the error message “upload_err_tmp_dir” just somewhere in the middle of the administration screen.
If I try the upload of a file then I’ll get the error message “Hochladen der Datei fehlgeschlagen uicontrol.gif -”.
Both directories are set to 777
Can you helb me?
Thanks für all and best regards
Wolfgang Uhr
Offline
Re: Upload problems with files and pictures
Try setting the “upload temp dir” to /path/to/textpattern/tmp
Offline
Re: Upload problems with files and pictures
Hello
Sorry, noch chance. I’ve putted the three dirs to to /path/to/textpattern/… and I can change it’s name and the diagnostic shows an error. If I change back, the error message disappears.
Nothing – strange, even it does not work
Best Regards
Wolfgang
Offline
Re: Upload problems with files and pictures
Hello
Only the path and the name of the file are submitted to the server?
Does the server initiate the upload?
Are ther any ports to be forwarded?
Best regards
Wolfgang
Last edited by Wolfgang (2007-01-22 19:26:36)
Offline
#5 2007-01-22 20:01:12
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Upload problems with files and pictures
Are ther any ports to be forwarded?
No.
Please post the results of your diagnostics tab.
Offline
Re: Upload problems with files and pictures
Hello Mary
I’ve added the diagnostics
___________________________________________
Textpattern-Version: 4.0.4 (r1956)
Letzte Aktualisierung: 2007-01-21 11:47:26/2007-01-21 16:56:40
Document Root: /home/devsupde/http/pub
$path_to_site: /home/devsupde/http/pub
Textpattern-Pfad: /home/devsupde/http/pub/textpattern
Schema der URLs: section_title
open_basedir: /home/devsupde/http
Temporäres Verzeichnis: /home/devsupde/http/pub/textpattern/tmp/
Seiten-URL: devsup.de
PHP-Version: 5.1.6-pl6-gentoo
Lokale Serverzeit: 2007-01-23 20:52:48
MySQL: 5.0.26-log
Regionale Einstellungen: de_DE.UTF-8
Server: Apache/2
Apache-Version: Apache/2
PHP Server API: apache2handler
RFC-2616-Header:
Betriebssystem des Servers: Linux 2.6.17.13
Inhalt der .htaccess-Datei:
————————————
#RewriteEngine On
#DirectoryIndex index.php index.html
#Options +FollowSymLinks
#RewriteBase /relative/web/path/
<IfModule mod_rewrite.c> RewriteEngine On RewriteCond %{REQUEST_FILENAME} -f [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^(.+) – [PT,L]
RewriteRule ^(.*) index.php </IfModule>#php_value register_globals 0
————————————
Best regards
Wolfgang
Last edited by Wolfgang (2007-01-23 19:58:44)
Offline
#7 2007-01-24 15:23:46
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Upload problems with files and pictures
Okay, assuming your image, files and tmp directories are located as they were within the zip file, your pref settings should look like:
- Image directory:
images(directory name only) - Temporary directory path :
/home/devsupde/http/pub/textpattern/tmp(full path, no ending slash) - File directory path:
/home/devsupde/http/pub/files(full path, no ending slash)
The images folder should be the directory name only. The full path, for your reference, would be /home/devsupde/http/pub/images.
Make sure all three folders are there, and chmod’ed to 777.
Offline
Re: Upload problems with files and pictures
> Image directory: images (directory name only)
checked and Ok …
> Temporary directory path : /home/devsupde/http/pub/textpattern/tmp (full path, no ending slash)
checked and Ok …
> File directory path: /home/devsupde/http/pub/files (full path, no ending slash)
checked and Ok …
> The images folder should be the directory name only.
Yes it is …
> The full path, for your reference, would be /home/devsupde/http/pub/images.
ok found …
> Make sure all three folders are there, and chmod’ed to 777.
They are all three set to 777.
But it does not work – sorry …
Offline
#9 2007-01-24 17:30:55
- Mary
- Sock Enthusiast
- Registered: 2004-06-27
- Posts: 6,236
Re: Upload problems with files and pictures
What error(s) do you get?
Offline
Re: Upload problems with files and pictures
upload_err_tmp_dir
http://devsup.de/Viewlets/Error_1.swf
Offline
Re: Upload problems with files and pictures
I’ve added some lines in get_uploaded_file
@function get_uploaded_file($f, $dest=’‘) { global $tempdir;
echo “<p>$tempdir</p>”;
echo “<p>$f</p>”;
echo “<p>$dest</p>”;
@
$f and $dest are empty strings in this functions. $tempdir is set correctly.
Offline
Re: Upload problems with files and pictures
Is there any chance to solve the problem or not?
Best regards
Wolfgang
Offline
Re: Upload problems with files and pictures
Hello
I think, that I’ve found something interesting part.
Go to the funcion “doDiagnostics()” in txp_diag.php. There you find the lines
$out = array('<textarea cols="78" rows="18" readonly="readonly" style="width: 500px; height: 300px;">',
and following
In this sequenze you find lines, each one creates a field of an array:
gTxt('permlink_mode').cs.$permlink_mode.n,
(ini_get('open_basedir')) ? 'open_basedir: '.ini_get('open_basedir').n : '',
(ini_get('upload_tmp_dir')) ? 'upload_tmp_dir: '.ini_get('upload_tmp_dir').n : '',
gTxt('tempdir').cs.$tempdir.n,
Each of those lines I will copy before the declaration of the array and change it to:
$hpXX = gTxt('permlink_mode').cs.$permlink_mode.n;
echo "<p>diag: $hpXX :</p>";
$hpXX = (ini_get('open_basedir')) ? 'open_basedir: '.ini_get('open_basedir').n : '';
echo "<p>diag: $hpXX :</p>";
$hpXX = (ini_get('upload_tmp_dir')) ? 'upload_tmp_dir: '.ini_get('upload_tmp_dir').n : '';
echo "<p>diag: $hpXX :</p>";
$hpXX = gTxt('tempdir').cs.$tempdir.n;
echo "<p>diag: $hpXX :</p>";
First Line: Schema der URLs: section_title -> Ok, this is found in the diagnostics …
Second Line: open_basedir: /home/devsupde/http – Ok, this is found too!
Third Line: Empty – -> There is no empty line in the diganostics
Fourth Line: Temporäres Verzeichnis: /home/devsupde/http/tmp – Ok, this is the third entry (of our investigated ones) in the diagnostics.
So the following line is hidden by the next one:
(ini_get('upload_tmp_dir')) ? 'upload_tmp_dir: '.ini_get('upload_tmp_dir').n : '',
And This is what I have said: upload_tmp_dir is not definded correctly. I’ve added a line
ini_set('upload_tmp_dir','/home/devsupde/http/tmp');
into the textpattern/index.php, but it does not work.
Best regards
Wolfgang
Offline
Re: Upload problems with files and pictures
Thanks, the problem is solved …
Offline
Pages: 1