[GH-ISSUE #1365] Arbitrary parameters for static html #1168

Open
opened 2026-02-28 01:28:50 +03:00 by kerem · 3 comments
Owner

Originally created by @tablatronix on GitHub (Feb 19, 2022).
Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1365

Allow adding arbitrary parameters with a visibility flag false, Use a new label placement?

Allow using parameters by id linked to static html form IDs to use param getters for value etc.

  • using null label for now internally for these
Originally created by @tablatronix on GitHub (Feb 19, 2022). Original GitHub issue: https://github.com/tzapu/WiFiManager/issues/1365 Allow adding arbitrary parameters with a visibility flag false, Use a new label placement? Allow using parameters by id linked to static html form IDs to use param getters for value etc. * using null label for now internally for these
Author
Owner

@tablatronix commented on GitHub (Feb 19, 2022):

e7623893f5

injected html from wherever, say a custom html param, might be problematic if outside the form..
webserver arg uses NAME not ID!

eg..

  WiFiManagerParameter custom_html("<p>This Is Custom HTML<input id=\"myhtmlinput\" name=\"myhtmlinput\" type=text></input</p>");`
<p>This Is Custom HTML<input id="myhtmlinput" name="myhtmlinput" type=text></input</p> // name is used for paramID server arg
 WiFiManagerParameter(const char *id, const char *defaultValue, int length);

 WiFiManagerParameter custom_staticarg("myhtmlinput","",40); // ID only for args, no html generated and output for these

<!-- gh-comment-id:1046102026 --> @tablatronix commented on GitHub (Feb 19, 2022): e7623893f580e059230f94f285909ef0289ab5fc injected html from wherever, say a custom html param, might be problematic if outside the form.. **webserver arg uses NAME not ID!** eg.. ```c++ WiFiManagerParameter custom_html("<p>This Is Custom HTML<input id=\"myhtmlinput\" name=\"myhtmlinput\" type=text></input</p>");` ``` ```html <p>This Is Custom HTML<input id="myhtmlinput" name="myhtmlinput" type=text></input</p> // name is used for paramID server arg ``` ```C++ WiFiManagerParameter(const char *id, const char *defaultValue, int length); WiFiManagerParameter custom_staticarg("myhtmlinput","",40); // ID only for args, no html generated and output for these ```
Author
Owner

@tablatronix commented on GitHub (Feb 22, 2022):

added dropdown example to
https://github.com/tzapu/WiFiManager/blob/master/examples/Super/OnDemandConfigPortal/OnDemandConfigPortal.ino

Note: Ideally this can be used in param child class instead to create custom form types instead of doing is this way..

<!-- gh-comment-id:1047923142 --> @tablatronix commented on GitHub (Feb 22, 2022): added dropdown example to https://github.com/tzapu/WiFiManager/blob/master/examples/Super/OnDemandConfigPortal/OnDemandConfigPortal.ino Note: Ideally this can be used in param child class instead to create custom form types instead of doing is this way..
Author
Owner

@tablatronix commented on GitHub (Feb 22, 2022):

branch: https://github.com/tzapu/WiFiManager/tree/feature_statichtmlparams

<!-- gh-comment-id:1047963875 --> @tablatronix commented on GitHub (Feb 22, 2022): branch: https://github.com/tzapu/WiFiManager/tree/feature_statichtmlparams
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/WiFiManager#1168
No description provided.