Left here for archival purposes.

User avatar
By dpwhittaker
#11797 The right solution for this platform is probably chunked encoding.

http://en.m.wikipedia.org/wiki/Chunked_ ... r_encoding

It is a standard way of providing the content length one packet at a time without having to know the full length ahead of time. If you are dynamically generating content, there is not enough memory to store the whole string just to get its length.

I've seen a web server floating around with an example, but can't find it right now. I'll try to put it in my lhttpd port this weekend.
User avatar
By Carlos Sales Junior
#26419 Hi,

Due the iPhone needs to receive a header, you have to put before
connection:send("<p>Temperaturanzeige</br>Temperatur: "..temp.."</p>")

the lines bellow:

connection:send("HTTP/1.1 200 OK\r\n");
connection:send("Content-type: text/html\r\n");
connection:send("Connection: close\r\n\r\n");

This worked for me.

Regards,

Carlos Sales Junior