random1 Posted October 19, 2011 Share Posted October 19, 2011 Hey All, I'm trying to get some opinions on source code formatting in HTML (using the TAB character). For example: <html> <head> <title>TITLE</title> </head> <body> <div> <div> <div> test </div> </div> </div> </body> </html> VS <html> <head> <title>TITLE</title> </head> <body> <div> <div> <div> test </div> </div> </div> </body> </html> I already tab indent any of my PHP source files however I haven't for HTML source files. What do you think is the better choice for HTML? Should there be a limit set of how many levels of indent to avoid it getting to hard to follow? Link to comment https://forums.phpfreaks.com/topic/249361-html-source-code-tab-indenting/ Share on other sites More sharing options...
trq Posted October 19, 2011 Share Posted October 19, 2011 I usually only use 2 (spaces) for HTML. You shouldn't really use tabs in PHP either as it's not consistent enough across editors. Link to comment https://forums.phpfreaks.com/topic/249361-html-source-code-tab-indenting/#findComment-1280468 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.