title: receiving data from sockets in php
body: <p>I have transmitter and receiver applications, which sends continuous log data on TCP sockets.</p>
  
  <p>I want these log data to publish on web, using PHP.</p>
  
  <p>On PHP web server, I want to listen (socket listening) for TCP connections from transmitter and receiver, when they connects, I want to receive data from both, and then publish on web. Log data will be sent from apps continously at say 1 second interval.</p>
  
  <p>How can I do this? Is there any better way to do this? If better, I will change transmitter and receiver apps.</p>
  
  <p>I thought to send data as HTTP requests to web server, but wouldn't it cause overhead of TCP connection opening and closing every second, also from 2 apps, so opening and closing 2 TCP connections every second. And also may be that gives overhead to transmitter and receiver apps..</p>
  
  <p>Is there anything by which I can send data as HTTP requests, but TCP connection do not get closed...</p>
  
  <p>Thanks</p>