CMPHP/form/form_editbox.php

24 lines
608 B
PHP
Raw Normal View History

2016-08-21 23:06:17 +04:00
<?php
2016-09-01 03:26:27 +04:00
function CreateInputGroup()
2016-08-21 23:06:17 +04:00
{
2016-09-01 03:26:27 +04:00
$type =func_get_arg(0);
$id =func_get_arg(1);
$label =func_get_arg(2);
$size =func_get_arg(3);
echo '<div class="form-group">
<label class="control-label col-sm-2">'.$label.'</label>
<div class="col-sm-10">
<input type="'.$type.'" class="form-control" id="'.$type.'" size="'.$size.'">';
if(func_num_args()==5)
{
$right_label=func_get_arg(4);
echo '<span class="help-block">'.$right_label.'</span>';
2016-09-01 03:26:27 +04:00
}
echo '</div></div>';
2016-08-21 23:06:17 +04:00
}
?>