I have an AP with handleRoot() containing a webstring to aswer to client.
I need to reply a dynamic timestamp in that string.
This is my code:
void handleRoot() {
DateTime now = rtc.now();
sprintf(t, "%02d%02d%02d%02d%02d%02d",now.year() , now.month(), now.day(), now.hour(), now.minute(), now.second() );
Timestamp = t;
Serial.println(Timestamp);
webString = "Master,"+Timestamp;
server.send(200, "text/plain", webString);
but doesn't work
... because timestamp is static
Many thanks for your help