Including and accessing an HTML page in a .sparkle file

I have created an HTML file using software unrelated to Sparkle. It is one big HTML page containing a lot of charts and it is stored on my desktop computer. It displays well locally in my browser when I double-click the file.

I would like to incorporate this HTML file in my .sparkle file and allow the user to open the HTML file in a separate window by clicking on a button in my Sparkle website.

How can I do this? Help will be much appreciated.

Philip

Hi @Phil, you would firstly need to put this html file up to your hosting server where you have Published your Sparkle website. You would open that file as an URL in the browser (based on how you have set it up on your hosting serverā€¦ for example if your domain is www.phil.com and you have placed the html file in a folder called ā€œchartsā€, the the final URL would be www.phil.com/charts/filename.html

On the Sparkle end you would link a button to an external link (your URL in this case) and make sure Open In New Page is ticked.

I hope that helps! :slight_smile:

Thanks FlaminFig. I guess Iā€™ll do it that way. But I was hoping I could build the HTML file into the .sparkle file that is my website, similar to how I can include a JPEG or PNG file in the .sparkle file. My HTML file is a very simple ā€˜flatā€™ one with no complications like buttons or menus. But I understand from your helpful reply that this is not feasible, or at least not a reasonable thing to do, for an HTML file.

You then also could try placing your html file content into an Embed element which you place on the Sparkle canvasā€¦ with it being active you will see on the right hand side an input container where your can place your html content.

Make sure you tick Content Expands Vertically.

That sounds promising. Iā€™ll give it a try. Much appreciated.

1 Like