Remove xhtml-strict and xhtml-transitional, add html (html5)
This commit is contained in:
parent
f761993f39
commit
c6ad68e0cf
17
blogthon.cgi
17
blogthon.cgi
@ -38,7 +38,7 @@ def generate_uuid(string):
|
||||
return string
|
||||
|
||||
def errorpage(string):
|
||||
document_header("xhtml-strict")
|
||||
document_header("html")
|
||||
print "<head>"
|
||||
print tab + "<title>Error!</title>"
|
||||
print tab + "<link rel=\"stylesheet\" type=\"text/css\" href=\"error.css\" />"
|
||||
@ -53,16 +53,9 @@ def errorpage(string):
|
||||
sys.exit()
|
||||
|
||||
def document_header(string):
|
||||
if string == "xhtml-transitional":
|
||||
print "Content-type: text/html\n"
|
||||
print "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\""
|
||||
print " \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\">"
|
||||
print "<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\">"
|
||||
if string == "xhtml-strict":
|
||||
print "Content-type: text/html\n"
|
||||
print "<!DOCTYPE html PUBLIC \"-//W3C//DTD XHTML 1.0 Strict//EN\""
|
||||
print " \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd\">"
|
||||
print "<html xmlns=\"http://www.w3.org/1999/xhtml\" xml:lang=\"en\">"
|
||||
if string == "html":
|
||||
print "<!DOCTYPE html>"
|
||||
print "<html>"
|
||||
if string == "atom":
|
||||
print "Content-type: application/atom+xml\n"
|
||||
print "<?xml version=\"1.0\" encoding=\"utf-8\"?>"
|
||||
@ -339,7 +332,7 @@ elif feed_display == "rss":
|
||||
|
||||
# Generate regular page
|
||||
else:
|
||||
document_header("xhtml-strict")
|
||||
document_header("html")
|
||||
print tab + "<head>"
|
||||
print tab*2 + "<title>%s</title>" % blog_title
|
||||
print tab*2 + "<meta http-equiv=\"content-type\" content=\"text/html; charset=utf-8\" />"
|
||||
|
Loading…
Reference in New Issue
Block a user