capitals or not

JavaScript and client side scripting.

Moderator: General Moderators

Post Reply
gavinbsocom
Forum Commoner
Posts: 71
Joined: Tue Sep 30, 2003 9:51 pm

capitals or not

Post by gavinbsocom »

does it matter if you type html in capitals or lower case? It doesnt matter right?
User avatar
JayBird
Admin
Posts: 4524
Joined: Wed Aug 13, 2003 7:02 am
Location: York, UK
Contact:

Post by JayBird »

nope, doesn't matter, as long as your consitent for readability, or just whatever you fancy really.

Mark
User avatar
infolock
DevNet Resident
Posts: 1708
Joined: Wed Sep 25, 2002 7:47 pm

Post by infolock »

html is not case-sensative by any means as bech pointed out. so <a HrEf .....> would work just like <a href....>
User avatar
nigma
DevNet Resident
Posts: 1094
Joined: Sat Jan 25, 2003 1:49 am

Post by nigma »

But if you are writing XHTML your tags need to be in lower case.

Valid XHTML markup: <a href="URLHERE">TEXTHERE</a>
Invalid XHTML markup: <A HREF="URLHERE">TEXTHERE</a>
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

that's becasue xhtml has that pesky xml case sensitivity... i guess it's good i met both languages at the same time about 7 years ago and just happen to prefer not to go for the shift key... gave me some goo habits now that html is being replaced by xhtml....
microthick
Forum Regular
Posts: 543
Joined: Wed Sep 24, 2003 2:15 pm
Location: Vancouver, BC

Post by microthick »

lower case html has been the recommendation since html 4.0 came out.

before that, uppercase was the recommendation.
maniac9
Forum Commoner
Posts: 55
Joined: Fri Aug 01, 2003 12:27 am
Location: Arkansas, USA
Contact:

Post by maniac9 »

eventually when browsers and everything go to xhtml and that becomes the standard, it will matter what case they are in, so do it lowercase...i think it's easier to read than upper anyways...
User avatar
nigma
DevNet Resident
Posts: 1094
Joined: Sat Jan 25, 2003 1:49 am

Post by nigma »

I always thought capitalizing your tag names looked silly and was a waste of time, so I never did it. When I discovered XHTML I had no nasty habits to break! w00t!
m3rajk
DevNet Resident
Posts: 1191
Joined: Mon Jun 02, 2003 3:37 pm

Post by m3rajk »

i think i have one... javascript... onClick...
User avatar
Saethyr
Forum Contributor
Posts: 182
Joined: Thu Sep 25, 2003 9:21 am
Location: Wichita, Kansas USA
Contact:

Post by Saethyr »

I have wierd habits when it comes to capitalization in my php code, My variables look as follows

NewVariableName

I cap the first letter out of habit


Saethyr
microthick
Forum Regular
Posts: 543
Joined: Wed Sep 24, 2003 2:15 pm
Location: Vancouver, BC

Post by microthick »

Saethyr wrote:I have wierd habits when it comes to capitalization in my php code, My variables look as follows

NewVariableName

I cap the first letter out of habit


Saethyr
I've noticed that that's often the standard that languages like vb and coldfusion employ.

usually c++, java go newVariableName.
User avatar
Saethyr
Forum Contributor
Posts: 182
Joined: Thu Sep 25, 2003 9:21 am
Location: Wichita, Kansas USA
Contact:

Post by Saethyr »

I started programming with VBScript so I guess I now know where that came from ;) Just seems easier to remember for me then the

Code: Select all

<?php
$newVariableName = "";
?>
type.
Post Reply