Moderator: igrr
try either or both of these...
void foto1(){
Serial.println("streaming una foto con filestream");
File file = SPIFFS.open("/foto1.jpg", "r");
server.streamFile(file, "image/jpg");
file.close();
}
void foto2(){
//caution: you MUST use the WHOLE path as url..
Serial.println("streaming una foto con serveStatic");
File file = SPIFFS.open("/foto2.jpg", "r");
server.serveStatic("/foto2.jpg",SPIFFS,"/foto2.jpg");
file.close();
}