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.

Home directory for FTP account

Discussion in 'cPanel Developers' started by mrtaryk, Dec 12, 2012.

  1. mrtaryk

    mrtaryk Registered

    Joined:
    Dec 12, 2012
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi

    I'm trying to create ftp account with '/' as homedir

    Code:
    Cpanel::Ftp::api2_addftp(
        user    => $ftp_username,
        pass    => $ftp_password,
        quota   => 0,
        homedir => '/',
    );
    Documentation says that homedir should be relative to the account's home but now this code produces ftp-account with homedir like `/home/<username>/public_html`

    Has something changed in the cPanel API recently?

    cPanel Version: 11.34.0 (build 11)

    Taras
     
    #1 mrtaryk, Dec 12, 2012
    Last edited: Dec 12, 2012
  2. mrtaryk

    mrtaryk Registered

    Joined:
    Dec 12, 2012
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    I've found a workaround to create the ftp-account with the same homedir as account's home, just specify '//' or '/.' as homedir parameter. But I'm not sure that it is correct way.
     

Share This Page