summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorduerst <duerst@localhost>2002-08-30 07:26:10 +0000
committerduerst <duerst@localhost>2002-08-30 07:26:10 +0000
commit31c787f2304cc8c85db328cb5ccc9ae350ab4f04 (patch)
tree78c633da10f7616081db1cfb310af10c0b44f784
parentc73a4f9948296cd1e7b50649ffeb8d0d9af3a50e (diff)
downloadmarkup-validator-31c787f2304cc8c85db328cb5ccc9ae350ab4f04.zip
markup-validator-31c787f2304cc8c85db328cb5ccc9ae350ab4f04.tar.gz
markup-validator-31c787f2304cc8c85db328cb5ccc9ae350ab4f04.tar.bz2
got rid of T_CHARSET_KLUDGE
-rwxr-xr-xhttpd/cgi-bin/check53
1 files changed, 13 insertions, 40 deletions
diff --git a/httpd/cgi-bin/check b/httpd/cgi-bin/check
index 15a6447..e8c6c7b 100755
--- a/httpd/cgi-bin/check
+++ b/httpd/cgi-bin/check
@@ -9,7 +9,7 @@
# This source code is available under the license at:
# http://www.w3.org/Consortium/Legal/copyright-software
#
-# $Id: check,v 1.219 2002-08-30 07:07:55 duerst Exp $
+# $Id: check,v 1.220 2002-08-30 07:26:10 duerst Exp $
#
# Disable buffering on STDOUT!
@@ -68,8 +68,6 @@ use constant T_WARN => 4; # 0000 0100
use constant T_ERROR => 8; # 0000 1000
use constant T_FATAL => 16; # 0001 0000
-use constant T_CHARSET_KLUDGE => 128; # 1000 0000
-
#
# Output flags for error processing
use constant O_SOURCE => 1; # 0000 0001
@@ -97,7 +95,7 @@ BEGIN {
#
# Strings
- $VERSION = q$Revision: 1.219 $;
+ $VERSION = q$Revision: 1.220 $;
$VERSION =~ s/Revision: ([\d\.]+) /$1/;
@@ -153,7 +151,7 @@ $File->{'Header'} = &prepSSI({
});
$File->{'Footer'} = &prepSSI({
File => $CFG->{'Footer'},
- Date => q$Date: 2002-08-30 07:07:55 $,
+ Date => q$Date: 2002-08-30 07:26:10 $,
});
#
@@ -1582,23 +1580,13 @@ sub report_valid {
print qq( <h2 class="valid">This document is well-formed XML.</h2>\n);
} elsif (defined $File->{Tentative}) {
print qq(<h2 class="valid">This Page Is Valid $File->{Version}!</h2>);
- if ($File->{Tentative} == T_CHARSET_KLUDGE) {
- print &daily_tip($File, $CFG->{'Tips DB'});
- &print_warnings($File);
- print "
- <p>
- This document would validate as $File->{Version} if you updated it to
- specify the Character Encoding used.
- </p>\n";
- } else {
- print &daily_tip($File, $CFG->{'Tips DB'});
- &print_warnings($File);
- print "
- <p>
- This document would validate as $File->{Version} if you updated it to
- match the Options used.
- </p>\n";
- }
+ print &daily_tip($File, $CFG->{'Tips DB'});
+ &print_warnings($File);
+ print "
+ <p>
+ This document would validate as $File->{Version} if you updated it to
+ match the Options used.
+ </p>\n";
} else {
print qq( <h2 class="valid">This document validates as the document type specified!</h2>\n);
print <<".EOF.";
@@ -2009,31 +1997,16 @@ sub charset_conflicts {
my $File = shift;
#
# Handle the case where there was no charset to be found.
- # (This is a different issue from whether an override was given!)
unless ($File->{Charset}->{Use}) {
- if (&is_xml($File->{Type})) {
- $File->{Charset}->{Use} = 'UTF-8';
- &add_warning($File, <<" .EOF.");
- <strong>No Character Encoding detected!</strong>
- To ensure correct validation, processing, and display,
- it is important that the character encoding is properly
- labeled.
- <a href="http://www.w3.org/International/O-charset.html">More
- information...</a>
- .EOF.
- $File->{Tentative} |= T_CHARSET_KLUDGE; # Would be T_WARN, but the complaints...
- } else {
- $File->{Charset}->{Use} = 'UTF-8'; # @@@FIXME@@@: This needs thought!
- &add_warning($File, <<" .EOF.");
+ &add_warning($File, <<" .EOF.");
<strong>No Character Encoding detected!</strong>
To ensure correct validation, processing, and display,
it is important that the character encoding is properly
labeled.
<a href="http://www.w3.org/International/O-charset.html">More
information...</a>
- .EOF.
- $File->{Tentative} |= T_CHARSET_KLUDGE; # Would be T_WARN, but the complaints...
- }
+ .EOF.
+ $File->{Tentative} |= T_WARN;
}
#