function input_wrap($name, $type, $label = '') { echo ''; if (!empty($label)) { echo ''; } echo ''; echo ''; }
input_wrap('first_name', 'text', 'First Name');This would output an input element with the name attribute of "first_name", the type attribute of "text", and a label element with the text "First Name". The entire input element would be wrapped in a div element with the class "form-group".