Jump to content

[SOLVED] PHP sockets and shell script help


stopblackholes

Recommended Posts

Hello i have a few questions about PHP sockets and Shell Scripts. I found some great tutorials but they fail at explaining the obvious.

 

 

Ok 

#!/usr/bin/php5 -q

 

that tells the server its a shell script. do  i need shell access to start a socket a server? if not how do i turn it on or shut it down?

 

Does each client/user need to start the script? or is it just one background process that listens for people who connect?

 

 

 

 

Well if you are going to be constantly running the listening script, you will need shell/root access. A client will only need to start their side of the script (connecting to your server script). To turn it on/off just use the command line to call/stop the script.

 

Curious, are you using socket_create or fsockopen? you might be asking the wrong question here.

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.