Connecting Tech Pros Worldwide Help | Site Map
 
 
LinkBack Thread Tools Search this Thread
  #1  
Old October 17th, 2006, 09:05 PM
fAnSKyer
Guest
 
Posts: n/a
Default Permission denied?

I am trying to make a new file using fopen, but I got a exception:
failed to open stream: Permission denied in tmp/ ..

I am using linux and I've already chmod the php file to 777.

I tried adding exec("touch afile") in my php program and the result is
there is no exception but no file come out.

I am confused? how to control the permission in PHP?
Thanks a lot

fAnS.

  #2  
Old October 17th, 2006, 09:35 PM
Jerry Stuckle
Guest
 
Posts: n/a
Default Re: Permission denied?

fAnSKyer wrote:
Quote:
I am trying to make a new file using fopen, but I got a exception:
failed to open stream: Permission denied in tmp/ ..
>
I am using linux and I've already chmod the php file to 777.
>
I tried adding exec("touch afile") in my php program and the result is
there is no exception but no file come out.
>
I am confused? how to control the permission in PHP?
Thanks a lot
>
fAnS.
>
Do you have permission to create files in tmp/? If this is being done
on a web page, that would be the userid the webserver is running under.

What's the actual fopen() you are using?

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================
  #3  
Old October 17th, 2006, 10:05 PM
Gale
Guest
 
Posts: n/a
Default Re: Permission denied?

fAnSKyer wrote:
Quote:
I am trying to make a new file using fopen, but I got a exception:
failed to open stream: Permission denied in tmp/ ..
>
I am using linux and I've already chmod the php file to 777.
>
I tried adding exec("touch afile") in my php program and the result is
there is no exception but no file come out.
>
I am confused? how to control the permission in PHP?
Thanks a lot
>
fAnS.
>
did you use chmod 777 on tmp dir by ftp or php ?
  #4  
Old October 18th, 2006, 02:55 PM
fAnSKyer
Guest
 
Posts: n/a
Default Re: Permission denied?

thanks a lot
it is because the permission for the tmp

Sorry for such a stupid question :)

Cheers
FanS.


Gale wrote:
Quote:
fAnSKyer wrote:
Quote:
I am trying to make a new file using fopen, but I got a exception:
failed to open stream: Permission denied in tmp/ ..

I am using linux and I've already chmod the php file to 777.

I tried adding exec("touch afile") in my php program and the result is
there is no exception but no file come out.

I am confused? how to control the permission in PHP?
Thanks a lot

fAnS.
>
did you use chmod 777 on tmp dir by ftp or php ?
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 205,248 network members.