Strict xhtml and different tags

Rewriting html into xhtml, I see after validating different errors, I cannot solve:

<a href="" target="_blank" title="">

Often within the <a href> tag you want to include extra information as above.

Now I see; there is no attribute ‘target’ and also there is no attibute ‘title’, although we are using it to open a new window and to do little SEO.

<td align="center" width="230">
<table width="730" border="0" padding="5" cellspacing="0">

No attibute width and also no padding?

Thanks for the help

The title attribute should still be allowed.

Back in the middle ages it was decided to get rid of the target attribute and allow your visitors to choose for themselves whether they want a link to open in a new window, a new tab, or in place of the current page. Attempting to use target reduces accessibility by denying them one of those choices unless they are using a browser that discards such garbage.

Using JavaScript to add code to the page that is invalid just means you are fooling yourself since the html is invalid regardless of whether the code is there at the start or added using JavaScript - so scripts to add a target attribute are only useful for those people who don’t care that it is invalid but want to hide that it is invalid from the validator. Of course the alternative is to use in JavaScript to request to open a new window which then lets your visitors still make the choice of where the page opens but with the default being a new window instead of over the current page (of course they can still override their default settings to have it open in a new tag or over the current page if that’s what they want).

Basically the rule is:

HTMNL defines what your content is.
CSS defines how the page should look/sound (eg. widths, padding, male or female voice etc).
JavaScript defines how the page interacts.

Width and padding should be declared in your CSS. For the target _blank you can use the rel attribute and a bit of javascript

Sitepoint Article

As Felgall says, you can still use the title attribute if it’s appropriate.

The target attribute is banned in Strict (X)HTML, and generally it’s a bad idea to use it. Forcing people to open a link in a new window, whether they want to or not, is unhelpful and often irritating, if not worse. You have to have a very good reason to force links to open in a new window, and “I want people to have my website still open in the background so they can come back to it” is not a good reason.

<td align="center" width="230">
<table width="730" border="0" padding="5" cellspacing="0">

No attibute width and also no padding?

All those features should be dealt with in a stylesheet. All aspects of formatting should be in CSS, not in HTML.