<?php include_once('header.php');
$limit=6; 
$courses=get_course_master($limit);
?>
<!-- START HOME -->
	<section  id="home" class="home_bg2" style="background-image: url(assets/images/banner/home2.png); height: 200px; background-size:cover; background-position: center center;">	
		<div class="container">
			<div class="row">
				<div class="col-lg-12 col-sm-12 col-xs-12 text-center">	
                	
                
                
					<div class="home_content hc_pt">
						<h1>Hi.. <span><u> <?php echo $_SESSION['name_log']; ?> </u></span>  </h1>
						<h3>Learn Smart. Grow Fast.  <span><u class="text-success">  Succeed </u></span>  Strong .</h3>						
					</div>
					<div class="home_sb" style="display:none">
						<form action="#" class="banner_subs">
							<input type="text" class="form-control home_si" placeholder="Search your course here" required="required">
							<button type="button" class="subscribe__btn">Search <i class="fa fa-paper-plane-o"></i></button>
						</form>
					</div>
					<div class="home_tag" style="display:none">
						<span>Popular Topic:</span>
						<a href="#">Design, </a>
						<a href="#">Development, </a>
						<a href="#">Graphics, </a>
						<a href="#">Marketing </a>
					</div>		  
				</div><!-- END COL-->
			</div><!--- END ROW -->			
		</div><!--- END CONTAINER -->
	</section>
	<!-- END  HOME -->
    
    <section class="topic_content_p2 section-padding">
	   <div class="container">
			<div class="section-title">
				<h2>Start Learning </h2>
			</div>		
			<div class="row">
            	<?php 
				 for($i=0;$i<count($courses);$i++)
				   {
				   $course_count=get_courses('',$courses[$i]['id'],'',1,'');
				?>									
				<div class="col-lg-4 col-sm-6 col-xs-12">
					<div class="single_tca">
						<img src="assets/images/icon/ct1.svg" alt="" />
						<h2><a href="filter_courses.php?course_id=<?php echo $course_count[0]['id']; ?>"><?php echo $courses[$i]['title']; ?></a></h2>
						<span><?php echo count($course_count); ?> Courses</span>
					</div>					
				</div><!-- END COL -->	
                <?php } ?>					
				<?php /*?><div class="col-lg-4 col-sm-6 col-xs-12">
					<div class="single_tca">
						<img src="assets/images/icon/ct2.svg" alt="" />
						<h2><a href="#">Digital Program</a></h2>
						<span>59 Courses</span>
					</div>					
				</div><!-- END COL -->							
				<div class="col-lg-4 col-sm-6 col-xs-12">
					<div class="single_tca">
						<img src="assets/images/icon/ct3.svg" alt="" />
						<h2><a href="#">Finance</a></h2>
						<span>68 Courses</span>
					</div>					
				</div><!-- END COL -->							
				<div class="col-lg-4 col-sm-6 col-xs-12">
					<div class="single_tca">
						<img src="assets/images/icon/ct4.svg" alt="" />
						<h2><a href="#">Modern Physics</a></h2>
						<span>83 Courses</span>
					</div>					
				</div><!-- END COL -->							
				<div class="col-lg-4 col-sm-6 col-xs-12">
					<div class="single_tca">
						<img src="assets/images/icon/ct5.svg" alt="" />
						<h2><a href="#">Music Production</a></h2>
						<span>37 Courses</span>
					</div>					
				</div><!-- END COL -->							
				<div class="col-lg-4 col-sm-6 col-xs-12">
					<div class="single_tca">
						<img src="assets/images/icon/ct6.svg" alt="" />
						<h2><a href="#">Data Science</a></h2>
						<span>51 Courses</span>
					</div>					
				</div><!-- END COL -->	
				<div class="col-lg-12 text-center">
					<div class="cc_btn">
						<a class="btn_one" href="course.html">View All category</a>
					</div>
				</div><!--END COL -->	<?php */?>				
			</div><!-- END ROW -->
		</div><!-- END CONTAINER -->
	</section>

<?php include_once('footer.php'); ?>