# charitable/1.8.0/templates/shortcodes/login.php

Charitable – Donation &amp; Fundraising Platform (Donation Forms, Recurring Donations &amp; Fundraising Campaigns), version 1.8.0. 52 lines.

- Page: https://pluginprobe.com/plugins/charitable/1.8.0/code/templates/shortcodes/login.php
- Raw: https://pluginprobe.com/plugins/charitable/1.8.0/raw/templates/shortcodes/login.php
- Modified: 2022-09-21T15:01:56+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/charitable/1.8.0/code/templates/shortcodes/login.php#L10-L20`.

```php
<?php
/**
 * The template used to display the login form. Provided here primarily as a way to make
 * it easier to override using theme templates.
 *
 * Override this template by copying it to yourtheme/charitable/shortcodes/login.php
 *
 * @author  David Bisset
 * @package Charitable/Templates/Account
 * @since   1.0.0
 * @version 1.5.7
 */

// Exit if accessed directly.
if ( ! defined( 'ABSPATH' ) ) {
	exit;
}

$login_form_args = array_key_exists( 'login_form_args', $view_args ) ? $view_args['login_form_args'] : array();

?>
<div class="charitable-login-form">
	<?php

	/**
	 * Do something before the login form.
	 *
	 * @param array $view_args All args passed to template.
	 */
	do_action( 'charitable_login_form_before', $view_args );

	wp_login_form( $login_form_args );

	?>
	<p>
		<?php if ( array_key_exists( 'registration_link', $view_args ) && $view_args['registration_link'] ) : ?>
			<a href="<?php echo esc_url( $view_args['registration_link'] ); ?>"><?php echo $view_args['registration_link_text']; ?></a>&nbsp;|&nbsp;
		<?php endif ?>
		<a href="<?php echo esc_url( charitable_get_permalink( 'forgot_password_page' ) ); ?>"><?php _e( 'Forgot Password', 'charitable' ); ?></a>
	</p>
	<?php

	/**
	 * Do something after showing the login form.
	 *
	 * @param array $view_args All args passed to template.
	 */
	do_action( 'charitable_login_form_after', $view_args )

	?>
</div>

```
