473,387 Members | 1,791 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

Upload, problem with dir

AA
I use php 5 on IIS 6.
I change upload_tmp_dir and restart IIS.

From phpinfo():
upload_tmp_dir 'D:\php\tmp'

But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"

I want to change the upload dir of tmp file...

Any suggestion?

Thanks,
Alberto
Nov 13 '08 #1
8 2231
AA escribió:
I use php 5 on IIS 6.
I change upload_tmp_dir and restart IIS.

From phpinfo():
upload_tmp_dir 'D:\php\tmp'

But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"
I'm not familiar with IIS but it's likely that the upload process runs
with the same credentials as the web server. So make sure the IIS user
has write permission over "D:\php\tmp". If your computer is called FOO,
the default IIS user is called IUSR_FOO.

Also, check the logs.

--
-- http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web: http://bits.demogracia.com
-- Mi web de humor al baño María: http://www.demogracia.com
--
Nov 13 '08 #2
AA
On 13 Nov, 10:05, "Álvaro G. Vicario"
<alvaroNOSPAMTHA...@demogracia.comwrote:
AA escribió:
I use php 5 on IIS 6.
I change *upload_tmp_dir and restart IIS.
From phpinfo():
upload_tmp_dir 'D:\php\tmp'
But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"

I'm not familiar with IIS but it's likely that the upload process runs
with the same credentials as the web server. So make sure the IIS user
has write permission over "D:\php\tmp". If your computer is called FOO,
the default IIS user is called IUSR_FOO.

Also, check the logs.

--
--http://alvaro.es- Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web:http://bits.demogracia.com
-- Mi web de humor al baño María:http://www.demogracia.com
--
gracias, Alvaro

I check, the ISS user has all the permissions on D:\php\tmp
In tmp_name I expect to find "d:\php\tmp", regardless the permission
to write in it...

Bye,
Alberto
Nov 13 '08 #3
AA escribió:
>>I use php 5 on IIS 6.
I change upload_tmp_dir and restart IIS.
From phpinfo():
upload_tmp_dir 'D:\php\tmp'
But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"
I'm not familiar with IIS but it's likely that the upload process runs
with the same credentials as the web server. So make sure the IIS user
has write permission over "D:\php\tmp". If your computer is called FOO,
the default IIS user is called IUSR_FOO.

Also, check the logs.
[...]
I check, the ISS user has all the permissions on D:\php\tmp
Just to be 100% sure, create a file there from a web page and see if it
gets there:

<?php
touch('D:\php\tmp\test.txt');
?>

If the logs don't display anything, you can try to enable the
display_startup_errors directive. I admit it didn't work for me (I set a
wrong path and nothing showed up) but who knows...

BTW, in my system phpinfo() displays the path without quotes, make sure
you didn't accidentally add single quotes to the path.

Sorry, I can't think of anything else.

In tmp_name I expect to find "d:\php\tmp", regardless the permission
to write in it...
I can't understand what you mean. The tmp_name is the actual path of the
uploaded file: if it can't create the file there, it won't display sudch
path.

--
-- http://alvaro.es - Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web: http://bits.demogracia.com
-- Mi web de humor al baño María: http://www.demogracia.com
--
Nov 13 '08 #4
AA wrote:
I use php 5 on IIS 6.
I change upload_tmp_dir and restart IIS.

From phpinfo():
upload_tmp_dir 'D:\php\tmp'

But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"

I want to change the upload dir of tmp file...

Any suggestion?

Thanks,
Alberto
Which version of PHP? Possibly it's related to this reported bug?

http://bugs.php.net/bug.php?id=44420

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Nov 13 '08 #5
AA
On 13 Nov, 12:37, Jerry Stuckle <jstuck...@attglobal.netwrote:
AA wrote:
I use php 5 on IIS 6.
I change *upload_tmp_dir and restart IIS.
From phpinfo():
upload_tmp_dir 'D:\php\tmp'
But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"
I want to change the upload dir of tmp file...
Any suggestion?
Thanks,
Alberto

Which version of PHP? *Possibly it's related to this reported bug?

http://bugs.php.net/bug.php?id=44420

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================- Nascondi testo citato

- Mostra testo citato -
Oh,no!
It's seem exactly the same thing described there...
same versions of ISS, PHP, MS Windows...
same behaviour...

thanks,
alberto
Nov 13 '08 #6
AA
On 13 Nov, 12:37, "Álvaro G. Vicario"
<alvaroNOSPAMTHA...@demogracia.comwrote:
AA escribió:
>I use php 5 on IIS 6.
I change *upload_tmp_dir and restart IIS.
From phpinfo():
upload_tmp_dir 'D:\php\tmp'
But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"
I'm not familiar with IIS but it's likely that the upload process runs
with the same credentials as the web server. So make sure the IIS user
has write permission over "D:\php\tmp". If your computer is called FOO,
the default IIS user is called IUSR_FOO.
Also, check the logs.
[...]
I check, the ISS user has all the permissions on D:\php\tmp

