Well, this page works fine on my computer as an HTML file… And it works fine on jsfiddle as well. However, if I try to put this HTML code inside a tiddler with the type text/html I get the following result:
I’d like to be able of creating some web pages inside my tiddlers. I have seen that it’s possible to set the type text/html inside a tiddler, but even though the HTML created with this type works with simple cases, it doesn’t work when I create more complex pages with javascript libraries declared in it. Is it possible to make a tiddler display the webpage from an HTML code that is inside the tiddler? Or did I get it wrong and the type text/html is not supposed to be used like that?
You were right, actually using an iframe with jsfiddle worked better for my case. Since there I have syntax highlight and more specific functionalities for web development… So using:
You can definitely put any kind of HTML (well, HTML elements) and CSS in any tiddler, but not javascript.
The only advantage of embedding the HTML+CSS+javascript right in a tiddler would be for off-line viewing of that content. Or the content from the external site does not allow embedding in an iframe.