Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am learning php and need to know the tmp directory on my apache server for this code. The script is hosted here /domains/

if ($_FILES[img1] != "" {
            @copy($_FILES[img1] [tmp_name], "/temp server location" .$_FILES[img1][name])

share|improve this question
up vote 0 down vote accepted

There isn't one. You will have to explicitly create a directory with appropriate permissions that you will use to hold the files.

share|improve this answer
cool, what permission shoule the directory be 777? – user40709 Apr 16 '10 at 3:19
Of course not. – Ignacio Vazquez-Abrams Apr 16 '10 at 3:22

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.