* Switched from Strict to Transitional... we DO want to use the target tag!
* Fixed some XHTML errors
This commit is contained in:
Stefan Ritter 2009-03-09 02:13:53 +01:00
parent aa2d5186f6
commit 1649dab547

View File

@ -76,8 +76,8 @@ if cname and ctext and ctitle:
content.close() content.close()
print 'Content-type: text/html\n' print 'Content-type: text/html\n'
print '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"' print '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"'
print ' "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">' print ' "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'
print '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">' print '<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">'
print ' <head>' print ' <head>'
print ' <title>' + blog_title + '</title>' print ' <title>' + blog_title + '</title>'
@ -145,7 +145,7 @@ if linklist == "True":
content = open("linklist", "r") content = open("linklist", "r")
for line in content: for line in content:
if not line.strip() is "": if not line.strip() is "":
print ' &nbsp;<a href=' + line.split(" ")[0] + ' target=_blank>' + line.split(" ", 1)[1].strip() + '</a>&nbsp;<br />' print ' &nbsp;<a href="' + line.split(" ")[0] + '" target="_blank">' + line.split(" ", 1)[1].strip() + '</a>&nbsp;<br />'
content.close() content.close()
print ' </div>' print ' </div>'
@ -177,7 +177,7 @@ else: # Show regular entry
print ' <div class="entrytitle"><a href="?p=' + title + '" class="entrytitle">' + title + ' <small>(' + date + ')</small></a></div>' print ' <div class="entrytitle"><a href="?p=' + title + '" class="entrytitle">' + title + ' <small>(' + date + ')</small></a></div>'
else: # ... or not else: # ... or not
print ' <div class="entrytitle">' + title + ' <small>(' + date + ')</small></div>' print ' <div class="entrytitle">' + title + ' <small>(' + date + ')</small></div>'
print ' <div class="entry"><p>' print ' <div class="entry">'
for line in content: for line in content:
print ' ' + line.strip() + '<br />' print ' ' + line.strip() + '<br />'
@ -213,7 +213,7 @@ else: # Show regular entry
if not comments_file and not post_display: if not comments_file and not post_display:
print ' <div class="comment">' print ' <div class="comment">'
print ' <ul><li><a href="?p=' + title + '" class="comment">no comments</a></li></ul>' print ' <ul><li><a href="?p=' + title + '" class="comment">no comments</a></li></ul>'
print ' </div><br />' print ' </div>'
elif comments_file and not post_display: elif comments_file and not post_display:
comments_content = open(comments_file[0], "r") comments_content = open(comments_file[0], "r")
comments_counter = 0 comments_counter = 0
@ -221,10 +221,10 @@ else: # Show regular entry
if line.split(".", 1)[0] == "-": comments_counter += 1 if line.split(".", 1)[0] == "-": comments_counter += 1
print ' <div class="comment">' print ' <div class="comment">'
print ' <ul><li><a href="?p=' + title + '" class="comment">comments (' + str(comments_counter) + ')</a></li></ul>' print ' <ul><li><a href="?p=' + title + '" class="comment">comments (' + str(comments_counter) + ')</a></li></ul>'
print ' </div><br />' print ' </div>'
comments_content.close() comments_content.close()
print ' </p></div>' print ' </div>'
print ' <br /><br />' print ' <br /><br />'
content.close() content.close()
entry_counter += 1 entry_counter += 1