You are writing a PHP script and you need to open a file. How would you do this?

  • open()
  • fopen()
  • read()
  • include()
In PHP, to open a file in a script, you would use the fopen() function. It takes the path to the file and the mode as parameters. This function returns a file handle or pointer that can be used for file operations, such as reading or writing data.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *