Browse Source

Merge branch 'master_sq9mdd' of github.com:Qyon/TTGO-T-Beam-LoRa-APRS into master_sq9mdd

pull/34/head
Łukasz Nidecki 12 months ago
parent
commit
c278ab3ec9
  1. 8
      src/taskWebServer.cpp

8
src/taskWebServer.cpp

@ -38,8 +38,12 @@ void sendCacheHeader() { server.sendHeader("Cache-Control", "max-age=3600"); }
void sendGzipHeader() { server.sendHeader("Content-Encoding", "gzip"); }
String jsonEscape(String s){
s.replace("\"", "\\\"");
s.replace("\\", "\\\\");
s.replace("\\", "\\\\");
s.replace("\"", "\\\"");
s.replace("\x7f", "\\\x7f");
for(char i = 0; i < 0x1f; i++){
s.replace(String(i), "\\" + String((char)i));
}
return s;
}

Loading…
Cancel
Save