Overriding of Profile2 form template not working
I am attempting to generate template files for user login, user register,
and now the edit profile pages on my site. The user login and user
register templates are working effectively. However, the edit profile
template doesn't seem to work. I am utilizing the Profile2 module, and the
form I'd like to theme is located at profile-main/#/edit.
function project_near_theme() {
$items = array();
// create custom user-login.tpl.php
$items['user_login'] = array(
'render element' => 'form',
'path' => drupal_get_path('theme', 'project_near') . '/templates',
'template' => 'user-login',
'preprocess functions' => array(
'project_near_preprocess_user_login'
),
);
// create custom user-register.tpl.php
$items['user_register_form'] = array(
'render element' => 'form',
'path' => drupal_get_path('theme','project_near') . '/templates',
'template' => 'user-register',
'preprocess functions' => array(
'project_near_preprocess_user_register_form'
),
);
// create custom user-profile-form.tpl.php
$items['user_profile_form'] = array(
'render element' => 'form',
'path' => drupal_get_path('theme','project_near') . '/templates',
'template' => 'user-profile-form',
'preprocess functions' => array(
'project_near_preprocess_user_profile_form'
),
);
return $items;
}
No comments:
Post a Comment