Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-05-30 10:03:39

borum
New Member
Registered: 2006-05-30
Posts: 3

upload_err_tmp_dir

Hello!
I have that problem, that i can’t upload any images or files. It gives me “upload_err_tmp_dir” message when uploading images and “Undefined index: file in /directory/www.mysite.com/textpattern/include/txp_file.php on line 306” when uploading files.
I searched already this forum for solution and found several topics, but found nothing helpful.

So, here’s my configuration: all directories are 777 and diagnostics says:

Textpattern version: 4.0.3 (r1188)
last_update: 2006-05-30 08:01:50/2005-12-26 17:49:56
Document root: /directory/www.mysite.com
$path_to_site: /directory/www.mysite.com
Textpattern path: /directory/www.mysite.com/textpattern
Permanent link mode: section_id_title
Temp folder: /directory/www.mysite.com/textpattern/tmp
Site URL: www.mysite.com
PHP version: 5.0.5
server_time: 2006-05-30 11:43:50
MySQL: 5.0.21-log
Locale: C
Server: Apache
Apache version: Apache
php_sapi_mode: apache
os_version: OpenBSD 3.9

Pre-flight check:
————————————
Web Domain DNS lookup fails: www.mysite.com <——- this is because i don’t have domain yet, i added the record to my hosts file.
————————————

.htaccess file contents:
————————————
#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

————————————

This is my apache.conf virtual host settings for my textpattern site (maby here is the problem?):

[VirtualHost 192.168.0.8:80] ServerName mysite.com ServerAlias mysite.com *.mysite.com DocumentRoot /directory/www.mysite.com

[Directory “/directory/www.mysite.com” ] Options -Indexes +FollowSymLinks AllowOverride All Order allow,deny Allow from all
[/Directory]

[/VirtualHost]

(replaced “<” with “[” )

file_uploads = On in php.ini

Please, help me to solve this problem. I think Textpattern is “The one” for me :)

Offline

#2 2006-05-31 23:13:32

zem
Developer Emeritus
From: Melbourne, Australia
Registered: 2004-04-08
Posts: 2,579

Re: upload_err_tmp_dir

Do you have any modifications or plugins installed?

As far as I can see, Textpattern 4.0.3 never refers to the “upload_err_tmp_dir” message from within its image upload code.


Alex

Offline

#3 2006-06-01 05:36:43

borum
New Member
Registered: 2006-05-30
Posts: 3

Re: upload_err_tmp_dir

No modifications and no plugins. Clean install.

Offline

#4 2006-06-01 05:53:13

net-carver
Archived Plugin Author
Registered: 2006-03-08
Posts: 1,648

Re: upload_err_tmp_dir

Zem, could this be it …

That string is used as part of the upload_get_errormsg routine in txplib_misc.php. Perhaps the corresponding text is missing from the global textarray so gTxt is just returning the key it was given from upload_get_errormsg??

The upload_get_errormsg routine is called for file and image upload failures just as the initial report indicates.

borum, Sorry I can’t offer you a direct solution to this!


Steve

Offline

#5 2006-06-01 09:21:08

Sencer
Archived Developer
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

Re: upload_err_tmp_dir

We didn’t make that error up, we just pass it on from PHP:
http://www.php.net/manual/en/features.file-upload.errors.php

@borum: Is this directory writable to, by PHP

Temp folder: /directory/www.mysite.com/textpattern/tmp

You have to manually adjust the permissions, for example with an FTP-Client or on the shell. (You can try 777)

Offline

#6 2006-06-01 16:20:42

borum
New Member
Registered: 2006-05-30
Posts: 3

Re: upload_err_tmp_dir

Thank you very much! All of you! Sencer, when i followed your link, i noticed there an error – “UPLOAD_ERR_NO_TMP_DIR” Value: 6; Missing a temporary folder. Introduced in PHP 4.3.10 and PHP 5.0.3.
I looked in my php.ini to check if there is something about about temp dir and yes – there is – upload_tmp_dir. I created temp dir for php and chmoded it to 777. It is working now without errors :)
Sorry, it was my fault.

P.s. and sorry for my english ;)

Offline

Board footer

Powered by FluxBB