Slashdot Log In
NYTimes.com Hand-Codes HTML & CSS
Posted by
kdawson
on Tuesday April 29, @10:43PM
from the all-the-finest-sites dept.
from the all-the-finest-sites dept.
eldavojohn writes "The design director of NYTimes.com, Khoi Vinh, recently answered readers' questions in the Times's occasional feature 'Ask the Times.' He was asked how the Web site looks so consistently nice and polished no matter which browser or resolution is used to access it. His answer begins: 'It's our preference to use a text editor, like HomeSite, TextPad or TextMate, to "hand code" everything, rather than to use a wysiwyg (what you see is what you get) HTML and CSS authoring program, like Dreamweaver. We just find it yields better and faster results.'"
Related Stories
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
Full
Abbreviated
Hidden
Loading... please wait.

Great idea! (Score:5, Funny)
Reply to This
Re:That's nothing. (Score:5, Funny)
Reply to This
Parent
Another opportunity to post... (Score:4, Funny)
Reply to This
Re:Another opportunity to post... (Score:5, Funny)
Reply to This
Parent
W3C (Score:5, Informative)
Reply to This
Valid Markup != Good Code (Score:5, Interesting)
In the real world us web developers have to deal with interoperability on many different levels. We have to make sure the layout looks the same on Internet Explorer, Firefox, Opera, and Safari with Windows XP & Vista, OSX, and Linux using the same code base. Most of this however has a lot to do with how talented your CSS developer is. And unfortunately for you kiddies, any less isn't perfect.
So to spell it out for those that don't know, here's the real difference between WYSIWYG and pure text:
In a WYSIWYG editor you tend to do everything the same way every time you do it. That means that all your links, images, and code snippets come from the same code base and therefore have all the same pitfalls and good points. Unfortunatly the wonderful world of DOM doesn't work that way. HTML, CSS, JavaScript, and objects like Flash, Quicktime, and Java have very specific ways that they interact with each other and the browser and so what you generally find is that the reason you code by hand is not for the specific reason of coding by hand but simply put you really can not build good, quality websites with WYSIWYG editors. At some point you will most assuredly find yourself digging in the HTML.
Finally, on the topic of validating your markup. The Markup validaters that are out there are only good as tools of the trade and shouldn't be used as the end-all be-all certification of quality markup. They are tools that should be used by a web developer to run through and make sure they can be as close to valid as possible but I am willing to bet that out of the top 100 sites on the internet, the front page of all of them will produce Markup validation errors. The reason is simple: The validation rules are so restrictive that there is no point even worrying about them. It would be impossible to make a working website by being totally loyal to the markup rules.
Especially with the validator's stupidity in treating & signs in the href attribute of my a elements as the beginning of an entity which it's not!
Reply to This
Parent
Re:Valid Markup != Good Code (Score:4, Informative)
Yes, it is. Don't just take my word for it, take a look at what the HTML specification has to say on the matter [w3.org].
You are confusing a URI with the representation of that URI within an HTML document. Just because it appears as & in the document, it doesn't mean that's what you end up with after it has been parsed.
Reply to This
Parent
Re:W3C (Score:5, Interesting)
53 walmart.com
36 exxon.com
26 chevron.com
33 gm.com
76 conocophillips.com
0 ge.com
29 ford.com
52 citigroup.com
105 bankofamerica.com
26 att.com
28 www.berkshirehathaway.com
8 jpmorganchase.com
148 aig.com
55 hp.com
0 ibm.com
144 valero.com
2 verizon.com
180 mckesson.com
5 cardinalhealth.com
1082 www.goldmansachs.com
Reply to This
Parent
Re:W3C (Score:5, Informative)
No, it's not telling them that some browsers will think it's wrong, it's telling them it is wrong. Validators don't check to make sure browsers can understand your document, they check if you have made any syntax errors. Writing <br/> in an HTML document is wrong, regardless of any particular browser's handling of it.
Reply to This
Parent
Re:W3C (Score:5, Informative)
No, one is correct for XHTML and incorrect for HTML, and one is incorrect for XHTML and correct for HTML. The NYTimes use HTML. That means the XHTML syntax is incorrect.
Reply to This
Parent
Re:W3C (Score:4, Informative)
This is simply not true. It's incorrect and invalid.
What you may be thinking of is Appendix C of the XHTML 1.0 specification. It lays out a series of guidelines that minimise incompatibility with legacy user-agents. This means that it is relatively safe to transmit XHTML 1.0 documents following these guidelines as text/html. What it does not mean is that those XHTML 1.0 documents magically become valid HTML documents. They are not.
Reply to This
Parent
Re:W3C (Score:4, Informative)
Reply to This
Parent
Re:W3C (Score:4, Insightful)
Agreed. <br /> should be, AFAIK, guaranteed to work in any working HTML parser because all HTML browsers have to ignore unknown properties in tags, including potentially that slash, in order to be forward-compatible with future changes to the specification. Assuming they included the space, then IMHO the W3C validator is being way too pedantic (as usual). If they left out the space (<br/>), then the W3C validator is right to warn about it, as that form does choke some HTML parsers, IIRC.
Reply to This
Parent
Re:W3C (Score:4, Insightful)
That reasoning would work if the people behind XML had chosen any other character to indicate empty elements. But unfortunately, they chose the slash. Not many people realise because browser support is rare, but a slash inside an opening tag means that it is the end of the tag and the contents follow. Basically, <foo/>x/ is equivalent to <foo>>x</foo> .
So no, while parsers that don't implement HTML fully might mistakenly treat it like an attribute, a parser that fully implements HTML cannot do so, and a validator certainly shouldn't.
What on earth do you think a validator is for, if not to point out syntax errors? Do you complain that your spelling checker is being pedantic when it tells you that you have misspelt something?
Reply to This
Parent
Re:W3C (Score:5, Informative)
It may or may not be improper American English, but "misspelt" is certainly correct English. Consult the OED [askoxford.com] if you don't believe me.
This is far from the first time I've had an ignorant American attempt to "correct" my proper English into your regional dialect. It's pretty annoying and reinforces negative aspects of your national stereotype.
Reply to This
Parent
Re:W3C (Score:5, Insightful)
Reply to This
Parent
Re:W3C (Score:5, Informative)
I knew somebody would pop up with this misconception. Did you know that the web has already been through this — not once but twice — and proven you wrong?
Netscape 2 was quite aggressive when it came to guessing when ampersands were mistakenly unencoded. Cue lots of people not bothering to do things correctly, and saying things exactly like you are — "What's the point? It makes no difference!"
Then Netscape 3 came out. It wasn't as aggressive as Netscape 2. All those people who cut corners had to rush to fix all of their pages. All the people who did it correctly the first time around didn't have to do any extra work.
Now Netscape 3 still guessed a little bit — if you left off the semicolon, it would pick up on it and guess correctly. So lots of the dumb people from the previous example didn't learn their lesson, and skipped the semicolon.
Can you guess what happened? Yep, that's right, Netscape 4 came out and broke all their pages again. And all the people who did things correctly laughed at them.
Sure, if you don't bother to do things right, today's major browsers will probably guess that you're an idiot and work around your bugs. But there's certainly no guarantee that tomorrow's browsers will do so. When you can do things correctly right now for no effort, why on earth would you risk incurring extra work in the future? Is it really so difficult to type & instead of &?
Reply to This
Parent
Dreamweaver is an excellent tool (Score:5, Interesting)
1. DW lets you code at the source code level if you choose.
2. DW is much faster--in Design View--at creating tables.
3. DW allows for flipping back and forth or split view.
4. DW does not rewrite your code (for the most part).
I use DW every day. I am not even conscious of flipping between the 2 views. Some things are done better in Design View and some in Code View.
CSS support is very good in DW.
Reply to This
I feel OLD. (Score:4, Funny)
Reply to This
Doesn't everyone? (Score:4, Informative)
Reply to This
And that's not all... (Score:5, Funny)
Reply to This
Re:Benefits vs Issues (Score:5, Insightful)
1. Handcoding takes a lot more effort and needs more 'actual' writers than before. So more techies keep their jobs in a recession.
Score: Hancoding 1: Dreamweaver: 0
Score: Hancoding 2: Dreamweaver: 0
Score: Hancoding 2: Dreamweaver: 1
Score: Hancoding 2: Dreamweaver: 2
I hate them for wasting my money as a shareholder.
Reply to This
Parent
Re:Hand-coding? (Score:5, Funny)
Hand-coding agent: I hate this guy, he's refreshing his browser every minute on the same news. I can't keep up.
Hand-coding supervisor: PrintScreen it!
Hand-conding agent: Brilliant!
Reply to This
Parent
Re:Hand-coding? (Score:5, Funny)
Reply to This
Parent
Re:text editors (Score:4, Funny)
Reply to This
Parent