AnsweredAssumed Answered

Passing a data URL as a parameter from a webviewer to filemaker file.

Question asked by madmike6537 on Oct 18, 2014
Latest reply on Oct 19, 2014 by steve_ssh



My ultimate goal is to pass an image that is created by my webviewer javascript code to filemaker.


As far as I can tell, I cant just pass the image as a parameter (please correct me if that is not right), so I am currently trying to pass it as a dataURL string and then Decode it inside my filemaker script.


Here is my code to send it to my filemaker file. The script runs, but the parameter always shows that its empty, as if nothing came accross. I am wondering if because of all the slashes and what not in the dataURL, that filemaker is not realizing that this is a string? I cant figure out how to make it more of a string then it already is though Maybe I am missing something simple...


var myParam = String(dataUrl.split(',').pop());

theURL = 'fmp://$/" & Get(FileName)& "?script=MoistureMap_Done&param=' + myParam;





dataUrl is my variable that stores the dataURL string.

Here I am using split and pop which basically cuts off the first part of the string which is the "image/png" stuff that comes before the actual data URL. If filemaker actually needs this let me know.


Thanks in advance to anyone that can help!