Announcement

Collapse
No announcement yet.

[solved] changing directory permissions so I can save php files for apache

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    [solved] changing directory permissions so I can save php files for apache

    Hi, I'm in a class and we're setting up a web server with apache. This won't be used publicly anytime soon (or ever) --

    My question is, I need to change permission on the home directory so I can save my php files in there. What's the right permissions to use? I hesitate to give read, write, and execute permissions to the whole world here...but not sure what else to do... ? At this time, I really just need some simple php scripts to run on local host.

    Any thoughts? Thanks in advance! Alex.

    Note: using Ubuntu Hardy Heron with Gnome on my Thinkpad R52 Laptop
    Laptop: Lenovo Thinkpad R52, Kubuntu 9.04 (KDE)<br />Desktop: Lenovo Thinkcentre, Fedora 13 (Gnome)

    #2
    Re: changing directory permissions so I can save php files for apache

    Found some answers here:
    http://ubuntuforums.org/showthread.php?t=90509

    The first suggestion above was to add myself to the www-data group. In the (Gnome) GUI for user administration I found no such group or user (?) -- so that didn't work. Instead, I followed the second line of guidance and edited the apache config file to make myself the default user/group.

    This still didn't get me permission to save a file in the apache home directory, though. After this, I changed ownership of /var/www from root to me.

    I'll still take any comments - I haven't tested much still but I can get my php files into /var/www now...

    Alex.

    Laptop: Lenovo Thinkpad R52, Kubuntu 9.04 (KDE)<br />Desktop: Lenovo Thinkcentre, Fedora 13 (Gnome)

    Comment


      #3
      Re: changing directory permissions so I can save php files for apache

      Hmmm Not such good news. My php doesn't seem to run...Tried the following:

      sudo a2enmod to verify php5 module is running
      restarting a few times
      putting LoadModule ... instructions in /etc/apache2/httpd.conf
      found the LoadModule scripts already in modules_enables in the same folder...
      undid most changes I've made tonight including the last post (default user and file permissions...)

      So, back to square one! Starting to get worried I won't solve this...so if you have any suggestions I'm all ears.
      Laptop: Lenovo Thinkpad R52, Kubuntu 9.04 (KDE)<br />Desktop: Lenovo Thinkcentre, Fedora 13 (Gnome)

      Comment


        #4
        Re: changing directory permissions so I can save php files for apache

        I am posting to an Ubuntu board today. If this is in violation of any rules please let me know.

        Link to Ubuntu forum post:
        http://ubuntuforums.org/showthread.p...36#post6676236
        Laptop: Lenovo Thinkpad R52, Kubuntu 9.04 (KDE)<br />Desktop: Lenovo Thinkcentre, Fedora 13 (Gnome)

        Comment


          #5
          Re: changing directory permissions so I can save php files for apache

          Solved at ubuntuforums... Only had to end my file with .php instead of .html ... 8)

          Alex
          Laptop: Lenovo Thinkpad R52, Kubuntu 9.04 (KDE)<br />Desktop: Lenovo Thinkcentre, Fedora 13 (Gnome)

          Comment

          Working...
          X