Scripsit Matthew Wilson:
> I need to style a link to be identical to a button.
Stop needing that. You don't need to mislead people into confusing
buttons with links.
> This is what I
> came up with. I want to know about downside risks:
>
> <a href="/blah"><input type="button" value="Visit blah" /></a>
>
> As far as I can tell, this works perfectly.
How many browsers did you test it on? The construct is illogical, since
both links and input buttons can be activated, so what happens when you
click on something that is both a link and an input button? Does it
invoke the inner element's functionality, or the outer element's, or
both elements'? Did you already check it on IE 9 and Firefox 4?
> It seems to be valid HTML.
It is valid (even in HTML 4.01, though with a meaning different from
XHTML), but this does not imply that some meaning or specific
functionality has been assigned to it.
--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/