cformsII Support Forum
Current User: Guest *Frequently Asked Questions*
Search 
Search Forums:


 




field and label display order

Add a New Topic Reply to Post
Post

zink - Guest

8:16 pm - April 5, 2008

Please replace the ??? with your data!

  • Your URL: http://???
  • The browser used: Firefox
  • cforms version: 8.02
  • Your Wordpress version: 2.5

Hello. I'd like to adjust the layout a little bit for how the forms are displayed. I've been able to successfully style the forms as far as colors, sizes, and alignment, but I can't seem to figure out how to change the order in which the fields and their labels are displayed.

Currently, I've styled the forms to display the label, field and any reqtxt all on one line through floats. It looks great. But, by default the forms are displayed in the following order: Label | Field | reqtxt (if applicable). I'd like to adust the forms so that they display as: Field | Label | reqtxt.

It seems like this would be a simple task, but after delving into the *.php file and discovering its complexitiy, I didn't want to risk breaking anything. I definitely appreciate your help in explaining what I need to do to achieve the desired result. Maybe I missed something in the admin panel and don't need to alter the PHP?

Also, there's one more thing I was wondering. Is there a way to display a field sans its label? For example, I'd like to remove the label from the 'message' form so only the field for that form is displayed. I tried deleting the label name in the admin panel, but that didn't seem to change anything.

I appreciate your help with my query
Many thanks in advance.

Kind Regards.
BJ

Oliver - Admin

9:46 pm - April 5, 2008

posts 3562

But, by default the forms are displayed in the following order: Label | Field | reqtxt (if applicable). I'd like to adust the forms so that they display as: Field | Label | reqtxt.

Correct, and it is the only way cforms currently renders the form. You can use CSS to pretty much control the complete look&feel, of course with certain limitations. Swaping HTML elements (label vs. input field) can not be done.

Also, there's one more thing I was wondering. Is there a way to display a field sans its label?

Simply turn on label IDs in the CSS admin section and then use CSS to set display:none; for a given label element. Do keep the label name, otherwise you "loose" the label in the emails & DB tracknig as well!

Add a New Topic Reply to Post


Reply to Topic: field and label display order
PLEASE READ THE FAQs FIRST! THANK YOU.

NOTE: New Posts are subject to administrator approval before being displayed

Guest Name (Required):

Guest EMail (Required):

Guest URL (required)

Math Required!
What is the sum of: 10 + 3        (Required)

Topic Reply:


 
© Simple:Press Forum - Version 3.1.3 (Build 356)