I know this is an old thread, but I thought I would add an updated answer as I recently decided to implement a convention for embedding jsFiddles into Markdown posts (while remaining sanitized)
The convention I came up with was the following:
// render jsFiddle embed iframe with default options
$[http://jsfiddle.net/uzMPU/]
// render jsFiddle embed iframe with specific tabs
$[http://jsfiddle.net/uzMPU/][result,js,css]
In addition, following similar convention to links and images, referencing the link by id will also be valid:
// render jsFiddle embed iframe with default options
$[1]
// render jsFiddle embed iframe with specific tabs
$[1][result,js,css]
[1]: http://jsfiddle.net/uzMPU/
This would result in the following iframes being rendered as the following:
<iframe src="http://jsfiddle.net/uzMPU/embedded/" allowfullscreen="allowfullscreen" frameborder="0"></iframe>
<iframe src="http://jsfiddle.net/uzMPU/embedded/result,js,css/" allowfullscreen="allowfullscreen" frameborder="0"></iframe>
(In reality, I have modified this slightly, and included a style tag: width: 100%; height: 300px;
by default)
In addition to the $[]
syntax, I have made it a requirement that the $[]
be entirely on it's own line. As a result, writing the following:
This is an inline $[http://jsfiddle.net/uzMPU] fiddle looking link
will not result in an iframe being rendered.
I implemented this with some additions to MarkdownSharp (which is what stack uses to process the markdown AFAIK) and blogged about it in my post Extending Markdown/MarkdownSharp for jsFiddle embedding
I am definitely in the camp that this would be very helpful and nice for js/html/css tagged questions... Although I also think that there would be issues having too many "links as answers" essentially.