Just to be 100% sure, create a file there from a web page and see if it
gets there:

<?php
touch('D:\php\tmp\test.txt');
?>

If the logs don't display anything, you can try to enable the
display_startup_errors directive. I admit it didn't work for me (I set a
wrong path and nothing showed up) but who knows...

BTW, in my system phpinfo() displays the path without quotes, make sure
you didn't accidentally add single quotes to the path.

Sorry, I can't think of anything else.
In tmp_name I expect to find "d:\php\tmp", regardless the permission
to write in it...

I can't understand what you mean. The tmp_name is the actual path of the
uploaded file: if it can't create the file there, it won't display sudch
path.

--
--http://alvaro.es- Álvaro G. Vicario - Burgos, Spain
-- Mi sitio sobre programación web:http://bits.demogracia.com
-- Mi web de humor al baño María:http://www.demogracia.com
--
touched!
Any other idea?
Alberto
Nov 13 '08 #7
AA
On 13 Nov, 14:20, AA <alb.am...@gmail.comwrote:
On 13 Nov, 12:37, Jerry Stuckle <jstuck...@attglobal.netwrote:


AA wrote:
I use php 5 on IIS 6.
I change *upload_tmp_dir and restart IIS.
From phpinfo():
upload_tmp_dir 'D:\php\tmp'
But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"
I want to change the upload dir of tmp file...
Any suggestion?
Thanks,
Alberto
Which version of PHP? *Possibly it's related to this reported bug?
http://bugs.php.net/bug.php?id=44420
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================- Nascondi testo citato
- Mostra testo citato -

Oh,no!
It's seem exactly the same thing described there...
same versions of ISS, PHP, MS Windows...
same behaviour...

thanks,
alberto- Nascondi testo citato

- Mostra testo citato -
.... the bug is still "open".
Any idea?
Workaround?
bye,
alb
Nov 13 '08 #8
AA wrote:
On 13 Nov, 14:20, AA <alb.am...@gmail.comwrote:
>On 13 Nov, 12:37, Jerry Stuckle <jstuck...@attglobal.netwrote:


>>AA wrote:
I use php 5 on IIS 6.
I change upload_tmp_dir and restart IIS.
From phpinfo():
upload_tmp_dir 'D:\php\tmp'
But, if I print $_FILE:
["tmp_name"]=string(26) "C:\WINDOWS\Temp\php1CA.tmp"
I want to change the upload dir of tmp file...
Any suggestion?
Thanks,
Alberto
Which version of PHP? Possibly it's related to this reported bug?
http://bugs.php.net/bug.php?id=44420
--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstuck...@attglobal.net
==================- Nascondi testo citato
- Mostra testo citato -
Oh,no!
It's seem exactly the same thing described there...
same versions of ISS, PHP, MS Windows...
same behaviour...

thanks,
alberto- Nascondi testo citato

- Mostra testo citato -

... the bug is still "open".
Any idea?
Workaround?
bye,
alb
All I can suggest is to follow the bug and see what the resolution is.
You could also add in a comment that you're experiencing the same problem.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attglobal.net
==================
Nov 13 '08 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: dave | last post by:
Hello there, I am at my wit's end ! I have used the following script succesfully to upload an image to my web space. But what I really want to be able to do is to update an existing record in a...
2
by: Sean Dotson | last post by:
I have a form that passes variables to an asp file and then uploads a file. For some reason the request.form is not getting the info from the form. It's returning blanks. Any insight would be...
0
by: SEMIH DEMIR | last post by:
Sitelerden birinde verilen yabancý kaynakli bir scriptti duzenledim yanlýz birseyin içinden bir turlu cýkamadým iþin aslý ilk defa persistin upload componentini kullanacam yanlýz suanki haliyle...
1
by: Alex | last post by:
I am having issues with a script to upload files from a client to a webserver. The problem is not with the actual upload but with where it uploads. The whole process is supposed to create a...
9
by: Wayne Smith | last post by:
I've come up against a major headache that I can't seem to find a solution for but I'm sure there must be a workaround and I would really be grateful of any help. I'm currently building a web...
7
by: pbd22 | last post by:
hi. i am having probs understanding how to grab a file being uploaded from a remote client. i am using hidden input fields for upload such as: <input id="my_file_element" type="file"...
9
by: 8anos | last post by:
Hello, I am new at the community and newbie at programming :) As you may know rapidshare provides a perl script for linux, to upload files at their servers. You can find the original scripts at...
21
KevinADC
by: KevinADC | last post by:
Note: You may skip to the end of the article if all you want is the perl code. Introduction Uploading files from a local computer to a remote web server has many useful purposes, the most...
2
by: hotflash | last post by:
Hi All, I found the best pure ASP code to upload a file to either server and/or MS Access Database. It works fine for me however, there is one thing that I don't like and have tried to fix but...
1
by: chennaibala | last post by:
can any one send me mutiple image upload program and save the file name with extension in mysql table.we must cheak uploaded file type like bmp or any image file while uploading. i develop...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.