types
types
A constant list of the known block types.
A class to describe a single content block for use in page templates.
Instances of this class are immutable.
Acceptable Attributes by block type:
textinput
date
number
textarea
statictext
dropdown
dropdown_udt
gcb_selector
multiselect
sortable_list
checkbox
radiobuttons
file_selector
advpageselector
with_name(string $name) : \CGContentUtils\ContentBlock
Set a name into a content block.
There is no validation to the content of the string provided.
| string | $name | the new content blockn name. |
The new content block.
with_type(string $type) : \CGContentUtils\ContentBlock
Set the type of a content block.
| string | $type | A valid type name |
the new content block
with_prompt(string $prompt) : \CGContentUtils\ContentBlock
Set the prompt for a content block
| string | $prompt | A non empty prompts. |
the new content block
with_value(string $value) : \CGContentUtils\ContentBlock
Set the defalt value for a content block
| string | $value |
the new content block
with_attrib(string $key, mixed $val) : \CGContentUtils\ContentBlock
Set a content block attribute
| string | $key | The atrribute key |
| mixed | $val | A value for the attribute. If the value is null, then the attribute is unset. Otherwise it is copied without validation. |