Revert "Web: Disable @title and @doctype for non-HTML documents." (incompatible with Python 2)

This reverts commit 34b0e5faadf7c042bd911cdc392e673e6889fa0e.