<?php defined('BASEPATH')or exit("NO DIRECT ACCESS iS ALLOWED");?>
<?php echo $this->uri->segment(n);?>


<div class="col-md-12  padding_sidebar">
<div class="row" style="margin-right:0px ;margin-left:0px;">
		<div class="card-head profile-categories_bread">
    		<!-- <header>Program Offered </header> -->
    		    <div class="pull-left"><?php echo  $link;?></div>


    		 <ol class="breadcrumb page-breadcrumb pull-right">
                    <li><i class="fa fa-home"></i>&nbsp;<a class="parent-item" href="<?=site_url('Student')?>">Home</a>&nbsp;<i class="fa fa-angle-right"></i>
                    </li>
                   <!--  <li><a class="parent-item" href="#">Class List</a>&nbsp;<i class="fa fa-angle-right"></i></li> -->
                    <li class="active">Program Offered</li>

             </ol>
			      <div class="pull-left">
			          <!-- <a href="#" class="btn btn-sm btn-social btn-github pull-right button_collapse" style="background:#FF6275"> 	TOG OFFERED PROGRAMS</a> -->
                <a href="#" class="btn btn-sm  pull-right " style="background:#FF6275;font-size: 11px!important;padding: 6px 6px;margin-top: 2px!important;cursor:default;"> 	TOG OFFERED PROGRAMS</a>
						</div>
    	</div>

    <div class="card card-topline-purple">
    	<div class="card-head">

    	</div>

 	<div class="table-responsive">
	   <div id="tableContainer2" class="container-tb">
	     <table class="table" style="font-family: sans-serif;font-size: 12px;">
    			<thead>
    				<tr>
    					<th>#</th>
    					<th>Program</th>
    					<th>Class</th>
    					<th>Subject</th>
    				</tr>
    			</thead>
    		   <tbody>
    		   <?php if( count($list) ):$sn=1;
                    $count = $this->uri->segment(4);
                    foreach($list as $lists ): ?>
    				<tr>
    				    <td><?php echo  $sn;?></td>
    				    <td><?php echo  strtoupper($lists->category);?></td>
    					<td><?php echo  strtoupper($lists->class);?></td>
    					<td>
                <!-- <a href="<?=site_url("Student/program/subject-list/{$lists->id}");?>">
    					         <span class="label label-mini" style="background: linear-gradient(45deg,#FFB64D,#ffcb80);">Subject List</span>
    					  </a> -->
                <a class="popper" id="dd" data-popbox="pop1" onclick="hello(<?=$lists->id?>)"  ><!--- onmouseover="hello(<?=$lists->id?>)" onmouseout="$('#pop1').empty();" onmouseout="$('#pop1').empty();"-->

                 <span class="label label-info label-mini"
                 style="background: linear-gradient(45deg,#FFa500,#ff869a);cursor:pointer;">Subject list</span>
                </a>
            </td>
    				</tr>
            		<?php $sn++;unset($json2);?>
                    <?php endforeach; ?>
                    <?php else : ?>
                    <tr><td><a href="#">No Record Found</a></td></tr>
                    <?php endif; ?>
    		  </tbody><?php $count++; //echo  $link; ?>

    		</table>
    	</div>
    </div>
</div>
</div>
</div>
</div>
</div>

<script type="text/javascript">

	function hello(id){
    $('#pop1').empty();
		$.ajax({
           type: "POST",
           url: "<?php echo site_url('Student/program_offered_subject_list_byid')?>/" + id,
           data:{action:'call_this'},
           success:function(html) {
             $('#pop1').append(html);
           }
      	});
    }
	function close_students(){
		$('#pop1').empty();
		document.getElementById("pop1").style.display ="none";
	}
	
</script>

<!-- <script>
function hide() {
    document.getElementById('pop1').style.display = 'none';
}
</script> -->
