File: /mnt/data/dreamsrent-wp/wp-content/themes/dreamsrent/template-dashboard-vendors.php
<?php
/**
* Template Name: Dashboard Vendors Page
*
* This is the template that displays all pages by default.
* Please note that this is the WordPress construct of pages
* and that other 'pages' on your WordPress site will use a
* different template.
*
* @package Dreamsrent
*/
$current_user = wp_get_current_user();
$current_user = wp_get_current_user();
$login_page = dreamsrent_fl_framework_getoptions('header_login_link');
// Redirect non-logged-in users early
if ( ! is_user_logged_in() ) {
nocache_headers();
wp_redirect( esc_url( get_permalink( $login_page ) ) );
exit();
}
get_header();
$current_user = wp_get_current_user();
$user_id = get_current_user_id();
$roles = $current_user->roles;
$role = array_shift($roles);
if (!empty($current_user->user_firstname)) {
$name = $current_user->user_firstname;
} else {
$name = $current_user->display_name;
}
?>
<!-- Content
================================================== -->
<div class="page-wrapper">
<div class="content ">
<?php
while (have_posts()) : the_post();
the_content();
endwhile; // End of the loop.
?>
</div>
<?php get_footer(); ?>
</div>