: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
* This template can be overridden by copying it to your child_theme_folder/themify-builder/template-login.php.
* Access original fields: $args['mod_settings']
defined( 'ABSPATH' ) || exit;
$mod_name=$args['mod_name'];
$element_id = $args['module_ID'];
$fields_args = $args['mod_settings']+ array(
'remember_me_display' => 'show',
'redirect_to' => add_query_arg( 'login_success', 1 ),
'icon_forgotten_password' => '',
'label_forgotten_password' => '',
'lostpasswordform_redirect_to' => '',
'lostpasswordform_icon_username' => '',
'lostpasswordform_icon_reset' => '',
'lostpasswordform_label_username' => '',
'lostpasswordform_label_reset' => '',
$fields_args['alignment']=$fields_args['alignment']==='' || 'left'=== $fields_args['alignment']?'':('center'=== $fields_args['alignment']?'tb_login_c':'tf_right');
$container_class = apply_filters( 'themify_builder_module_classes', array(
), $mod_name, $element_id, $fields_args );
if(!empty($fields_args['global_styles']) && Themify_Builder::$frontedit_active===false){
$container_class[] = $fields_args['global_styles'];
$container_props = apply_filters( 'themify_builder_module_container_props', self::parse_animation_effect($fields_args,array(
'class' => implode( ' ', $container_class),
)), $fields_args, $mod_name, $element_id );
if(Themify_Builder::$frontedit_active===false){
$container_props['data-lazy']=1;
self::sticky_element_props($container_props, $fields_args);
<div <?php echo themify_get_element_attributes($container_props); ?>>
<div class="tb_login_wrap <?php echo $fields_args['alignment'];?>">
<?php $container_props=$container_class=$args=null;
echo Themify_Builder_Component_Module::get_module_title($fields_args);
<?php if ( is_user_logged_in() && ! Themify_Builder_Model::is_front_builder_activate() ) :
$fields_args['content_text'] = str_replace(
[ '%username%', '%display_name%', '%first_name%', '%last_name%', '%email%' ],
[ $current_user->user_login, $current_user->display_name, $current_user->user_firstname, $current_user->user_lastname, $current_user->user_email ],
$fields_args['content_text']
echo apply_filters( 'themify_builder_module_content', $fields_args['content_text'] );
if ( $fields_args['logout_link'] === 'show' ) {
echo ' <a href="' . wp_logout_url( $fields_args['logout_redirect'] ) . '">' . __( 'Logout', 'themify' ) . '</a>';
<?php if ( $fields_args['fail_action'] === 'm' && isset( $_GET['login_error'] ) ) : ?>
<div class="tb_login_error"><?php echo esc_html( $fields_args['msg_fail'] ) ?></div>
<form class="tb_login_form tf_clearfix tf_box tf_clear" name="loginform" action="<?php echo esc_url( site_url( 'wp-login.php', 'login_post' ) ) ?>" method="post">
<p class="tb_login_username">
<?php if ( $fields_args['icon_username'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['icon_username'] ); ?></em><?php endif; ?>
<span class="tb_login_username_text"><?php echo esc_html( $fields_args['label_username'] ) ?></span>
<input type="text" name="log" required="required">
<p class="tb_login_password">
<?php if ( $fields_args['icon_password'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['icon_password'] ); ?></em><?php endif; ?>
<span class="tb_login_password_text"><?php echo esc_html( $fields_args['label_password'] ) ?></span>
<input type="password" name="pwd" required="required" autocomplete="current-password">
<div class="tb_login_links tf_box tf_clear">
<?php if ( $fields_args['icon_forgotten_password'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['icon_forgotten_password'] ); ?></em><?php endif; ?>
<a href="<?php echo esc_url( network_site_url( 'wp-login.php?action=lostpassword', 'login_post' ) ); ?>"><?php echo esc_html( $fields_args['label_forgotten_password'] ); ?></a>
/** This action is documented in wp-login.php */
do_action( 'login_form' );
<?php if ( $fields_args['remember_me_display'] === 'show' ) : ?>
<p class="tb_login_remember tf_left tf_box">
<input name="rememberme" type="checkbox" value="forever">
<?php if ( $fields_args['icon_remember'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['icon_remember'] ); ?></em><?php endif; ?>
<span class="tb_login_remember_text"><?php echo esc_html( $fields_args['label_remember'] ); ?></span>
<p class="tb_login_submit tf_right">
<button name="wp-submit">
<?php if ( $fields_args['icon_log_in'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['icon_log_in'] ); ?></em><?php endif; ?>
<?php echo esc_html( $fields_args['label_log_in'] ) ?>
<input type="hidden" name="redirect_to" value="<?php echo esc_url( $fields_args['redirect_to'] ) ?>">
<input type="hidden" name="tb_login" value="1">
<?php if ( $fields_args['fail_action'] === 'c' && ! empty( $fields_args['redirect_fail'] ) ) : ?>
<input type="hidden" name="tb_redirect_fail" value="<?php echo esc_url( $fields_args['redirect_fail'] ) ?>">
<?php elseif ( $fields_args['fail_action'] === 'm' ) : ?>
<input type="hidden" name="tb_redirect_fail" value="<?php echo esc_url( add_query_arg( 'login_error', 1 ) ) ?>">
<form class="tb_lostpassword_form tf_clearfix tf_box tf_clear" name="lostpasswordform" action="<?php echo esc_url( network_site_url( 'wp-login.php?action=lostpassword', 'login_post' ) ); ?>" method="post" style="display:none">
<p class="tb_lostpassword_username">
<?php if ( $fields_args['lostpasswordform_icon_username'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['lostpasswordform_icon_username'] ); ?></em><?php endif; ?>
<span class="tb_lostpassword_username_text"><?php echo esc_html( $fields_args['lostpasswordform_label_username'] ) ?></span>
<input type="text" name="user_login" required="required">
/** This action is documented in wp-login.php */
do_action( 'lostpassword_form' );
<?php if ( ! empty( $fields_args['lostpasswordform_redirect_to'] ) ) : ?>
<input type="hidden" name="redirect_to" value="<?php echo esc_attr( $fields_args['lostpasswordform_redirect_to'] ); ?>">
<p class="tb_lostpassword_submit tf_right">
<button><?php if ( $fields_args['lostpasswordform_icon_reset'] !== '' ) : ?><em><?php echo themify_get_icon( $fields_args['lostpasswordform_icon_reset'] ); ?></em><?php endif; ?> <?php echo esc_html( $fields_args['lostpasswordform_label_reset'] ) ?></button>
<div class="tb_login_links tf_left tf_box">
<a href="<?php echo esc_url( site_url( 'wp-login.php' ) ); ?>"><?php echo esc_html( $fields_args['label_log_in'] ); ?></a>
</div><!-- /module login -->