Export XHTML Pages

When a Web uses one of the Markdown Text Filters, and you export
all the pages as a zip file, you'd like the MathML and SVG to
render when the pages are viewed locally. This means saving them
with a .xhtml extension. Users of non-XHTML-capable browsers or
Textile users should still get .html files.
This commit is contained in:
Jacques Distler 2009-01-23 11:02:16 -06:00
parent 13b7e1d766
commit 0b2a6935a2
6 changed files with 64 additions and 20 deletions

View file

@ -52,7 +52,7 @@ class UrlGenerator < AbstractUrlGenerator
case mode
when :export
if known_file
%{<a class="existingWikiWord" title="#{description}" href="#{CGI.escape(name)}.html">#{text}</a>}
%{<a class="existingWikiWord" title="#{description}" href="#{CGI.escape(name)}.#{@controller.html_ext}">#{text}</a>}
else
%{<span class="newWikiWord">#{text}</span>}
end
@ -79,7 +79,7 @@ class UrlGenerator < AbstractUrlGenerator
case mode
when :export
if known_page
%{<a class="existingWikiWord" href="#{CGI.escape(name)}.html">#{text}</a>}
%{<a class="existingWikiWord" href="#{CGI.escape(name)}.#{@controller.html_ext}">#{text}</a>}
else
%{<span class="newWikiWord">#{text}</span>}
end
@ -142,5 +142,5 @@ class UrlGenerator < AbstractUrlGenerator
%{<span class="deleteWikiWord">[[#{name}:delete]]</span>}
end
end
end