Jump to content

html structure


anarchojoseph
 Share

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.

Edited by thescientist
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

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...