I need to add on condition to profile form submit handler profile2_form_submit_handler
A theme can not simply override a form handler. What you need is a form alter function (hook_form_FROM_ID_alter()) to alter the profile2 form, remove its original submit handler and replace it with your own.

THEMENAME_form_profile2_form_alter(&amp;$form, &amp;$form_state) {
  array_splice($form['#submit'], array_search('profile2_form_submit_handler', $form['#submit']), 1, 'THEMENAME_form_submit_handler');
}


Because your are changing the behavior of your site, this should be implemented in a custom module rather than in the theme. Themes are about presentation.

Also, instead of altering profiles on form submit, you could also implement hook_profile2_presave() to alter the profiles before they are saved to the database, regardless on how they are created (ie. your code will also work for profile created programmatically).