Forum Moderators: open

Message Too Old, No Replies

<table><form></form></table> + XHTML

any way to make this validate?

         

phph

4:01 pm on Jul 16, 2006 (gmt 0)

10+ Year Member



I tried using fieldset, but it won't validate. Should I assume that the only way around is dropping the table and using CSS (this is not a solution in my case). Also, putting the table tags inside the form is not a solution, since it adds unwanted whitespace.

Any advice is greatly appreciated!

Birdman

4:11 pm on Jul 16, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



The simplest solution is to drop XHTML and use HTML 4 Doctype.

See also: Why most of us shouldn't use xhtml [webmasterworld.com]

kiwibrit

4:20 pm on Jul 16, 2006 (gmt 0)

10+ Year Member



In 4.01 strict, <form><table></table></form> validates, of course. I am not sure what you mean by unwanted white space.

That said, I don't like using a table for this purpose.

Robin_reala

8:48 pm on Jul 16, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



HTML:
<form><table></table></form>

CSS:

form, form table { margin: 0; padding: 0; }

That help?

[edited by: Robin_reala at 8:49 pm (utc) on July 16, 2006]

encyclo

2:02 am on Jul 17, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Making the form display inline can help with the white space problems too:

form {display:inline;}

Then place the

form
element outside the table.

phph

1:05 pm on Jul 17, 2006 (gmt 0)

10+ Year Member



Long live display:inline!

Thanks everyone, that worked perfectly!