Dear friends,
I am unable to findout the answers for this question?
I am having one server socket program ans one client program.
server program:
<---------------->
<----------------->
./server.rb -p 1234
client program:
<------------------>
<------------------>
./client.rb -p 1234
Now I want to send one file to client that is available in current
directory.
Both the client and server is runnig under this
directory[vellingiri@fountserver].
Thsi is having some files ,for instance,
1.rb 2.rb 3.rb 4.rb sserver.rb client.rb
Is there any method to send a one file from client to server.Please
could anybody tell me.
In c we are using the sendfile library function,same way in ruby is
there any way.
by
Vellingiri
Is there any method to send a one file from client to server.Please
could anybody tell me.
In c we are using the sendfile library function,same way in ruby is
there any way.
by
Vellingiri
http://rubyforge.org/projects/ruby-sendfile
On 10/25/07, Arul hari [email protected] wrote:
<------------------>
1.rb 2.rb 3.rb 4.rb sserver.rb client.rb
Is there any method to send a one file from client to server.Please
could anybody tell me.
In c we are using the sendfile library function,same way in ruby is
there any way.
If you are using EventMachine library for instance for writing server,
then it does offer a method send_file_content for sending files across
network. Otherwise, I suppose, you can stream the file over the
socket. Or else, there might be bindings for sendfile library in ruby.
–
Let them talk of their oriental summer climes of everlasting
conservatories; give me the privilege of making my own summer with my
own coals.
http://gnufied.org