I have this issue with chmod.
the webserver says "permission denied" after i chmod a directory i created with ftp_mkdir( );
The website is on a webhotel with php 4, mysql and it uses Linux and apache.
Basicly what i do is this:
Code: Select all
<?php
$ftp_con = ftp_connect( FTP_HOST, FTP_PORT );
if( ftp_login( $ftp_con, FTP_USER, FTP_PASS ) )
{
if( ftp_mkdir( $ftp_con, "/public_html/users/owe" ) )
{
chmod("/home/owe/public_html/users/owe", 0777);
}
}
ftp_nclose = ftp_quit( $ftp_con );
?>Operation not permitted in /home/owe/public_html/test/ftp.php
I have allso tried to use ftp_exec(), but it returns:
SITE EXEC is an unknown extension in /home/owe/public_html/test/ftp.php
If somebody knows how to deal with this, please help me out.
Allso, Why isn´t there a ftp_chmod( "ftp_connection", "chmod" ) function?
Regards,
Owe Blomqvist