fopen(); don't works on my account.

Status
Not open for further replies.

torwald.lung67

New Member
Messages
14
Reaction score
0
Points
0
Hi! I am writing PHP script with fopen() function but it does not work. I heard it is all about my account PHP level. Can You set my PHP level hi enough to use that type of functions?

respectfully yours.
 

Livewire

Abuse Compliance Officer
Staff member
Messages
18,169
Reaction score
216
Points
63
We haven't used the PHP level system in years, so that's not the problem.

The problem is that we blocked outgoing traffic on port 80 because content scraping and proxies aren't allowed, and we've been whitelisting the popular API systems used for updating (like wordpress, phpbb, etc). Where are you trying to connect to and for what purpose?
 

torwald.lung67

New Member
Messages
14
Reaction score
0
Points
0
Misunderstanding. Part of my website's file: http://michaelsoft.x10.mx/kontakt.php uses PHP code and it works fine on "FOX SERVER" with PHP installed on my PC, but not on michaelsoft.x10.mx. This is simple code not something complicated.

In short way, why this does not work on my x10.mx account?:

$file=fopen("poczta\wiadomosci.txt", "a");
flock($file, LOCK_EX);
fputs($file, $dane);
flock($file, LOCK_UN);
fclose($file);
 

descalzo

Grim Squeaker
Community Support
Messages
9,373
Reaction score
326
Points
83
1. Use / as a path separator. Linux, not Windows.

2. I cannot find that file ( poczta/wiadomosci.txt ) on your site from the web. Are you sure that it is there (and remember CaSe MatteRS in Linux) ?
 

torwald.lung67

New Member
Messages
14
Reaction score
0
Points
0
It was MY BIG mistake. You are right, it is all about "/". Thank You very much.

P.S. "poczta/wiadomosci.txt" will be created after first use of that script (now it's alll fine)
 

Livewire

Abuse Compliance Officer
Staff member
Messages
18,169
Reaction score
216
Points
63
Was about to say "I just checked on the server and the file's there..."

Glad it's working, and sorry I misunderstood what fopen was actually being used for in this case - we've been getting a lot of questions on folks using it to download from -other- sites so I assumed it was another one of those. I couldn'tve been more wrong this time if I had tried XD
 

torwald.lung67

New Member
Messages
14
Reaction score
0
Points
0
Hi! Do anybody know how to close this tread? Replays from forum members alredy helped me so no new entrys needed.
Thx.
 
Status
Not open for further replies.
Top