Well I know obfuscation is a bad idea. But I want all of my html code to come in one long single line. All the html tags are generated through PHP, so I think its possible.
This is already well answered, but you may be able to do more than just trim spaces at both ends of each line:
tags and do the same as step #1>_< with >< (_ = space)_>, <_ and with >, < and (_ = space)This procedure can potentially compact the entire HTML file. This takes advantage of the fact that multiple white-space text inside HTML tags are intepreted as one single space.