Bootstrap Datetimepicker Min Css Example
Bootstrap Datetimepicker Min Css Example
Butenko
Version: 4.1-master
https://github.com/avbdr/php-bootstrap-form
1) Button
Form::Button("label", "type", array(properties));
✔ attributes
type: default=submit, (submit, button, reset)
properties
• required
• class
• value: text
• ...
Example:
Form::Button("Login", "button", array("autofocus" => "","icon"=>"fa fa-sign-in ","value"=>"Login"));
Form::Button("Ok", "submit", array("name" => "approve", "disabled" => "disabled","formtarget"=>"_blank"));
Form::Button("Cancel", "button", array("onclick" => "history.go(-1);"));
2) CKEditor
3) Captcha
4) Checkbox
Form::Checkbox("label", "name|id", array(values), array(attributes));
attributes
• inline
• value
• required
• ...
Example:
Form::Checkbox("Level", "ProfLevels", array(0 => "Exc", 1 => "med"), array("value" => "med"));
Form::Checkbox("Level", "ProfLevels", array("poor", "med"), array("inline" => 1, "value" => "poor"));
Form::Checkbox("", "remember", array("1" => "Remember me"));
5) Checksort
6) Color
7) Country
8) Date
Form::Date("label", "name|id", array(properties));
properties
• required
• title
• placeholder
• ...
Example:
Form::Date();
Form::Date("Date", "date");
Form::Date("Age", date('Y-m-d'), array("title" => "input date", "required" => 1));
9) DateTime
10) DateTimeLocal
12) FaCalendar
Form::FaCalendar("label", "name|id", array(properties));
Dependencies:
shares/UI/css/bootstrap-datepicker.min.css
shares/UI/js/bootstrap-datepicker.min.js
shares/UI/js/bootstrap-datepicker.fa.min.js
properties
• required
Example:
Form::FaCalendar(""تاریخ, "FaDate", array("required" => 1));
14) HTML
Form::HTML(‘values’);
Example:
Form::HTML('<h4>PFBC/PHP Form Builder Class</h4>');
15) Hidden
Form::Hidden("name", "value", array(properties));
Example:
Form::Hidden("id", "12", array("required" => 1));
16) Month
19) Phone
20) Radio
Form::Radio("label", "name|id", array(values), array(attributes));
attributes
• inline
• value
• required
• ...
Example:
Form::Radio("Level", "LVL", array('1' => "poor", '2' => "med"), array("inline" => 1, "value" => '1', "required" => 1));
21) Range
22) Search
25) Sort
26) SpanStart
27) State
28) Textarea
Form::Textarea("label", "name", array(attributes));
attributes
• rows
• required
• ...
Example:
Form::Textarea("Description", "desc",
array('required' => 1, 'rows' => 2, 'maxlength' => '100', 'placeholder' => 'Inset your description:', ‘style’ => "resize: vertical"));
29) Textbox
Form::Textbox("label", "name", array(attributes));
attributes
• value
• required
• multiple
...
Example:
Form::Textbox("Name", "name",
array('required' => 1, 'maxlength' => '30', 'placeholder' => 'Inset your text:', 'pattern' => '[A-Za-z]{30}'));
30) Time
31) TinyMCE
32) Url
33) Week
Example:
Form::YesNo("Level", "LVL", array("inline" => 1, "value" => 'Yes', "required" => 1));
35) jQueryUIDate
- Form::open
Form::open($formId, $values = null, $opts = null)
$opts
• ajax
• action
• view
• enctype
• ...
Examples:
Form::open ("levelForm", array('id' => '12'),
array ('ajax' => 'finishCallback', 'view' => 'Inline|Vertical|SideBySide4','enctype' => 'multipart/form-data'));
<script>
function finishCallback (data) {
alert('approved');
}
</script>
- Form::close
Form::close could be one of the following types: Form::$SUBMIT, false.
Examples:
Form::close (false); Just close a form. No need to generate extra buttons
Form::close( Form::$SUBMIT ); Add submit and Cancel button. Close a form after that
Form::close (); Display: Remove and Submit buttons as Defaults
Form::close(99); Display: Submit button