Please excuse if this is the wrong forum for this, but i'm not sure where else.
I have a new module that lets users track company info. But i want to make the admin edit form look more distinct than the generic drupal form. For example, i'd like to put it all in a table and have the labels in the left cell and the form fields in the right.
The form_textfield function rocks (thanks!) but would it be smart of me to think of trying to add another parameter for having the form label to the left rather than above the form?
If there's a way to do this in a theme (i checked xtemplate.engine and xtemplate.inc, but didn't find anything illuminating) please let me know.
Thanks! I'm itching to chip in some code (still new at this) but want to do it right.
Cheers,
mark
Comments
theme_form_element()
Your theme can overwrite the theme_form_element() function to style form items/elements.
CSS
Presentation is definitely something to do at the theme layer, not in code.
You can do this with CSS:
.form-item br { display: none; }
Though the form controls won't line up. For that, you can use something like this:
.form-item br { display: none; }
.form-item label { float: left; clear: left; width: 150px; }
.form-item label.option { float: none; }
Though I only tried it in Firefox with Webdeveloper, might not work on IE.