Skip to content

Commit

Permalink
v2.0.15
Browse files Browse the repository at this point in the history
  • Loading branch information
holgerlembke committed Feb 26, 2025
1 parent 1f564b2 commit acfb9c9
Show file tree
Hide file tree
Showing 11 changed files with 1,141 additions and 694 deletions.
14 changes: 12 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,16 @@ ESPFMfGK is the successor of Award Winning https://github.com/holgerlembke/ESPxW

It has a one-the-device file editor. And a persistent preview function.

# Features

* handles all file systems (FFAT, SD, SD_MMC, LittleFS, SPIFFS), all together
* flat view (all files in one go) or folder view
* upload files via drag and drop
* download, delete, rename, create new file
* included image preview and text editor
* authentication
* snap in coding style (just copy one file, it has all the code)

# File menu functions

### Download
Expand Down Expand Up @@ -47,7 +57,7 @@ Permanent editor windows! Just open a file in a windowed editor, change content,

### Preview

Opens a preview window for the file. It depends on what the browser can display, so everything editable and JPEG/PNG files should work. The windows existance is disconnected from the files existance, it is a snapshot.
Opens a preview window for the file. It depends on what the browser can display, so everything editable and JPEG/PNG files should work. The windows existence is disconnected from the files existence, it is a snapshot.

### Download all files

Expand All @@ -65,7 +75,7 @@ Defines are used to configure some basic features of ESPFMfGK.

## define fileManagerServerStaticsInternally

By design concept ESPFMfGK is inteded as "drop it in and that is it" solution. To archive that it includes
By design concept ESPFMfGK is intended as "drop it in and that is it" solution. To archive that it includes
its own html/css/javascript files. They are stored in code space and eat something around 35k.

If you want to reduce the code footprint, undefine that define and put the files from "filemanager" folder into the first added filesystem. No free lunch, either code space or file system.
Expand Down
9 changes: 9 additions & 0 deletions examples/advanced/ESPFMfGKdropin.ino
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// Adds the filé systems
void addFileSystems(void) {
// set configTzTime() in setup() to get valid file dates. Otherwise they are kaputt[tm].

// This adds the Storage into the Filemanager. You have to at least call one of those.
// If you don't, begin() will fail. Because a Filemanager without files is useless.

Expand Down Expand Up @@ -113,6 +115,13 @@ void setupFilemanager(void) {
filemgr.BackgroundColor = "white";
filemgr.textareaCharset = "accept-charset=\"utf-8\"";

// If you want authentication
// filemgr.HttpUsername = "my";
// filemgr.HttpPassword = "secret";

// display the file date? change here. does not work well if you never set configTzTime()
// filemgr.FileDateDisplay = ESPFMfGK::fddNone;

if ((WiFi.status() == WL_CONNECTED) && (filemgr.begin())) {
Serial.print(F("Open Filemanager with http://"));
Serial.print(WiFi.localIP());
Expand Down
4 changes: 2 additions & 2 deletions examples/advanced/advanced.ino
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ void setup() {
delay(10);
}

configTzTime("CET-1CEST,M3.5.0,M10.5.0/3", "pool.ntp.org", "");

addFileSystems();
setupFilemanager();


}

void loop() {
Expand Down
9 changes: 9 additions & 0 deletions examples/simple/ESPFMfGKdropin.ino
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
// Adds the filé systems
void addFileSystems(void) {
// set configTzTime() in setup() to get valid file dates. Otherwise they are kaputt[tm].

// This adds the Storage into the Filemanager. You have to at least call one of those.
// If you don't, begin() will fail. Because a Filemanager without files is useless.

Expand Down Expand Up @@ -87,6 +89,13 @@ void setupFilemanager(void) {
filemgr.BackgroundColor = "white";
filemgr.textareaCharset = "accept-charset=\"utf-8\"";

// If you want authentication
// filemgr.HttpUsername = "my";
// filemgr.HttpPassword = "secret";

// display the file date? change here. does not work well if you never set configTzTime()
// filemgr.FileDateDisplay = ESPFMfGK::fddNone;

if ((WiFi.status() == WL_CONNECTED) && (filemgr.begin())) {
Serial.print(F("Open Filemanager with http://"));
Serial.print(WiFi.localIP());
Expand Down
4 changes: 2 additions & 2 deletions examples/simple/simple.ino
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@ void setup() {
delay(10);
}

configTzTime("CET-1CEST,M3.5.0,M10.5.0/3", "pool.ntp.org", "");

addFileSystems();
setupFilemanager();


}

void loop() {
Expand Down
Loading

0 comments on commit acfb9c9

Please sign in to comment.