Tuesday, August 26, 2003

What's the difference between using a class inside a table cell tag and using a span tag in a table cell?

In other words what is the difference between:

<td class="myClass"></td>

<td><span class="myClass"></span></td>

In the first case you are applying your class to a block level element (<td>) whereas in the latter case the <span> creates an inline element.

The first example will apply to all the content in the td (or the cell itself) whereas the second one applies only to the items wrapped in the span and does not effect the cell itself.

As to whether it matters, it depends on what you're doing with the style. If you are just setting font styles, then either is probably fine. If you're going to do a background color or underlining or padding effects, you need to consider if you want that applied to the text block or to the cell. See the example below.

There are still a few browsers which won't apply styles within a <td>, including NS4.x.
In general, unless you’re designing for these browsers, use the class in the table tag. The span is just an extra piece of code. Try to reserve using span to very discreet items. For instance: a word that receives special treatments.

Saturday, May 24, 2003

Why do we still have <u>?

Is there any reason for the <u> tag to exist? Underlining text was a means to highlight typewriting text. Typewriters, as useful as they were, were limited to a single font and size. Underlining text in these pre-published manuscripts was a kludge, allowing users to emphasize a particular portion of the text.

We understand why <u> was initially created: the web was originally conceived as a means for academics to exchange ideas. Since academic papers used underlines as a means of emphasizing reference titles; and since the people who created the original web standards still thought in terms of the typewriter they naturally included the <u> tag.

However a decade has gone by since Mosaic / Netscape revolutionized the web. What do we need the <u> for? Underlines are the default means of displaying a link and will remain that way for the foreseeable future even though underlines deface the types’ descenders. Still, usability trumps aesthetics in this case. As a result of underlines being used (almost) exclusively to designate links few professionals use the <u> tag anymore except when designers mean to evoke the look and feel of typewritten text.

This is a minor issue as there is no overriding reason to pull the <u> tag. Still, Web Standards are an evolving project – and this kludge from a bygone era needs to go.

Thursday, May 1, 2003

How to deal with spam, unsolicited email?

As with pornographic pages it should be easy for the recipient to automatically delete or block it.

Legally spammers are protected by first amendment rights of freedom of speech. This right however doesn’t let them to force others to accept their solicitations.

There are precedents – flyers placed in mailboxes and on doorsteps. As with the flyers a no thank you sign should be an acceptable compromise. Granted, all other things being equal, it would be the same with spam.

On the surface there is a simple solution. As Senator Schumer suggested all unsolicited email should have ADV (short for advertisement) as the first 3 letters of the subject line. Then people could delete or filter the email without first seeing them.

There is a slight problem with the application of the law. It doesn’t apply to non-US citizens and from marketers based outside of the US. Nor is it possible to prevent the email from “crossing the border.” For those unfamiliar with the internet, the internet was designed to keep information flowing in case of accident or attack. There is, for all practical purposes, no way of preventing spam from entering the country.

The end result is that companies in the US would place “ADV” or some such indication that it is an unsolicited advertisement and companies outside would still be able to send their spam unhindered. Unscrupulous American marketers would then move their base of operations, or hire foreign firms to send the spam.

Is there a way to deal with this? Yes there is. It’s a wonderfully evil way, and that is to spam the spammers. How do we do this? There are anti-spamming organizations that do just this. The only thing is that it’s not legal for them to do so, so involvement is tricky.

How does, or could, the anti-spamming work? When you get spam you forward it to the anti-spamming organization. They would then, after checking to be sure that it is spam, send your email back to the spammer. Now just sending it back won’t discourage the spammer, but if they send it to him 1000 times a minute for a couple hours, perhaps the spammer will get the point. The more spams the person sends out, the more spams he gets back. In time those sending unsolicited spam will get so frustrated that they will change their ways. Thousands upon thousands of useless responses will do that. Especially as it will cost time and money for them to go through all these responses.

That leads to a little problem. It costs money to send these fight-back emails. To fight back you, the recipient of these emails would have to pay a little to fight back. It won’t have to be much; if millions contribute it would only be at most a dollar or two for everyone and probably a whole lot less. After the first few rounds I think the out-of-country spammers will see that it’s not worth the hassle.

Saturday, March 8, 2003

The Pinball Effect, James Burke

It's a fun and easy read for someone who loves the history of science and technology. I think it would be terribly convoluted for someone who has little to no knowledge on the subject. As much as I like the The Pinball Effect it is fundamentally flawed book. I'm not talking about the few historical flaws, but nstead the books unstated and underlying premise that correlation equals causation.

James Burke is an educated man and would never argue that point but each chapter, while fun to read, implies that each discovery/invention led to the next and the next. It's tantamount to saying that the shooting of the Archduke Ferdinand led to WWI which led to the allies dismembering the Ottoman Empire, which led to Osama bin Laden and 9/11.

We all see the correlation but there is no causation. History is not so neat.