<div class="checkbox">jjjghjjghj
  <?php
  	$course_name=$a_row[2];
  $queryy = "SELECT * FROM subject where college_code='$college' and college_type='$CourseType' and course_name='$Course'";
  $numresultsy=mysql_query($queryy);$resulty= mysql_query($queryy) or die("Couldn't execute query1");
  //////////////////////////////////
  $queryyn = "SELECT * FROM seme_year where college_id='$college' and college_type='$CourseType' and course_name='$Course' and sem_yer='$Course_Details'  and college_id='$college'";
  $numresultsyn=mysql_query($queryyn);
  $resultyn= mysql_query($queryyn) or die("Couldn't execute query2");
  $a_rown = mysql_fetch_row( $resultyn );$cv=$a_rown[3]; ?>
  <input name="cv" type="hidden" value="<?php echo $cv; ?>"/>
  <table width="100%" border="1">
    <tr>
      <?php if((($Course==65)&&($Course_Details=='I-SEM'))||(($Course==66)&&($Course_Details=='I-SEM'))){ ?>
      <td width="15%">3rd Major Subjects</td>
      <td width="16%">Miner Subjects</td>
      <td width="16%">Vocational Subjects</td>
      <td width="10%">Compulsury Paper's</td>
      <?php } ?>
      <td width="43%"><?php if((($Course==65)&&($Course_Details=='I-SEM'))||(($Course==66)&&($Course_Details=='I-SEM'))){ ?>
        Major Subjects
        <?php } ?></td>
    </tr>
    <tr>
      <?php if((($Course==65)&&($Course_Details=='I-SEM'))||(($Course==66)&&($Course_Details=='I-SEM'))){ ?>
      <td style="color:#0000FF; font-weight:bold">उपलब्ध विषयों में से किसी 01 विषय का चयन तृतीय विषय के रूप में अनिवार्य होगा जो उसी संकाय से लेना होगा</td>
      <td style="color:#0000FF; font-weight:bold">उपलब्ध विषयों में से किसी 01 विषय का चयन चतुर्थ विषय के रूप में अनिवार्य होगा जो किसी अन्य संकाय से लेना होगा</td>
      <td style="color:#0000FF; font-weight:bold">दिये गये विषयों में कौशल विकास विषय/प्रश्नपत्र के रूप में किन्ही 01 विषय का चयन करें</td>
      <td style="color:#0000FF; font-weight:bold">अनिवार्य प्रश्नपत्र</td>
      <?php } ?>
      <td style="color:#0000FF; font-weight:bold"><?php if((($Course==65)&&($Course_Details=='I-SEM'))||(($Course==66)&&($Course_Details=='I-SEM'))){ ?>
        किन्ही 01 विषयों का चयन करें
        <?php } ?></td>
    </tr>
    <tr>
      <?php if((($Course==65)&&($Course_Details=='I-SEM'))||(($Course==66)&&($Course_Details=='I-SEM'))){ ?>
      <td><?php if($_POST['major_subject2']!=""){$major_subject2=$_POST['major_subject2'];}else{$major_subject2=$row['major_subject2'];}?>
        <?phpif((in_array($major_subject2,$my_stored_game, true))||(in_array($major_subject2,$all_game_valueb, true))||($major_subject2==$minorsubject)){?>
        <div style="color:#FF0000; font-weight:bold">आपने पहले ही ये सब्जेक्ट चुन लिया है कोई और सब्जेक्ट चुनें</div>
        <?php }?>
        <select name="major_subject2" style="width:200px;" required onchange='this.form.submit()'>
          <option value="" <?php if($major_subject2==""){ ?>selected<?php } ?>></option>
          <option value="HOME SCIENCE" <?php if($major_subject2=="HOME SCIENCE"){ ?>selected<?php } ?>>HOME SCIENCE</option>
          <option value="HINDI" <?php if($major_subject2=="HINDI"){ ?>selected<?php } ?>>HINDI</option>
          <option value="ENGLISH" <?php if($major_subject2=="ENGLISH"){ ?>selected<?php } ?>>ENGLISH</option>
          <option value="SOCIOLOGY" <?php if($major_subject2=="SOCIOLOGY"){ ?>selected<?php } ?>>SOCIOLOGY</option>
          <option value="SANSKRIT" <?php if($major_subject2=="SANSKRIT"){ ?>selected<?php } ?>>SANSKRIT</option>
          <option value="Drawing and Painting" <?php if($major_subject2=="Drawing and Painting"){ ?>selected<?php } ?>>Drawing and Painting</option>
          <option value="EDUCATION" <?php if($major_subject2=="EDUCATION"){ ?>selected<?php } ?>>EDUCATION</option>
        </select></td>
      <td><?php if($_POST['minorsubject']!=""){$minorsubject=$_POST['minorsubject'];$minorsubject2=$_POST['minorsubject'];}else{$minorsubject=$row['minorsubject'];$minorsubject2=$row['minorsubject'];} ?>
        <?phpif((in_array($minorsubject,$my_stored_game, true))||(in_array($minorsubject,$all_game_valueb, true))||($major_subject2==$minorsubject)){?>
        <div style="color:#FF0000; font-weight:bold">आपने पहले ही ये सब्जेक्ट चुन लिया है कोई और सब्जेक्ट चुनें !</div>
        <?php }?>
        <select name="minorsubject"  required style="width:200px;" onchange='this.form.submit()'>
          <option value="" <?php if($minorsubject==""){ ?>selected<?php } ?>></option>
          <option value="HOME SCIENCE" <?php if($minorsubject=="HOME SCIENCE"){ ?>selected<?php } ?>>HOME SCIENCE</option>
          <option value="HINDI" <?php if($minorsubject=="HINDI"){ ?>selected<?php } ?>>HINDI</option>
          <option value="ENGLISH" <?php if($minorsubject=="ENGLISH"){ ?>selected<?php } ?>>ENGLISH</option>
          <option value="SOCIOLOGY" <?php if($minorsubject=="SOCIOLOGY"){ ?>selected<?php } ?>>SOCIOLOGY</option>
          <option value="SANSKRIT" <?php if($minorsubject=="SANSKRIT"){ ?>selected<?php } ?>>SANSKRIT</option>
          <option value="Drawing and Painting" <?php if($minorsubject=="Drawing and Painting"){ ?>selected<?php } ?>>Drawing and Painting</option>
          <option value="EDUCATION" <?php if($minorsubject=="EDUCATION"){ ?>selected<?php } ?>>EDUCATION</option>
        </select></td>
      <td><?php if($_POST['vcourse']!=""){$vcourse=$_POST['vcourse'];}else{$vcourse=$row['vcourse'];} ?>
        <?phpif((in_array($vcourse,$my_stored_game, true))||(in_array($vcourse,$all_game_valueb, true))||($vcourse==$minorsubject)||($vcourse==$major_subject2)){?>
        <div style="color:#FF0000; font-weight:bold">आपने पहले ही ये सब्जेक्ट चुन लिया है कोई और सब्जेक्ट चुनें !</div>
        <?php }?>
        <select name="vcourse" style="width:200px;" required onchange='this.form.submit()'>
          <option value="" ></option>
          <option value="Tailoring & Embroidery" <?php if($vcourse=="Tailoring & Embroidery"){ ?>selected<?php } ?>>Tailoring & Embroidery</option>
          <option value="House Keeping" <?php if($vcourse=="House Keeping"){ ?>selected<?php } ?>>House Keeping</option>
          <option value="Nutrition & Dietician" <?php if($vcourse=="Nutrition & Dietician"){ ?>selected<?php } ?>>Nutrition & Dietician</option>
          <option value="Yoga & Fiteness" <?php if($vcourse=="Yoga & Fiteness"){ ?>selected<?php } ?>>Yoga & Fiteness</option>
          <option value="Information Communication  Technology" <?php if($vcourse=="Information Communication  Technology"){ ?>selected<?php } ?>>Information Communication  Technology</option>
          <option value="Legal Services Assistance" <?php if($vcourse=="Legal Services Assistance"){ ?>selected<?php } ?>>Legal Services Assistance</option>
          <option value="Sales & Marketing Management" <?php if($vcourse=="Sales & Marketing Management"){ ?>selected<?php } ?>>Sales & Marketing Management</option>
          <option value="Computerized Accounting" <?php if($vcourse=="Computerized Accounting"){ ?>selected<?php } ?>>Computerized Accounting</option>
          <option value="Horticulture & Garden Supervising" <?php if($vcourse=="Horticulture & Garden Supervising"){ ?>selected<?php } ?>>Horticulture & Garden Supervising</option>
          <option value="Disaster Management" <?php if($vcourse=="Disaster Management"){ ?>selected<?php } ?>>Disaster Management</option>
          <option value="Science Laboratory Establishment & Management" <?php if($vcourse=="Science Laboratory Establishment & Management"){ ?>selected<?php } ?>>Science Laboratory Establishment & Management</option>
          <option value="Basic Instrumentation Skills" <?php if($vcourse=="Basic Instrumentation Skills"){ ?>selected<?php } ?>>Basic Instrumentation Skills</option>
          <option value="Textile Design" <?php if($vcourse=="Textile Design"){ ?>selected<?php } ?>>Textile Design</option>
          <option value="Sculpture" <?php if($vcourse=="Sculpture"){ ?>selected<?php } ?>>Sculpture</option>
          <option value="Defence Journalism" <?php if($vcourse=="Defence Journalism"){ ?>selected<?php } ?>>Defence Journalism</option>
          <option value="Primary Health Care" <?php if($vcourse=="Primary Health Care"){ ?>selected<?php } ?>>Primary Health Care</option>
          <option value="Community Health Care" <?php if($vcourse=="Community Health Care"){ ?>selected<?php } ?>>Community Health Care</option>
          <option value="Nursing Assistant" <?php if($vcourse=="Nursing Assistant"){ ?>selected<?php } ?>>Nursing Assistant</option>
        </select></td>
      <td><input type="text"  name='cccourse' value='communication skills and personality development'/></td>
      <?php } ?>
      <td><?php if(($Course==65)&&($Course_Details=='I-SEM')){ ?>
        <script type="text/javascript">function chkcontrol(j) {var total=0;for(var i=0; i < document.form1.ckb.length; i++){if(document.form1.ckb[i].checked){total =total +1;}if(total > 1){alert("Please Select only 1") document.form1.ckb[j].checked = false ;return false;}}} </script>
<style>
.tu li{ float:left; width:250px;}
</style>
        <ul class="tu">
          <?php	 $c=0;while ( $a_roww = mysql_fetch_row( $resulty ) ) { $sx=$a_roww[1]; ?>
          <li>
            <input type='checkbox' name='ckb[]' id="ckb" value='<?php echo $a_roww[1]; ?>' <?php if(in_array($sx,$my_stored_game, true)){print "checked";}?> onclick='chkcontrol(<?php echo $c;?>)';>
            <?php echo $a_roww[1];?></li>
          <?php 				  				  $c++;				  } ?>
        </ul>
        <?php }elseif(($Course==66)&&($Course_Details=='I-SEM')){ ?>
        <script type="text/javascript">function chkcontrol(j) {var total=0;for(var i=0; i < document.form1.ckb.length; i++){if(document.form1.ckb[i].checked){total =total +1;}if(total > <?php echo $cv; ?>){alert("Please Select only <?php echo $cv; ?>") document.form1.ckb[j].checked = false ;return false;}}} </script>
        <style>
.tu li{ float:left; width:250px;}
</style>
        <ul class="tu">
          <?php	 $c=0;while ( $a_roww = mysql_fetch_row( $resulty ) ) { $sx=$a_roww[1]; ?>
          <li>
            <input type='checkbox' name='ckb[]' id="ckb" value='<?php echo $a_roww[1]; ?>' <?php if(in_array($sx,$my_stored_game, true)){print "checked";}?> onclick='chkcontrol(<?php echo $c;?>)';>
            <?php echo $a_roww[1];?></li>
          <?php 				  				  $c++;				  } ?>
        </ul>
        <?php }else{ ?>
        <script type="text/javascript">function chkcontrol(j) {var total=0;for(var i=0; i < document.form1.ckb.length; i++){if(document.form1.ckb[i].checked){total =total +1;}if(total > <?php echo $cv; ?>){alert("Please Select only <?php echo $cv; ?>") document.form1.ckb[j].checked = false ;return false;}}} </script>
        <style>
.tu li{ float:left; width:250px;}
</style>
        <ul class="tu">
          <?php	 $c=0;while ( $a_roww = mysql_fetch_row( $resulty ) ) { $sx=$a_roww[1]; ?>
          <li>
            <input type='checkbox' name='ckb[]' id="ckb" value='<?php echo $a_roww[1]; ?>' <?php if(in_array($sx,$my_stored_game, true)){print "checked";}?> onclick='chkcontrol(<?php echo $c;?>)';>
            <?php echo $a_roww[1];?></li>
          <?php 				  				  $c++;				  } ?>
        </ul>
        <?php } ?></td>
    </tr>
  </table>
</div>
