LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
Search this Thread
Old 06-18-2012, 01:12 AM   #1
zob
LQ Newbie
 
Registered: Jul 2011
Distribution: fedora 14
Posts: 10

Rep: Reputation: Disabled
php on apache server running in fedora 13


Hello, for the past few weeks I have been learning php. Right now I have been playing with the fopen() statement for saveing data from php and html.
However when I try to run my code I get this error in firefox:


saveing your file... Warning: fopen(hi.txt): failed to open stream: Permission denied in /var/www/html/fileio.php on line 5

I know my php code is good because I have a php debugger on my work station and it runs with that but my server for some reason has issues with file io
Can any one point me to where I would find the config file to fix this and how I would edit that config file?
 
Old 06-18-2012, 02:44 AM   #2
scandalist
LQ Newbie
 
Registered: Apr 2011
Posts: 27

Rep: Reputation: 1
Firefox is probably running under a normal system account and does not have permission to save where you want it to. Either run firefox as a root user or grant yourself permission to save in /var/www/html/

If I'm just messing around in Apache, I explicitly grant myself full privileges so I don't run into these nuisances. ie

Code:
 chmod -R 777 /var/www/
Obviously you need to be careful with this if security is a concern...
 
Old 06-21-2012, 12:59 AM   #3
zob
LQ Newbie
 
Registered: Jul 2011
Distribution: fedora 14
Posts: 10

Original Poster
Rep: Reputation: Disabled
didn't work

I think that the issue is not with permissions for the file but with the php config file do you have any idea where that would be?
 
  


Reply

Tags
apache, fedora, html, php, servers


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Apache server simultaneous requests time out while PHP script is running ilnli Linux - Server 2 04-02-2011 09:00 AM
running apache 2 & php 5 in fedora 9 raport Linux - Software 4 01-06-2009 03:56 AM
Please help with Apache Web Server / Apache Tomcat / PHP / Java / PHP-Java Bridge jpmad4it Linux - Server 2 01-05-2009 06:07 AM
Centos 5.2 running Apache 2 and PHP 4 cannot display info.php codenjanod Linux - Server 2 08-19-2008 02:00 AM
running apache 2.2 with php 5 sharathg786 Linux - Networking 1 07-19-2006 05:23 AM


All times are GMT -5. The time now is 04:45 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration