Advanced Form Framework with PHP lets you generate forms inside a table using classes and methods. It supports CSS, so changing the style is a snap.