It depends from what type of solution You want. If You still want to keep script generating data on Your local machine:
You can write PHP script with simple API and host it on the server.
From Your local machine You will have to only send HTTP requests with results.
Server will be rendering HTML page with the most actual data and accepting requests with fresh data.