Sindbad~EG File Manager
<?php
$turitor_course_layout = turitor_option('course_layout_style', 'standard');
$profile = LP_Global::profile();
$filter_status = LP_Request::get_string( 'filter-status' );
$turitor_course = $profile->query_courses( 'own', array( 'status' => $filter_status ) );
$limit = LP()->settings->get('learn_press_profile_courses_limit');
$user = $profile->get_user();
$id = $user->get_id();
if(isset($_REQUEST['pg'])){
$paged = $_REQUEST['pg'];
}else{
$paged = 1;
}
$args = array(
'post_type' => LP_COURSE_CPT,
'orderby' => 'modified',
'order' => 'DESC',
'posts_per_page' => $limit,
'paged' => $paged,
'author' => $id,
'post__in' => $turitor_course['items']
);
$args = apply_filters('turitor_instructor_course_args',$args);
$query = new WP_Query($args);
$total = $query->found_posts;
?>
<div class="row">
<?php
if($query->have_posts()){
while ($query->have_posts()) : $query->the_post();
if($turitor_course_layout == 'solid'){
get_template_part( 'learnpress/content-course', 'archive-solid' );
}else{
get_template_part( 'learnpress/content-course', 'archive' );
}
endwhile;
wp_reset_postdata();
} else{
echo "<div class='col-lg-12'><p class='alert alert-danger'>" . esc_html__("Course not found", 'turitor'). '</p></div>';
}
?>
</div>
<?php
$GLOBALS['wp_query']->max_num_pages = $query->max_num_pages;
get_template_part( 'template-parts/blog/paginations/pagination', 'style2' );
?>
Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists