user3809872
user3809872

Reputation:

fopen access denied no access to php.ini

I've a problem. I have a website from a friend who has created the website on his own server and now trying to set it on my hosting.

The problem now is that I've no permission to the php.ini file so I can't use fopen becease that is not allow on by mine hosting.

is there an alternative?

Martijn

$myfile = fopen("../".$enterurl.".php", "w") or die("Unable to open file!");

        $txt = file_get_contents("blank.php");
        fwrite($myfile, $txt);
        fclose($myfile);

Upvotes: 2

Views: 452

Answers (1)

user3809872
user3809872

Reputation:

The problem was that i had my file permissions not right. So he had no permission to open, change or delete a file. I changed my file permission to 777 or 744

Upvotes: 1

Related Questions