diff --git a/application/helpers/cms_helper.php b/application/helpers/cms_helper.php
index 7fea7f09..6202de7b 100755
--- a/application/helpers/cms_helper.php
+++ b/application/helpers/cms_helper.php
@@ -605,3 +605,50 @@ function parse_record($record, $config=array()){
$replace[] = $backend_urls;
return str_replace($search, $replace, $record_template);
}
+
+function create_labeled_form_input($id, $label, $input_html){
+ $input_html = str_replace('{{ id }}', $id, $input_html);
+ $html = '';
+ $html .= '
';
+ return $html;
+}
+
+function build_register_input($secret_code, $user_name, $email, $real_name){
+ $html = '';
+
+ $id = $secret_code.'user_name';
+ $input_html = form_input($id, $user_name,
+ 'id="{{ id }}" placeholder="User Name" class="form-control"');
+ $html .= create_labeled_form_input($id, '{{ language:User Name }}', $input_html);
+
+ $id = $secret_code.'real_name';
+ $input_html = form_input($id, $real_name,
+ 'id="{{ id }}" placeholder="Real Name" class="form-control"');
+ $html .= create_labeled_form_input($id, '{{ language:Real Name }}', $input_html);
+
+ $id = $secret_code.'email';
+ $input_html = form_input($id, $email,
+ 'id="{{ id }}" placeholder="Email" class="form-control"');
+ $html .= create_labeled_form_input($id, '{{ language:Email }}', $input_html);
+
+
+ $id = $secret_code.'password';
+ $input_html = form_password($id, '',
+ 'id="{{ id }}" placeholder="Password" class="form-control"');
+ $html .= create_labeled_form_input($id, '{{ language:Password }}', $input_html);
+
+ // spacer
+ $html .= '
';
+
+ $id = $secret_code.'confirm_password';
+ $input_html = form_password($id, '',
+ 'id="{{ id }}" placeholder="Password (again)" class="form-control"');
+ $html .= create_labeled_form_input($id, '{{ language:Confirm Password }}', $input_html);
+
+ return $html;
+}
diff --git a/modules/installer/models/Install_model.php b/modules/installer/models/Install_model.php
index a72ecdb2..d462dc99 100755
--- a/modules/installer/models/Install_model.php
+++ b/modules/installer/models/Install_model.php
@@ -1043,7 +1043,7 @@ protected function insert_all_data($config=NULL){
array('main_register', NULL, 'Register', 'Register', NULL, 'New User Registration', 'main/register',
2, 7, 1, 0, NULL, 0, NULL, NULL, 'default-one-column'),
array('main_change_profile', NULL, 'Change Profile', 'Change Profile', NULL, 'Change Current Profile', 'main/change_profile',
- 3, 8, 1, 0, NULL, 0),
+ 3, 8, 1, 0, NULL, 0, NULL, NULL, 'default-one-column'),
array('main_group_management', 4, 'Group Management', 'Group Management', NULL, 'Group Management', 'main/manage_group',
4, 0, 1, 0, NULL, 0, NULL, NULL, 'default-one-column'),
array('main_user_management', 4, 'User Management', 'User Management', NULL, 'Manage User', 'main/manage_user',
diff --git a/modules/main/views/main_change_profile.php b/modules/main/views/main_change_profile.php
index c58a9d41..591f47e4 100755
--- a/modules/main/views/main_change_profile.php
+++ b/modules/main/views/main_change_profile.php
@@ -6,9 +6,9 @@
echo $asset->compile_css();
?>
{{ language:Change Profile }}
';
- echo form_label('{{ language:Profile Picture }}', ' for="" class="control-label col-sm-4');
- echo '';
+ $input = '';
if(trim($profile_picture) != ''){
- echo '
';
+ $input .= '
';
}
- echo '
';
- echo '
';
- echo '';
+ $input .= '';
+ echo create_labeled_form_input('profile_picture', '{{ language:Profile Picture }}', $input);
- echo '';
+ echo create_labeled_form_input('user_name', '{{ language:User Name }}', $user_name);
- echo '';
+ echo create_labeled_form_input('email', '{{ language:Email }}', $input);
- echo '';
+ echo create_labeled_form_input('real_name', '{{ language:Real Name }}', $input);
- echo '';
+ echo create_labeled_form_input('birthdate', '{{ language:Birthdate }}', $input);
- echo '';
+ $input .= '';
+ echo create_labeled_form_input('sex', '{{ language:Sex }}', $input);
- echo '';
+ $input .= '';
+ echo create_labeled_form_input('language', '{{ language:Language }}', $input);
- echo '';
+ $input .= '';
+ echo create_labeled_form_input('theme', '{{ language:Theme }}', $input);
- echo '';
+ echo create_labeled_form_input('self_description', '{{ language:Self Description }}', $input);
echo $additional_input;
- echo '';
+ $input = form_checkbox('change_password','True',FALSE, 'id="change_password"');
+ $input .= form_label('{{ language:Change Password }}', 'change_password', 'class="control-label');
+ echo create_labeled_form_input('change_password', '', $input);
- echo '';
+ echo '