#Pass hidden values when using Input

1 messages · Page 1 of 1 (latest)

carmine aurora
#

I've been working with input for captive portals and wanted to pass hidden data based off the selection (in this case a drop down).
If you use font-size:0pt the text is passed but not shown in the dropdown.

This is a sample of how I'm building the list:
allPortals = json.append(allPortals,"<html><b>"+oneZone+":</b><br>"+getName(onePad,oneZone)+"<br><span style='font-size:0pt'>"+onePad+"</span>")]
you'll need to strip out the html via replace or a regex to "clean" the output to "raw text"

The input example image was attached.
The output example: Grasslands:^ActionPads Stairs Down Token^09BD04C5487B4F40936A0DCBF575A727

In this example I've hidden the mapID (and will be adding the tokenID the same way whilst hiding both from the user).

formal sphinx
#

Cool. I've also would create 2 arrays. First array is for the input formatting included and 2nd array has the values I want if picked in the first array. Input will return the index chose and I just use a json.get on the 2nd array.