[Xsltforms-support] dynamic include of SVG image
Brought to you by:
alain-couthures
From: Dan M. <dan...@gm...> - 2014-09-26 14:24:14
|
Hi folks, I have a form that the user is uploading a SVG image and I would like to show a preview of it after the file has been selected. I have seen that the <xf:include src=""> element allows us to place the SVG image in the form like this: <xf:include src="images/blue-circle.svg"/> Here is the example on github: https://github.com/AlainCouthures/xsltforms/blob/master/testsuite/samples/flags.xhtml Is there a way to dynamically load the image? I tried: <xf:include src="images/{$filename}"/> but that did not work. Perhaps some combination of an XForms on-change event and xf:load? Thanks! - Dan -- Dan McCreary http://danmccreary.com Co-author: Making Sense of NoSQL <http://manning.com/mccreary> office: (952) 931-9198 cell: (612) 986-1552 skype: dmccreary47 |