aboutsummaryrefslogtreecommitdiff
path: root/plugin/markdown
diff options
context:
space:
mode:
authorHakim El Hattab <hakim.elhattab@gmail.com>2014-04-06 10:16:46 +0200
committerHakim El Hattab <hakim.elhattab@gmail.com>2014-04-06 10:16:46 +0200
commit2eb3d082ce0d406b128c17e03b53ee2ccb7a500d (patch)
tree25e495494904e53b6bb4c785039c21648704fcad /plugin/markdown
parent3aaca471b193cf2ff4bb54432e59798b6c688a43 (diff)
parent873f2dbc96e712d1afbc2f197c8b60287d7f728c (diff)
downloadfreenode-live-2017-presentation-2eb3d082ce0d406b128c17e03b53ee2ccb7a500d.tar
freenode-live-2017-presentation-2eb3d082ce0d406b128c17e03b53ee2ccb7a500d.tar.gz
Merge branch 'xhr-local' of https://github.com/malyw/reveal.js into dev
Diffstat (limited to 'plugin/markdown')
-rwxr-xr-xplugin/markdown/markdown.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugin/markdown/markdown.js b/plugin/markdown/markdown.js
index 718475b..9c0c91a 100755
--- a/plugin/markdown/markdown.js
+++ b/plugin/markdown/markdown.js
@@ -219,7 +219,10 @@
xhr.onreadystatechange = function() {
if( xhr.readyState === 4 ) {
- if ( xhr.status >= 200 && xhr.status < 300 ) {
+ if (
+ (xhr.status >= 200 && xhr.status < 300) ||
+ xhr.status === 0 // file protocol yields status code 0 (useful for local debug, mobile applications etc.)
+ ) {
section.outerHTML = slidify( xhr.responseText, {
separator: section.getAttribute( 'data-separator' ),