anarchojoseph Posted March 26, 2010 Share Posted March 26, 2010 <tr> <td>100</td> What does the space mean when coding? Why do people do that when coding in html? Is it so that you can be better organized? And, lastly, is there a program that does this? because I use notepad++ and when I type in the same snippet of code I get <tr><td>100</td> should I double space manually? I've always wondered why people do this but I was never sure Link to comment Share on other sites More sharing options...
thescientist Posted March 26, 2010 Share Posted March 26, 2010 indentation is much preferred way of adding organization, structure, and readability to code. I prefer to use a tab setting of 2 spaces. Link to comment Share on other sites More sharing options...
jeffman Posted March 26, 2010 Share Posted March 26, 2010 1. An organization that is easy to visualize is not very useful until something goes wrong or needs to be changed.2. Something always goes wrong.3. Something always needs to be changed. Link to comment Share on other sites More sharing options...
Synook Posted March 27, 2010 Share Posted March 27, 2010 Note that while in HTML whitespace has no special meaning, in some programming languages such as Python indentation is the only way you can specify blocks of code. Link to comment Share on other sites More sharing options...
knystrom18 Posted March 28, 2010 Share Posted March 28, 2010 Yep. DD said it right. Theoretically, the code for a site could all be on one line, or a character per line, indentation is purely organizational. Link to comment Share on other sites More sharing options...
Synook Posted March 28, 2010 Share Posted March 28, 2010 Yep. DD said it right. Theoretically, the code for a site could all be on one line, or a character per line, indentation is purely organizational.Err, there are some things that can't be split, for example an element can't be written:<a href = "test">a</hr> But in terms of non-syntactic structures, then yes. Link to comment Share on other sites More sharing options...
knystrom18 Posted March 28, 2010 Share Posted March 28, 2010 That seems right, and I feel silly for saying a character per line. I should have said a tag per line. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.