Jump to content

$fp = fopen("emails.txt", "w"); but not in same folder where php is located


nightkarnation

Recommended Posts

Hey guys!

I have the following doubt:

 

I have a php file that does the following alongside with other code not displayed here:

 

$fp = fopen("emails.txt", "w");

 

It opens a txt file called emails.txt that is in the same folder where the php is saved but how do I tell $fp = fopen("/folderbefore/emails.txt", "w"); ??

 

In other words, how do I write the path on the script that the emails.txt is located in a previous folder where the php file is located??

 

Thanks in advance for your help

Cheers!

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.