fopen access denied no access to php.ini

845

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);
418

Answer

Solution:

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

People are also looking for solutions to the problem: PHP rows inserting in reverse order to Mysql

Source

Didn't find the answer?

Our community is visited by hundreds of web development professionals every day. Ask your question and get a quick answer for free.

Ask a Question

Write quick answer

Do you know the answer to this question? Write a quick response to it. With your help, we will make our community stronger.

Similar questions

Find the answer in similar questions on our website.