Creating a dynamically-built HTML form from Storyline
Oct 18, 2016
I did consider creating an HTML file that could accept key/value pairs on the URL line that could be parsed and written to the page, but again, that really wasn't an option. I couldn't add files. I suppose I could have created the HTML page and landed it somewhere else, but that might turn complicated fairly quickly.
Some of my considerations:
- I had to include 24 variables from SL and show them in a table
- I had to include a branding graphic, but not link to it (again, because I could not add files to the SCO)
Setting up the page and including the variables wasn't hard. But the branding graphic was going to take a little bit of thought. What I ended up doing was this:
1) Convert my original *.png graphic to an *.svg graphic
2) Copied the SVG code from the *.svg graphic to the appropriate place in my new dynamic page
[When you open up the text file and look at it, the SVG image is that large string of characters in the middle.]
The entire string variable that gets written is created line-by-line. Each line has to be wrapped in double-quotes, and added to the string down the page before the write command. Also, any HTML markup that has quotes within in it needs to be changed to single-quotes - like in my in-line CSS (I know, sloppy coding.)
This is my over-thought solution. Have fun!
This discussion is closed. You can start a new discussion or contact Articulate Support.