summaryrefslogtreecommitdiff
path: root/lib/VNDB/Util/CommonHTML.pm
diff options
context:
space:
mode:
authorYorhel <git@yorhel.nl>2015-11-01 13:42:56 +0100
committerYorhel <git@yorhel.nl>2015-11-01 13:43:50 +0100
commit8c9cfe238e565088b37d256eb461a01919ef9968 (patch)
tree56143b98815c308aa84dc626a91364db5eadec23 /lib/VNDB/Util/CommonHTML.pm
parent3c967881d7b5408a49f16de8b268b053d6ba9051 (diff)
Switch to HTML5 doctype + s/acronym/abbr/ + s/&nbsp;/&#xa0;/e
I'd have preferred to stick with XHTML 1.0, but unfortunately browsers won't allow you to use modern Javascript APIs with an older doctype. Note that most pages don't actually validate correctly as HTML5, I'm relying on browsers to be lenient. In either case, I'd like VNDB to stay valid XML (XHTML5, then), and luckily that shouldn't be a problem.
Diffstat (limited to 'lib/VNDB/Util/CommonHTML.pm')
-rw-r--r--lib/VNDB/Util/CommonHTML.pm8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/VNDB/Util/CommonHTML.pm b/lib/VNDB/Util/CommonHTML.pm
index bcc2ea97..7504ace8 100644
--- a/lib/VNDB/Util/CommonHTML.pm
+++ b/lib/VNDB/Util/CommonHTML.pm
@@ -204,12 +204,12 @@ sub htmlRevision {
table class => 'stripe';
thead;
Tr;
- td; lit '&nbsp;'; end;
+ td; lit '&#xa0;'; end;
td; revheader($self, $type, $old); end;
td; revheader($self, $type, $new); end;
end;
Tr;
- td; lit '&nbsp;'; end;
+ td; lit '&#xa0;'; end;
td colspan => 2;
b mt '_revision_edit_summary', $new->{rev};
br; br;
@@ -439,6 +439,7 @@ sub htmlSearchBox {
sub htmlRGHeader {
my($self, $title, $type, $obj) = @_;
+ # This used to be a good test for inline SVG support, but I'm not sure it is nowadays.
if(($self->reqHeader('Accept')||'') !~ /application\/xhtml\+xml/) {
$self->htmlHeader(title => $title);
$self->htmlMainTabs($type, $obj, 'rg');
@@ -452,8 +453,7 @@ sub htmlRGHeader {
$self->htmlFooter;
return 1;
}
- $self->resHeader('Content-Type' => 'application/xhtml+xml; charset=UTF-8');
- $self->htmlHeader(title => $title, svg => 1);
+ $self->htmlHeader(title => $title);
$self->htmlMainTabs($type, $obj, 'rg');
return 0;
}