Simple Base64 Encoder/Decoder

i want to share this Base64 Encoder/Decoder app i made just to try the webviewer extension that allows us to apply javascript coded functions on data. in this case, the functions for encoding and decoding base64 are already standard functions in javascript. the full messages being passed are shown in the examples below. (i “borrowed” the server that @actech provided in one of his recent examples to illustration this webviewer extension. thank you!):


<script>function encode(data){return btoa(data)}; ThunkableWebviewerExtension.postMessage(encode("142857"));</script>

<script>function encode(data){return atob(data)}; ThunkableWebviewerExtension.postMessage(encode("MTQyODU3"));</script>

here’s a copy of the project:

1 Like

replace test if switch is to if switch only’(remove == and true block) and it will work
thanks allot