| 1 |
<?php |
| 2 |
/** |
| 3 |
* The template used to display the profile form. |
| 4 |
* |
| 5 |
* @author Studio 164a |
| 6 |
* @package Charitable/Templates/Account |
| 7 |
* @since 1.0.0 |
| 8 |
* @version 1.5.7 |
| 9 |
*/ |
| 10 |
|
| 11 |
// Exit if accessed directly. |
| 12 |
if ( ! defined( 'ABSPATH' ) ) { exit; } |
| 13 |
|
| 14 |
$form = $view_args['form']; |
| 15 |
$donor = charitable_get_user( wp_get_current_user() ); |
| 16 |
|
| 17 |
/** |
| 18 |
* Do something before rendering the user profile form. |
| 19 |
* |
| 20 |
* @param array $view_args All args passed to template. |
| 21 |
*/ |
| 22 |
do_action( 'charitable_user_profile_before', $view_args ); |
| 23 |
|
| 24 |
?> |
| 25 |
<form method="post" id="charitable-profile-form" class="charitable-form" enctype="multipart/form-data"> |
| 26 |
<?php |
| 27 |
/** |
| 28 |
* Do something before rendering the form fields. |
| 29 |
* |
| 30 |
* @since 1.0.0 |
| 31 |
* |
| 32 |
* @param Charitable_Form $form The form object. |
| 33 |
* @param array $view_args All args passed to template. |
| 34 |
*/ |
| 35 |
do_action( 'charitable_form_before_fields', $form, $view_args ); |
| 36 |
|
| 37 |
?> |
| 38 |
<div class="charitable-form-fields cf"> |
| 39 |
<?php $form->view()->render() ?> |
| 40 |
</div><!-- .charitable-form-fields --> |
| 41 |
<?php |
| 42 |
|
| 43 |
/** |
| 44 |
* Do something after rendering the form fields. |
| 45 |
* |
| 46 |
* @since 1.0.0 |
| 47 |
* |
| 48 |
* @param Charitable_Form $form The form object. |
| 49 |
* @param array $view_args All args passed to template. |
| 50 |
*/ |
| 51 |
do_action( 'charitable_form_after_fields', $form, $view_args ); |
| 52 |
|
| 53 |
?> |
| 54 |
<div class="charitable-form-field charitable-submit-field"> |
| 55 |
<button class="button button-primary" type="submit" name="update-profile"><?php echo apply_filters( 'charitable_profile_form_submit_button_name', __( 'Update', 'charitable' ) ); ?></button> |
| 56 |
</div> |
| 57 |
</form><!-- #charitable-profile-form --> |
| 58 |
<?php |
| 59 |
/** |
| 60 |
* Do something after rendering the user profile form. |
| 61 |
* |
| 62 |
* @param array $view_args All args passed to template. |
| 63 |
*/ |
| 64 |
do_action( 'charitable_user_profile_after', $view_args ); |
| 65 |
|