mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 14:05:37 +02:00
Merge pull request #7596 from andrewandante/pulls/sanitise_select_tag_3
sanitise select tag in DropdownField Docblock
This commit is contained in:
commit
abe0e96192
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/**
|
||||
* Dropdown field, created from a <select> tag.
|
||||
* Dropdown field, created from a select tag.
|
||||
*
|
||||
* <b>Setting a $has_one relation</b>
|
||||
*
|
||||
|
@ -513,7 +513,7 @@ class FormField extends RequestHandler {
|
||||
}
|
||||
|
||||
/**
|
||||
* Set an HTML attribute on the field element, mostly an <input> tag.
|
||||
* Set an HTML attribute on the field element, mostly an input tag.
|
||||
*
|
||||
* Some attributes are best set through more specialized methods, to avoid interfering with
|
||||
* built-in behaviour:
|
||||
@ -1103,7 +1103,7 @@ class FormField extends RequestHandler {
|
||||
*
|
||||
* The field type is the class name with the word Field dropped off the end, all lowercase.
|
||||
*
|
||||
* It's handy for assigning HTML classes. Doesn't signify the <input type> attribute.
|
||||
* It's handy for assigning HTML classes. Doesn't signify the input type attribute.
|
||||
*
|
||||
* @see {link getAttributes()}.
|
||||
*
|
||||
@ -1145,7 +1145,7 @@ class FormField extends RequestHandler {
|
||||
/**
|
||||
* Describe this field, provide help text for it.
|
||||
*
|
||||
* By default, renders as a <span class="description"> underneath the form field.
|
||||
* By default, renders as a span class="description" underneath the form field.
|
||||
*
|
||||
* @param string $description
|
||||
*
|
||||
|
@ -1,13 +1,13 @@
|
||||
<?php
|
||||
/**
|
||||
* Grouped dropdown, using <optgroup> tags.
|
||||
* Grouped dropdown, using optgroup tags.
|
||||
*
|
||||
* $source parameter (from DropdownField) must be a two dimensional array.
|
||||
* The first level of the array is used for the <optgroup>, and the second
|
||||
* level are the <options> for each group.
|
||||
* The first level of the array is used for the optgroup, and the second
|
||||
* level are the options for each group.
|
||||
*
|
||||
* Returns a <select> tag containing all the appropriate <option> tags, with
|
||||
* <optgroup> tags around the <option> tags as required.
|
||||
* Returns a select tag containing all the appropriate option tags, with
|
||||
* optgroup tags around the option tags as required.
|
||||
*
|
||||
* <b>Usage</b>
|
||||
*
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?php
|
||||
/**
|
||||
* Multi-line listbox field, created from a <select> tag.
|
||||
* Multi-line listbox field, created from a select tag.
|
||||
*
|
||||
* <b>Usage</b>
|
||||
*
|
||||
@ -17,7 +17,7 @@
|
||||
* )
|
||||
* </code>
|
||||
*
|
||||
* @see DropdownField for a simple <select> field with a single element.
|
||||
* @see DropdownField for a simple select field with a single element.
|
||||
* @see CheckboxSetField for multiple selections through checkboxes.
|
||||
* @see OptionsetField for single selections via radiobuttons.
|
||||
* @see TreeDropdownField for a rich and customizeable UI that can visualize a tree of selectable elements
|
||||
@ -69,7 +69,7 @@ class ListboxField extends DropdownField {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a <select> tag containing all the appropriate <option> tags
|
||||
* Returns a select tag containing all the appropriate option tags
|
||||
*/
|
||||
public function Field($properties = array()) {
|
||||
if($this->multiple) $this->name .= '[]';
|
||||
|
Loading…
Reference in New Issue
Block a user