Page 1 of 2

Socks

Posted: Thu Aug 18, 2005 7:11 am
by sticksys
hi there, i'm not new in PHP but i never worked with socks..

is some ome here can teach me use socks?

thanks in advance =]

Posted: Thu Aug 18, 2005 7:29 am
by Grim...
Must... Resist...

Posted: Thu Aug 18, 2005 7:30 am
by Grim...
Hold the top (opening) of the sock in both hands, and stretch it to a good-looking size.
Pull the sock over your foot, and as far up your ankle as it will go.
Let go, and the sock will magically stay put! That's all there is to it!

Posted: Thu Aug 18, 2005 7:30 am
by Grim...
Sorry, couldn't help it.

Posted: Thu Aug 18, 2005 7:33 am
by sticksys
lol..... O.K


:twisted:

Posted: Thu Aug 18, 2005 8:09 am
by sticksys
some body? :cry:

Posted: Thu Aug 18, 2005 8:29 am
by feyd
I'm going to guess you're referring to sockets?

fsockopen() has a lot of useful information and examples on working with sockets. Although complex, the SHA256 Code Snippet here tries to use fsockopen() when the url wrappers are offline to request a remote file. That may help with a working example as well.

Posted: Thu Aug 18, 2005 8:32 am
by sticksys
yeah it's sockets i fought that in english it's different :roll:

thanks you =]

Posted: Thu Aug 18, 2005 8:35 am
by sticksys
ohh i forgot, how can i user sockets with softwares or hosts? like radio, cheking who is on now and stuff, and like icq, send message to a number.


can you help me with that?

Posted: Thu Aug 18, 2005 8:44 am
by timvw
The only thing you can do with sockets is read/write from them. Just as you would read from a file(stream) or whatever...

So you have to lookup the protocol/language you want to talk to a server.. For example, if you wan to recieve a file from a webserver, you would have to talk HTTP and you would probably say something like:

Code: Select all

GET / HTTP/1.1
Host: timvw.madoka.be
Or if you were talking to a telnet server:

Code: Select all

user john
pass doe
echo bar

Posted: Thu Aug 18, 2005 8:47 am
by feyd
you may find several libraries for those on phpclasses.org, failing that (and google), you'll need to figure out which API's the services support to write a connection to each. It can be quite complicated, so getting to specifics would help.


I'm pretty sure I saw an ICQ connector on phpclasses......

http://www.google.com/search?q=ICQ+site ... lasses.org
http://www.google.com/search?q=radio+si ... lasses.org

Posted: Thu Aug 18, 2005 1:47 pm
by sticksys
i realy hate to copy or see files, i just wanna a little guide of the basics =]

Posted: Thu Aug 18, 2005 1:56 pm
by dbevfat
sticksys wrote:i realy hate to copy or see files, i just wanna a little guide of the basics =]
You'll have to copy and see a lot of files if you want to learn :)

Posted: Thu Aug 18, 2005 1:58 pm
by sticksys
i can learn in 2 minutes i'm not a noob, i'm 1.5 years in Php =]

Posted: Thu Aug 18, 2005 2:20 pm
by brookie