4

What are cons to using deprecated elements if I don't care about validation and I use that DTD which supports them? Will deprecated elements will not be rendered by future browsers?

Some online WYSIWYG editors (which we use in CMS) still give output in deprecated elements. Must I invest the time to change the output for a client?

alt text http://easycaptures.com/fs/uploaded/241/3445655293.jpg

Should we avoid deprecated elements at any cost?

Currently all mainstream browsers show all deprecated elements.

I just wanted to know the disadvantages of using deprecated elements to give to a non technical client even if all are working today in all browsers.

Update:

you can meet guideline 1.3 ensure that information and structure can be separated from presentation by using font and align elements if you like. Yes, that’s right. You can use an element which was deprecated in HTML 4.01 nine years ago that ties the presentation of your page is into the page structure and content — there’s no success criterion telling you not to use deprecated features, and you can still pass all of the success criteria for the guideline which states “ensure that information and structure can be separated from presentation.” And this is a step forward?

I found this in this article http://accessites.org/site/2006/06/the-wcag-20-what-a-whopper/

Beska
  • 12,445
  • 14
  • 77
  • 112
Jitendra Vyas
  • 148,487
  • 229
  • 573
  • 852
  • 8
    Over 400 questions, and you boast an interest in "XHTML, CSS, W3C Standards, and Accessibility." I would expect a different grade of questions by now :) – Sampson Feb 10 '10 at 13:56
  • 1
    Jonathan Sampson: It's possible he's trying to explain to a client why they're wrong and he doesn't have a good enough understanding to explain? :-) Maybe... – sam Feb 10 '10 at 13:58
  • @citricsquid - u r absolutely right – Jitendra Vyas Feb 10 '10 at 13:59
  • 1
    @Jitendra: If the definition of "deprecated" eludes you, you should probably not advertise a focus in "XHTML, CSS, W3C Standards and Accessibility." With all due respect, I'm not being rude, just looking out for you. – Sampson Feb 10 '10 at 14:01
  • Out of curiousity, what elements are being produced that are deprecated? – T.J. Crowder Feb 10 '10 at 14:02
  • 3
    You've really had ~178 different questions that never got answered satisfactorily? – T.J. Crowder Feb 10 '10 at 14:04
  • @Jonathan Sampson - I changed my profile, you are right I'm not expert yet – Jitendra Vyas Feb 10 '10 at 14:06
  • @ T.J. Crowder - yes, but i need to revise ,rewrote some questions to get good answers – Jitendra Vyas Feb 10 '10 at 14:29
  • 1
    *"yes, but i need to revise ,rewrote some questions to get good answers"* Ah, I understand. Thanks. – T.J. Crowder Feb 10 '10 at 14:30

4 Answers4

10

Future browsers may not support them, and you should always follow spec. If you make a habit of deviating with trivial HTML, your future as a professional programmer will be dim.

If you're using an editor that still uses deprecated elements, you should replace them. Fortunately, this can be as simple as a find/replace command.

spender
  • 117,338
  • 33
  • 229
  • 351
Sampson
  • 265,109
  • 74
  • 539
  • 565
  • 5
    +1 for "your future as a professional programmer will be dim" – Vincent Ramdhanie Feb 10 '10 at 13:55
  • 2
    @ijw: Yeah, but would *you* hire them? ;-) – T.J. Crowder Feb 10 '10 at 14:01
  • I'm not talking about application I'm talking about web based editor like RAD Editor etc – Jitendra Vyas Feb 10 '10 at 14:12
  • "Future browsers may not support them" can u pls give me any link where it is stated. – Jitendra Vyas Feb 10 '10 at 14:44
  • "deprecation does not mean the older version of the specification won't be supported. Each specification has a version number. The lists of deprecated elements and attributes from the previous posts refer to what has been deprecated from HTML3.2 to HTML4.0. Your code will still work fine in all browsers that support HTML3.2." http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/HTML/Q_21732157.html – Jitendra Vyas Feb 10 '10 at 15:36
  • Deprecated features may become obsolete in future versions of HTML, though browsers that support the features will likely continue to support them. http://htmlhelp.com/reference/html40/deprecated.html Both statement indicate support of browser will remain – Jitendra Vyas Feb 10 '10 at 15:38
  • It's seems fair to say that something deprecated will be removed at some point, first from the specification and later from things implementing that specification. Otherwise there is no point in calling it deprecated. – phkahler Feb 10 '10 at 16:44
5

There is normally a reason for deprecating things, and more often than not, another way of doing the same thing that isn't deprecated.

James
  • 9,774
  • 5
  • 34
  • 58
3

The cons ?

well... they are deprecated ..

Gabriele Petrioli
  • 191,379
  • 34
  • 261
  • 317
3

First, deprecated elements are usually not the best elements to use. They are generally deprecated for a reason, as there are better ways to do it.

Second, they could go away in future browsers. (Whether they will is a complicated question.)

For these reasons, you should always avoid deprecated functionality. It isn't a matter of avoiding it at all costs, since deprecated functionality is almost never the best way of doing something.

Whether it's worth changing an existing product is another question. Most web sites will need revision for other reasons later on, and that can include removing deprecated elements. Many will be removed from the web (for various reasons) long before any browser that doesn't support them gains popularity.

However, you're talking about a tool, and that's different. A tool should be more strict than an end product, since it affects not only today's work but work extending into the indefinite future, thereby raising the chances for problems. I'd say that the tool needs to be changed.

David Thornley
  • 56,304
  • 9
  • 91
  • 158