Skip to content
This repository was archived by the owner on Jan 20, 2025. It is now read-only.
This repository was archived by the owner on Jan 20, 2025. It is now read-only.

Template processing error with IOS18 #1435

Closed
@hakkapet

Description

@hakkapet

Hi, just noticed that some reason when Iphone is updated to IOS18.
Template processing wont work anymore in Safari browser: It just gives an "cannot parse response" error to Safari. So i this is Safari/IOS18 error, but it would be nice to know why this wont work anymore. It is crucial functionality almost everywhere in web applications. Other browsers (Chrome) what i was trying to use works fine. Some reason return page from AwsTemplateProcessor is interpreted as faulty in Safari.

Example this wont work anymore:

server.on("/", HTTP_GET, [](AsyncWebServerRequest *request){
        const char * html = "<p>Temperature: %PLACEHOLDER_TEMPERATURE% ºC</p><p>Humidity: %PLACEHOLDER_HUMIDITY% %</p>";
          request->send_P(200, "text/html", html, processor); 
});

or this wont work:

    server.on("/", HTTP_GET, [](AsyncWebServerRequest *request){
          request->send(LittleFS, "/index.html", "text/html;", false, processor);
    });

Without processor it gives page without problem.
request->send_p(200, "text/html", html);

Even if processor is so simple that:

String processor(const String& var) {
  return "";
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions