summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorot <ot@localhost>2007-04-19 07:28:43 +0000
committerot <ot@localhost>2007-04-19 07:28:43 +0000
commit7e08b8aa2c3ec89611d4e7742555500b9023c475 (patch)
treee5ff63b13e36e3751fc9bace85d6d7b77a141c6a
parent196a0b95676cab4ee86d2d6237fce6b5f8c7be98 (diff)
downloadmarkup-validator-7e08b8aa2c3ec89611d4e7742555500b9023c475.zip
markup-validator-7e08b8aa2c3ec89611d4e7742555500b9023c475.tar.gz
markup-validator-7e08b8aa2c3ec89611d4e7742555500b9023c475.tar.bz2
fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=4472
(outline for non xml-based languages) by making heading-selection regexp case insensitive.
-rwxr-xr-xhttpd/cgi-bin/check8
1 files changed, 4 insertions, 4 deletions
diff --git a/httpd/cgi-bin/check b/httpd/cgi-bin/check
index 7f96afd..d7e2d8c 100755
--- a/httpd/cgi-bin/check
+++ b/httpd/cgi-bin/check
@@ -14,7 +14,7 @@
# This source code is available under the license at:
# http://www.w3.org/Consortium/Legal/copyright-software
#
-# $Id: check,v 1.501 2007-04-18 06:32:52 ot Exp $
+# $Id: check,v 1.502 2007-04-19 07:28:43 ot Exp $
#
# Disable buffering on STDOUT!
@@ -180,7 +180,7 @@ Directory not readable (permission denied): @_r
#
# Strings
- $VERSION = q$Revision: 1.501 $;
+ $VERSION = q$Revision: 1.502 $;
$VERSION =~ s/Revision: ([\d\.]+) /$1/;
#
@@ -2241,7 +2241,7 @@ sub W3C::Validator::SAXHandler::data
sub W3C::Validator::SAXHandler::start_element
{
my ($self, $element) = @_;
- if ($element->{Name} =~ /^h([1-6])$/) {
+ if ($element->{Name} =~ /^h([1-6])$/i) {
$self->{_file}->{heading_outline} = $self->{_file}->{heading_outline} . " " x int($1) . "[". $element->{Name}."] ";
$self->{am_in_heading} = 1;
@@ -2322,7 +2322,7 @@ sub W3C::Validator::SAXHandler::start_element
sub W3C::Validator::SAXHandler::end_element
{
my ($self, $element) = @_;
- if ($element->{Name} =~ /^h[1-6]$/) {
+ if ($element->{Name} =~ /^h[1-6]$/i) {
$self->{_file}->{heading_outline} = $self->{_file}->{heading_outline} . "\n";
$self->{am_in_heading} = 0;
}