Change protect element header and add fields

Support,

Is it possible to change the protect element header and add additional text with links, a link to recover password and a link to my register page?

Page where protect is located: motorfieds.com/post-a-motorcycle

New header: Login To Post A Motorcycle (or some variance)

Links I wish to add with text:
motorfieds.com/lost-password
motorfieds.com/register/

Thanks,
Chuck

Hi Chuck,

Unfortunately, the protect element just accept simple text and what you want to achieve is possible with customization that is outside the scope of our support. This is something we can add to our list of feature requests. This way it can be taken into consideration for future development. All of these items are discussed with our team internally and prioritized based on the amount of interest a particular feature might receive. Thanks!

Where can I locate the .php file that controls this element?

or how can I just remove the header through CSS?

Hello There,

Thanks for updating in! If you want to customize the protect element, assuming that the child theme is set up, please add the following code in your child theme’s functions.php file

//
// Custom Content Protect
// =============================================================================

function custom_shortcode_protect( $atts, $content = null ) {
  extract( shortcode_atts( array(
    'id'    => '',
    'class' => '',
    'style' => ''
  ), $atts, 'x_protect' ) );

  GLOBAL $user_login;

  $id    = ( $id    != '' ) ? 'id="' . esc_attr( $id ) . '"' : '';
  $class = ( $class != '' ) ? 'x-protect ' . esc_attr( $class ) : 'x-protect';
  $style = ( $style != '' ) ? 'style="' . $style . '"' : '';

  if ( is_user_logged_in() ) {
    $output = do_shortcode( $content );
  } else {
    $output = "<div {$id} class=\"{$class}\" {$style}>"
              . '<form action="' . esc_url( site_url( 'wp-login.php' ) ) . '" method="post" class="mbn">'
                . '<h6 class="h-protect man">' . esc_html__( 'Restricted Content Login', 'cornerstone' ) . '</h6>'
                . '<div><label>' . esc_html__( 'Username', 'cornerstone' ) . '</label><input type="text" name="log" id="log" value="' . esc_attr( $user_login ) . '" /></div>'
                . '<div><label>' . esc_html__( 'Password', 'cornerstone' ) . '</label><input type="password" name="pwd" id="pwd" /></div>'
                . '<div><input type="submit" name="submit" value="' . esc_html__( 'Login', 'cornerstone' ) . '" class="x-btn x-btn-protect" /></div>'
                . '<input type="hidden" name="redirect_to" value="' . esc_url( get_permalink() ) . '">'
                . '<p><a href="<?php echo wp_registration_url(); ?>">Register</a> | '
                . '<a href="' . wp_lostpassword_url( get_permalink() ) . '" title="Password Recovery">Lost your password?</a></p>'
              . '</form>'
            . '</div>';
  }

  return $output;
}

function update_content_protect() {
  remove_shortcode( 'x_protect' );
  add_shortcode( 'x_protect', 'custom_shortcode_protect' );
}
add_action('wp', 'update_content_protect');
// =============================================================================

Please be very careful when modifying the code above. Any invalid character or code you add will result to a fatal error.

Please let us know how it goes.