This repository was archived by the owner on Dec 2, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
AIIXForm HTML Attributes
ailixter edited this page Mar 5, 2016
·
8 revisions
[elem]<input type="text" id="elem" name="elem"/>[Not valid html's ident]
id = "count"<input type="text" id="count" name="count"/>[elem]
name = "count"<input type="text" id="elem" name="count"/>[test1]
[test2]
-suffix = 'product/id'// get salar input
$attrs = \AIIX\Form::attrs('test1');
echo \AIIX\Form::input($attrs);
// get array input
$attrs_with_suffix = \AIIX\Form::attrs(array('test1', 'product', 'id'));
echo \AIIX\Form::input($attrs_with_suffix);<input id="test1" name="test1"/>
<input id="test1_product_id" name="test1[product][id]"/>$attrs: array (
'-suffix' => '',
'id' => 'test1',
'name' => 'test1',
'-path' => 'test1',
);
$attrs_with_suffix: array (
'-suffix' => 'product/id',
'id' => 'test1',
'name' => 'test1',
'-path' => 'test1/product/id',
);
[preset]
-control = text
value = "Change me!"<input type="text" name="preset" value="Change me!"/>[preset]
-control = textarea
value = "Change me!"<textarea name="preset">Change me!</textarea>[preset]
-control = select
-options[One] = Apples
-options[Two] = Oranges
value = Two; selects OrangesTODO