Ability to add arbitrary HTML

dllh - May 11, 2007 - 13:58
Project:Forms
Version:5.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:closed
Description

I had a need to include arbitrary html within a form (e.g. descriptive text or images that did not fit well shoehorned into a form description area). So I patched the module to add an "html" field type that adds whatever is entered in the explanation field to the form. Thought it might be useful to add to the module for others, so if you want it, here it is.

AttachmentSize
forms.module_3.patch908 bytes

#1

drupalegg - December 23, 2007 - 16:37

When I used this with Survey module, I made this to be:

case 'html':
$real_field = array(
'#type' => 'item',
'#value' => $field->explanation
);
break;

It works great!
Thank you!

#2

quicksketch - March 22, 2008 - 06:51
Status:needs review» closed

Forms and survey modules are no longer being maintained, use Webform module instead.

---Closing down issue queue of survey module---

 
 

Drupal is a registered trademark of Dries Buytaert.