The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to allow php scripts in one domain access/move files in another?

Discussion in 'General Discussion' started by darksky, Mar 12, 2013.

  1. darksky

    darksky Member

    Joined:
    Mar 12, 2013
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    I've got 2 web sites - well, one is a subdomain (forum.) of the main (www.) site. But they're in separate /home folders on the server.

    I'd like to have some custom scripts I have in my forum.domain.com folder be able to edit and move files in my www.domain.com folder.

    Right now, I have to FTP in to the www domain, set the folders or files to 777, run my scripts, then change them back to 755 (for folders) and 644 (for files). Lots of hassle, and obviously not the safest method.

    :confused:
     
  2. darksky

    darksky Member

    Joined:
    Mar 12, 2013
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Anyone? Is there any cPanel setting that will allow scripts in one domain access to files in another?
     
  3. quietFinn

    quietFinn Well-Known Member

    Joined:
    Feb 4, 2006
    Messages:
    998
    Likes Received:
    10
    Trophy Points:
    18
    Location:
    Finland
    cPanel Access Level:
    Root Administrator
    No, there is not.

    You might get an answer if you 1st tell if you are running suPHP, or is PHP running as an Apache module.
    In the latter case it is very easy to implement.
     
  4. darksky

    darksky Member

    Joined:
    Mar 12, 2013
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Sorry! (I don't have much linux experience)

    suPHP
     
  5. darksky

    darksky Member

    Joined:
    Mar 12, 2013
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Is there a way via command line (root) ?
     
  6. electric

    electric Well-Known Member

    Joined:
    Nov 5, 2001
    Messages:
    697
    Likes Received:
    1
    Trophy Points:
    18
    Well sure, as root you can do anything. ;)
     
  7. darksky

    darksky Member

    Joined:
    Mar 12, 2013
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    WEll, *I* can't do anything, I'm a linux idiot :) How would one go about it? I don't want to CHANGE the user in the www folder, because I don't want any scripts in the www part of it not be able to run properly. I just want scripts in the forum.domain.com folder able to access/move/edit files in the www.domain.com folder.

    Right now I have to change perms in on the www.domain.com files/folders to 777 to do use the scripts, then change them back (a hassle).
     
Loading...

Share This Page