Browse Source

Correcting some syntax problems in the html file. Now the website can be loaded from ROM

master
grch101 5 years ago
committed by Torsten Stauder
parent
commit
6b40e5c251
  1. 1137
      html/index.html
  2. 14
      html/management.html
  3. 14
      src/HTMLmanagement.h
  4. 2
      src/main.cpp

1137
html/index.html
File diff suppressed because it is too large
View File

14
html/management.html

@ -663,7 +663,7 @@
path: node.data.path + "/" + data.name,
directory: data.dir
}
}
};
return child;
@ -775,7 +775,7 @@
});
}
}
}
};
}
/* Play */
@ -785,7 +785,7 @@
var playMode = node.data.directory?"5":"1";
postData("/exploreraudio?path=" + node.data.path + "&playmode=" + playMode);
}
}
};
/* Refresh */
items.refresh = {
@ -793,7 +793,7 @@
action: function(x) {
refreshNode(nodeId);
}
}
};
/* Delete */
items.delete = {
@ -802,7 +802,7 @@
handleDeleteData(nodeId);
refreshNode(ref.get_parent(nodeId));
}
}
};
/* Rename */
items.rename = {
@ -815,7 +815,7 @@
refreshNode(ref.get_parent(nodeId));
});
}
}
};
return items;
}
@ -841,7 +841,7 @@
directory: data[i].dir
},
children: []
}
};
$('#explorerTree').jstree(true).settings.core.data.children.push(newChild);
}

14
src/HTMLmanagement.h

@ -663,7 +663,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
path: node.data.path + \"/\" + data.name,\
directory: data.dir\
}\
}\
};\
\
return child;\
\
@ -775,7 +775,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
});\
}\
}\
}\
};\
}\
\
/* Play */\
@ -785,7 +785,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
var playMode = node.data.directory?\"5\":\"1\";\
postData(\"/exploreraudio?path=\" + node.data.path + \"&playmode=\" + playMode);\
}\
}\
};\
\
/* Refresh */\
items.refresh = {\
@ -793,7 +793,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
action: function(x) {\
refreshNode(nodeId);\
}\
}\
};\
\
/* Delete */\
items.delete = {\
@ -802,7 +802,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
handleDeleteData(nodeId);\
refreshNode(ref.get_parent(nodeId));\
}\
}\
};\
\
/* Rename */\
items.rename = {\
@ -815,7 +815,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
refreshNode(ref.get_parent(nodeId));\
});\
}\
}\
};\
\
return items;\
}\
@ -841,7 +841,7 @@ static const char management_HTML[] PROGMEM = "<!DOCTYPE html>\
directory: data[i].dir\
},\
children: []\
}\
};\
$('#explorerTree').jstree(true).settings.core.data.children.push(newChild);\
}\
\

2
src/main.cpp

@ -3596,7 +3596,7 @@ void webserverStart(void) {
wServer.addHandler(&events);
wServer.on("/", HTTP_GET, [](AsyncWebServerRequest *request) {
request->send(FSystem, "/management.html", String(), false, templateProcessor);
request->send_P(200, "text/html", management_HTML, templateProcessor);
});
wServer.on("/upload", HTTP_POST, [](AsyncWebServerRequest *request){

Loading…
Cancel
Save