From 928c55cbc5f3f162c10077f46d75d0bc0b1cbe53 Mon Sep 17 00:00:00 2001
From: Derek Allard Similar to other functions, you can submit an associative array in the second parameter if you prefer to set additional attributes. Produces a closing </fieldset> tag. The only advantage to using this function is it permits you to pass data to it
- which will be added below the tag. For example:$attributes = array('id' => 'address_info', 'class' => 'address_info');
- echo form_fieldset('Address Information', $attributes);
+ echo form_fieldset('Address Information', $attributes);
echo "<p>fieldset content here</p>\n";
echo form_fieldset_close();
@@ -269,7 +269,7 @@ echo form_fieldset_close();
</fieldset>form_fieldset_close()
$string = "</div></div>";
echo fieldset_close($string);
@@ -321,7 +321,7 @@ fourth parameter:
<input type="submit" name="mysubmit" value="Submit Post!" />
Similar to other functions, you can submit an associative array in the first parameter if you prefer to set your own attributes. - The third parameter lets you add extra data to your form, like JavaScript.
+ The third parameter lets you add extra data to your form, like JavaScript.Lets you generate a <label>. Simple example:
echo form_label('What is your Name', 'username');
@@ -329,13 +329,13 @@ fourth parameter:
// Would produce:
<label for="username">What is your Name</label>
-Similar to other functions, you can submit an associative array in the third parameter if you prefer to set additional attributes.
+Similar to other functions, you can submit an associative array in the third parameter if you prefer to set additional attributes.
$attributes = array(
'class' => 'mycustomclass',
'style' => 'color: #000;',
);
- echo form_label('What is your Name', 'username', $attributes);
-
+ echo form_label('What is your Name', 'username', $attributes);
+
// Would produce:
<label for="username" class="mycustomclass" style="color: #000;">What is your Name</label>