我认为您的网站工作正常,因为:
我看到你看到的了,没有办法预订房间。要访问预订功能,您必须在http://www.mayanhills.com/registro-de-nuevo-usuario/, 有一扇像这样的窗户.然后登录。然后你回到预定地点。。。现在你可以开始了:我认为它工作得很好,现在如果你想更改它,或者至少发送到注册表,你应该用PHP修改如下内容。
<?php if ( is_user_logged_in() ) { ?>
<span class="mkdf-input-email">
<label><?php esc_html_e( \'Email:\', \'mkdf-hotel\' ) ?></label>
<input type="text" class="mkdf-res-email" name="user_email" placeholder="<?php esc_attr_e( \'Need to be logged in\', \'mkdf-hotel\' ) ?>" disabled value="<?php echo esc_attr($email) ?>" />
</span>
<?php } else { ?>
<a href="<?php echo esc_url( wp_login_url( get_permalink() ) ); ?>" class="mkdf-res-email" alt="<?php esc_attr_e( \'Login\', \'textdomain\' ); ?>"><?php _e( \'Login\', \'textdomain\' ); ?></a>
<?php } ?>
我希望这对你有帮助;D
UPDATE
用你发给我的代码,我做到了:
<div class="mkdf-hotel-room-reservation" data-room-id="<?php echo get_the_ID(); ?>">
<form id="mkdf-hotel-room-form" method="POST">
<?php wp_nonce_field(\'mkdf_hotel_room_booking_form\', \'mkdf_hotel_room_booking_form\'); ?>
<div class="mkdf-grid-row">
<!-- New code -->
<?php if ( is_user_logged_in() ) : // Verify if current user is logged in, if so; show the input with the email. ?>
<div class="mkdf-grid-col-12">
<span class="mkdf-input-email">
<label><?php esc_html_e( \'Email:\', \'mkdf-hotel\' ) ?></label>
<input type="text" class="mkdf-res-email" name="user_email" placeholder="<?php esc_attr_e( \'Need to be logged in\', \'mkdf-hotel\' ) ?>" disabled value="<?php echo esc_attr($email) ?>" />
</span>
</div>
<?php elseif: // In case the current user is not known, show the registration link. ?>
<style>
/* If possible, move these styles to the styles.css */
.mkdf-unkown-user{
width: 100%;
margin: 0;
padding: 12px 40px;
font-family: inherit;
font-size: 15px;
line-height: 30px;
font-weight: inherit;
color: #afafaf;
background-color: transparent;
border: 1px solid #555;
}
</style>
<div class="mkdf-grid-col-12">
<a href="<?php bloginfo(\'descriurlption\'); ?>/registro-de-nuevo-usuario/" class="mkdf-unkown-user" alt=""><?php _e( \'Login\', \'textdomain\' ); ?></a>
</div>
<?php endif; ?>
<!-- End new code -->