Jump to content

html structure


anarchojoseph

Recommended Posts

<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

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

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

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

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

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...