D:\host\scoreman.in\kldistricts2025\New folder\index.php

<?php
include('dbconnect.php');
include('jfunctions.php');
include('functions.php');

function auto_version($file)
{
 // if(strpos($file, '/') !== 0 || !file_exists($_SERVER['DOCUMENT_ROOT'] . $file))
 
//    return $file;

  //$mtime = filemtime($file);
 // return preg_replace('{\\.([^./]+)$}', ".$mtime.\$1", $file);

$appvers=13;
return $file."?version=".$appvers;
}

//header("Cache-Control: no-cache, no-store, must-revalidate"); // HTTP 1.1.
//header("Pragma: no-cache"); // HTTP 1.0.
//header("Expires: 0"); // Proxies.
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />

<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/font-awesome/4.3.0/css/font-awesome.min.css" />
		<link rel="stylesheet" href="//ajax.googleapis.com/ajax/libs/jquerymobile/1.4.5/jquery.mobile.min.css" />
		<link rel="stylesheet" href="vendor/waves/waves.min.css" />
		<link rel="stylesheet" href="css/nativedroid2.css" />
        <link rel="stylesheet" href="css/cbstyle.css" />
      	<link rel="stylesheet" href="vendor/wow/animate.css" />
		<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Lato:400,900|Montez" />
		
		
		<!-- <link rel="stylesheet" type="text/css" href="../css/sparkle.css">  

		
		<style>
	/*	//*[@id="entryform"]/div[1]/div[3]/div/div/div[1]
		#entryform > div:nth-child(1) > div:nth-child(3) > div > div > div 
		{
			content:"";
			display:none !important;
			width:50% !important;
			height:0px !important;
		}*/
		</style>-->

		<style>
		
		
		
		h1 span, h2 span, h3 span {
  font-family: Montez;
  font-size: 1.9em;
  font-weight: 300;
  margin: 0 0.3em;
  color: #ff0080;
}
		</style>
		
		  <style type='text/css'>
table {
    border-collapse: collapse;
}
		

       body { background-image:url("jimages/bg8.jpg");
 background-repeat: no-repeat;
    background-attachment: fixed;
	 background-size: cover;

	   }
        @media only screen and (min-width: 600px){
            .ui-page {
                width: 100% !important;
				max-width:1200px !important;
                margin: 0 auto !important;
                position: relative !important;
             //  border-right: 1px #aaa  !important;
            //   border-left: 1px #aaa  !important;
			//   border-top: 1px #aaa  !important;
			//	 border-style: solid !important;
				// border: 1px #666  !important;
			//	box-shadow:0 0 3px 1px #aaa;
				
			//	background-image:url("jimages/rsfi trans bg.jpg");
			//	background-size: 32%;
			//	background-position:center;
 //background-repeat: no-repeat;
            }
        }
		
	

    </style>
	

<script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.4/jquery.min.js"></script>
		<script src="//code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>
		<script src="//ajax.googleapis.com/ajax/libs/jquerymobile/1.4.5/jquery.mobile.min.js"></script>
		<script src="vendor/waves/waves.min.js"></script>
        
      <script src="//cdnjs.cloudflare.com/ajax/libs/jquery-cookie/1.4.1/jquery.cookie.min.js"></script>
        
        
        <script src="vendor/wow/wow.min.js"></script> 
		<script src="js/nativedroid2.js"></script>
		<script src="nd2settings.js"></script>
        
         <script src="js/jquery.cropit.js"></script>
         <script type="text/javascript" src="<?php echo auto_version('j.js'); ?>"></script>
         <script src="https://cdnjs.cloudflare.com/ajax/libs/jspdf/0.9.0rc1/jspdf.min.js"></script>
         
           

  
  <script type="text/javascript">
  
  
  
   window.onload = function () {
	   var lastScrollTop = $.cookie('last-scroll-top');
	//    alert(lastScrollTop);
if (lastScrollTop) {
    $(window).scrollTop(lastScrollTop);
//	$(window).scroll(0,lastScrollTop);
	
	// alert("final"+ $(window).scrollTop());
    $.removeCookie('last-scroll-top');
}
   }
    $(function() {
$('.image-editor').cropit({
 maxZoom: 2,
 smallImage: 'stretch'
});
$('.image-editor').cropit('initialZoom', 'fit');

$('#image-editor2').cropit({
 maxZoom: 2,
 smallImage: 'stretch',
 minZoom:'fit'
});
$('#image-editor2').cropit('initialZoom', 'fit');
$('#image-editor2').cropit('previewSize', { width:248, height: 350.75});


 $("#slider-step").on('slidestop', function (event) {
    console.log("slidestop event fired");
  });
  
//$zoomSlider= $('.image-editor').find('input.cropit-image-zoom-input');
		
		 $('#photorotcw').click(function() {
          $('.image-editor').cropit('rotateCW');
        });
        $('#photorotccw').click(function() {
          $('.image-editor').cropit('rotateCCW');
        });
		
		
			 $('#dobrotcw').click(function() {
          $('#image-editor2').cropit('rotateCW');
        });
        $('#dobrotccw').click(function() {
          $('#image-editor2').cropit('rotateCCW');
        });


        $('#entryform').submit(function() {
          // Move cropped image data to hidden input
	//	    var w = window.open();
			
      //    var imageData = $('.image-editor').cropit('export');
		   var imageData = $('.image-editor').cropit('export', {
  type: 'image/jpeg',
  quality: .8,
  
});
		  
		  if(typeof imageData !== "undefined")
		  {
			
          $('.hidden-image-data').val(imageData);
		  }
		  
		  $('#image-editor2').cropit('exportZoom', 2.5);
		  
		  var dobData = $('#image-editor2').cropit('export', {
  type: 'image/jpeg',
  quality: .8,
  
});

//// dobData = $('#image-editor2').cropit('export');
// console.log("DobData");
 //console.log(dobData);
 if(typeof dobData !== "undefined")
 {
          $('.hidden-dob-data').val(dobData);
	//	  console.log("Setting..");
 }
 // console.log("HDobData");
 //  console.log(  $('.hidden-dob-data').val());		  
		//  alert(dobData);
		  
if(checkform()==false)
		 {
			 return false;
			 
			 }

          // Print HTTP request params
        //  var formValue = $(this).serialize();
        //  $('#result-data').text(formValue);
		$.mobile.loading( "show", {
  text: "Submitting...",
  textVisible: true,
  theme: "z",
  html: ""
});

   
       
  //  }
	$serdata=$('#entryform').serialize();
	///console.log($serdata);
		$.ajax({
        url: 'register.php',
        type: 'post',
        dataType: 'text',
	       data: $serdata,
        success: function(data) {
			 console.log("data received:");
                console.log(data);
			//	 $(w.document.body).html(data);
			  try {
    
		var myObj = JSON.parse(data);
		if(myObj.status=="error")
			{
				console.log("error");
			//	var dobd=$("#dob").val();
		//	alert(myObj.name+" "+myObj.message);
		$("#poptitle").html("ERROR! - NOT SAVED.");
			$("#alertmessage").html(myObj.message);
	//$("#printappbtn").attr("href", "application.php?appno="+myObj.appno+"&k="+encodeURIComponent(myObj.name));
	////$("#printappbtn").hide();
			$.mobile.changePage( "#successpop", { role: "dialog" } );
		/*$("#successpop").show();
			$.mobile.changePage(
    "#successpop",
    {
      allowSamePageTransition : true,
      showLoadMsg             : false,
      reloadPage              : false
    });
	
	$.mobile.changePage("#myDialog");*/
				
			}
			if(myObj.status=="success")
			{
				console.log("success");
			//	var dobd=$("#dob").val();
		//	alert(myObj.name+" "+myObj.message);
			$("#alertmessage").html("Application No : " +myObj.appno+"<br/>"+myObj.name+" "+myObj.message);
///			$("#printappbtn").show();
///	$("#printappbtn").attr("href", "application.php?appno="+myObj.appno+"&k="+encodeURIComponent(myObj.name));
			$.mobile.changePage( "#successpop", { role: "dialog" } );
		/*$("#successpop").show();
			$.mobile.changePage(
    "#successpop",
    {
      allowSamePageTransition : true,
      showLoadMsg             : false,
      reloadPage              : false
    });
	
	$.mobile.changePage("#myDialog");*/
				
			}
			  }
  catch (e) {
    console.log("error: "+e);
  alert(e);
	
  };
	
		 clearform();
	// location.reload();
                 }
    });
	

          // Prevent the form from actually submitting
          return false;
        });
      });
	  


</script>





<style>
      
	    .cropit-preview {
        background-color: #f8f8f8;
        background-size: cover;
        border: 1px solid #ccc;
        border-radius: 3px;
        margin-top: 7px;
        width: 240px;
        height: 240px;
      }

      .cropit-preview-image-container {
        cursor: move;
      }

      .image-size-label {
        margin-top: 10px;
      }

      input {
       /* display: block;*/
      }

      button[type="submit"] {
        margin-top: 10px;
      }

      #result {
        margin-top: 10px;
        width: 900px;
      }

      #result-data {
        display: block;
        overflow: hidden;
        white-space: nowrap;
        text-overflow: ellipsis;
        word-wrap: break-word;
      }
<style>
@media print
{    
    .noprint, .noprint *
    {
        display: none !important;
		visibility: hidden; 
    }
	
	table
{
font-size:10px;
max-width:60%;
}

}



/*table, th, td {
    border: 1px solid black;
}


table
{
	font-family:Verdana, Geneva, sans-serif;
    border-collapse: collapse;
}
			th
			{
				background-color:#EBEBEB;
				color:#00F;
				text-align: center;
				vertical-align: bottom;
				height: 100px;
				padding-bottom: 3px;
				padding-left: 0px;
			padding-right: 0px;
			
			}
			td{
				text-align:center;
padding-bottom: 3px;
padding-top: 3px;
			} */
			tr:nth-child(even) {
    background-color:#F1F1F8;
}

table
{
font-size:11px;
max-width:100%;
margin:0px;
}
table, th, td {
    border: 1px solid #ccc;

}



	th{
text-align: center;
				vertical-align: middle;
				//height: 110px;
				padding-bottom: 3px;
				padding-left: 0px;
			padding-right: 0px;
				
			
background-color:#E6E6E6;

	}
   


			.verticalText1
			{
				/*font-family:"Trebuchet MS", Arial, Helvetica, sans-serif;*/
				font-size:11px;
				text-align: left;
				vertical-align: bottom;
				width: 12px;
				margin:0px;
				margin-top:120px;
				padding: 0px;
				padding-left: 0px;
				padding-right: 0px;
				padding-top: 0px;
				
			
				white-space: nowrap;
				-webkit-transform: rotate(-90deg); 
				-moz-transform: rotate(-90deg);  				
			};
		</style>
  
</head>





<body>


<div data-role="page" id="page1" data-url="page1"> 

<div data-role="header" style="overflow:hidden;">
<h1 style="text-align:center;"><?php echo $configs['eventtitle']; ?></h1>
       <div data-role="navbar" class="noprint">
        <ul>
            <li><a href="index.php#page1">Entries</a></li>
            <li><a href="#"  id="logout_btn">Logout <?php echo $_SESSION["username"] ?></a></li>
        </ul>
    </div><!-- /navbar -->
	<div class="box" style="background-color:blue;" class="noprint">
	<ul data-role="nd2tabs" data-swipe="true">
	<li data-tab="summary" data-tab-active="true" >Summary</li>
<!--	<li data-tab="u8q" id="under8qtabm">U8-Quad</li>
	<li data-tab="u8i" id="under8itabm">U8-Inline</li> -->
	<li data-tab="speedquad" id="quadtabm">Speed-Quad</li>
	<li data-tab="speedinline" id="inlinetabm" >Speed-Inline</li>
	<li data-tab="artistic" id="artistictabm">Artistic</li>
	<li data-tab="rollerhockey" id="rhockeytabm">Roller Hockey</li>
	<li data-tab="inlinehockey" id="ihockeytabm">Inline Hockey</li>
	<li data-tab="inlinefreestyle" id="ifreestyletabm">Inline Freestyle</li>
	<!--<br/>
	<li data-tab="inlinehockey">Alpine</li>
	<li data-tab="inlinehockey">Downhill</li>
	<li data-tab="inlinehockey">Roller Derby</li>
	<li data-tab="inlinehockey">Roller Freestyle</li>
		<li data-tab="inlinehockey">Skateboarding</li> -->

	
	
	<li data-tab="otherdisciplines" id="othertabm">Others</li>
</ul>

	</div>

</div><!-- /header -->

 

<div data-role="main" class="ui-content">
<!--<p><h4 style="color:green;"><b>Thank you for your great support.</b></h4></p>
 <p><h4 style="color:green;"><b style="color:RED;">Registrations Closed.</b></h4></p> -->
<?php

//if ($_SERVER['REQUEST_METHOD'] == 'POST')
//{
	
	//$skey=$_POST["skey"];
	//$club=$_POST["club"];
	$club=$_SESSION["username"];
	
	if ($_SERVER['REQUEST_METHOD'] == 'GET')
	{
		$_SESSION["team"]=$_GET['team'];
	}
	
	$team=$_SESSION["team"];
	
	?>
	
	<?php
if($club =="")
{
	loginbox();
	//exit();
}

?>

<button  onclick="newapp(); " data-rel="page"  class="ui-btn ui-btn-raised clr-warning ui-btn ui-btn-inline waves-effect waves-button waves-effect waves-button" ><i class="zmdi zmdi-account-add zmd-2x"></i> Add New Entry</button>

<!--<button  onclick="teammanagers(); " data-rel="page"  class="ui-btn ui-btn-raised clr-warning ui-btn ui-btn-inline waves-effect waves-button waves-effect waves-button" ><i class="zmdi zmdi-account-add zmd-2x"></i>Add Team Manager</button>
-->



   <button  onclick="newapp();" data-rel="page" data-position-to="window" class="ui-btn-fab ui-btn-raised clr-warning ui-btn ui-btn-inline waves-effect waves-button waves-effect waves-button" style="position:fixed;right:10px;bottom:10px;"><i class="zmdi zmdi-account-add zmd-2x"></i></button>
 



 
<div data-role="nd2tab" data-tab="summary">
<?php
if($club =="secretary")
	{
		echo "Team Wise Entries <br/><table border=1>";
		$databaseQuery = 'SELECT club,count(*) as c FROM applications group by club';
	$result = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
	while($row = mysqli_fetch_array($result))
  {
	   echo "<tr><td>".$row["club"]."</td><td>".$row["c"]."</td><!--<td class='noprint'><a  href='index.php?team=".$row["club"]."&stype=all'>View List</a></td>--></tr>";
  }
  echo "</table>";
  
  echo "Summary <br/><table border=1>";
		$databaseQuery = 'SELECT  status,count(appno) as c FROM applications group by status order by c desc';
	$result = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
	while($row = mysqli_fetch_array($result))
  {
	  if($row["status"]!="")
	  {
	   echo "<tr><td>".$row["status"]."</td><td>".$row["c"]."</td></tr>";
	  }
	  else
	  {
		  	   echo "<tr><td>Unverified</td><td>".$row["c"]."</td></tr>";
		  }
  }
  echo "</table>";
echo "Participation Summary <br/><table border=1>";
		$databaseQuery = 'SELECT  skatertype,count(appno) as c FROM applications group by skatertype order by c desc';
	$result = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
	while($row = mysqli_fetch_array($result))
  {
	  if($row["skatertype"]!="")
	  {
	   echo "<tr><td>".$row["skatertype"]."</td><td>".$row["c"]."</td></tr>";
	  }
	  else
	  {
		  	   echo "<tr><td>Unverified</td><td>".$row["c"]."</td></tr>";
		  }
  }
  echo "</table>";
	
	
	
	
	$club=$_GET['team'];
	$skey=$_GET['team'];
	$stype=$_GET['stype'];
	if($stype=="" || $stype=="all")
	{
		$stype="%";
		}
	
	$databaseQuery = 'SELECT * FROM applications WHERE (skatertype like "%'.$stype.'%") and (club like "%'.$con->real_escape_string($club).'%")  order by agorder+0,LTRIM(RTRIM(gender)) desc,LTRIM(RTRIM(skatertype)),club,CONVERT(LTRIM(RTRIM(appno)),UNSIGNED INTEGER)';
	//echo  $databaseQuery;
	$result2 = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
	$skey=$club;
	
	 echo "Summary for ".$club."<br/><table border=1>";
		$databaseQuery = 'SELECT  status,count(appno) as c FROM applications  WHERE (club like "%'.$con->real_escape_string($club).'%")  group by status order by c desc';
	$result = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
	while($row = mysqli_fetch_array($result))
  {
	  if($row["status"]!="")
	  {
	   echo "<tr><td>".$row["status"]."</td><td>".$row["c"]."</td></tr>";
	  }
	  else
	  {
		  	   echo "<tr><td>Unverified</td><td>".$row["c"]."</td></tr>";
		  }
  }
  echo "</table>";
		
	}
	else
	{
	//	$club=$_GET['team'];
	//$skey=$_GET['team'];
	$stype="all";
	if($stype=="" || $stype=="all")
	{
		$stype="%";
		}
	
	
	$skey=$club;
	
	 echo "Summary for ".$club."<br/><table border=1>";
		$databaseQuery = 'SELECT  status,count(appno) as c FROM applications  WHERE (club like "%'.$con->real_escape_string($club).'%")  group by status order by c desc';
	$result = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
	while($row = mysqli_fetch_array($result))
  {
	  if($row["status"]!="")
	  {
	   echo "<tr><td>".$row["status"]."</td><td>".$row["c"]."</td></tr>";
	  }
	  else
	  {
		  	   echo "<tr><td>Unverified</td><td>".$row["c"]."</td></tr>";
		  }
  }
  echo "</table>";
	} 
?>

</div>

<script>
$( "#under8qtabm" ).on( "click", function() {

  
	$( "#u8qtab" ).load( "lists.php?stype=Under8-Quad" );
	
  });
  $( "#under8itabm" ).on( "click", function() {

  
	$( "#u8itab" ).load( "lists.php?stype=Under8-Inline" );
	
  });
  
$( "#quadtabm" ).on( "click", function() {

  
	$( "#quadtab" ).load( "lists.php?stype=Speed-Quad" );
	
  });
  
  $( "#inlinetabm" ).on( "click", function() {

  
	$( "#inlinetab" ).load( "lists.php?stype=Speed-Inline" );
	
  });
  
  $( "#artistictabm" ).on( "click", function() {

  
	$( "#artistictab" ).load( "lists.php?stype=Artistic" );
	
  });
  
    $( "#rhockeytabm" ).on( "click", function() {

  
	$( "#rhockeytab" ).load( "lists.php?stype=Roller-Hockey" );
	
  });
  
    $( "#ihockeytabm" ).on( "click", function() {

  
	$( "#ihockeytab" ).load( "lists.php?stype=Inline-Hockey" );
	
  });
  
   
    $( "#ifreestyletabm" ).on( "click", function() {

  
	$( "#ifreestyletab" ).load( "lists.php?stype=Inline-Freestyle" );
	
  });
  
      $( "#othertabm" ).on( "click", function() {

  
	$( "#othertab" ).load( "lists.php?stype=Other" );
	
  });
  
  
  
  
 </script>
 
 <div data-role="nd2tab" data-tab="u8q">
 

<div id="u8qtab"></div>

</div>
 <div data-role="nd2tab" data-tab="u8i">
 

<div id="u8itab"></div>

</div>
 
<div data-role="nd2tab" data-tab="speedquad">
 

<div id="quadtab"></div>

</div>
<div data-role="nd2tab" data-tab="speedinline">

<div id="inlinetab"></div>


</div>

<div data-role="nd2tab" data-tab="artistic">

<div id="artistictab"></div>

</div>

<div data-role="nd2tab" data-tab="rollerhockey">
	<div id="rhockeytab"></div>
</div>
<div data-role="nd2tab" data-tab="inlinehockey">
	<div id="ihockeytab"></div>
</div>

<div data-role="nd2tab" data-tab="inlinefreestyle">
	<div id="ifreestyletab"></div>

</div>


<div data-role="nd2tab" data-tab="otherdisciplines">
	<div id="othertab"></div>
</div>



<script type="text/javascript">

//$(document).on("pagecreate","#page1", function(){ 
   
    //    $("#popupDialog").popup("open"); 
       
//});


$(document).on("pagecreate", function () {
		  $("#logout_btn").click(function() {
            $.ajax({
                url: 'logout.php?argument=logOut',
                success: function(data){
               document.location.href = "index.php#login";
					 location.reload();
				/*		$.mobile.changePage(
    "index.php#login",
    {
      allowSamePageTransition : true,
      showLoadMsg             : true,
      reloadPage              : true
    }
	
  );*/
  
                }
            });
        });
	
	//clearform();
	//setraces();
  $(".cropit-image-zoom-input").on('slidestop', function (event) {
  //  console.log("slidestop event fired");
	 // console.log("zoomable"+$('.image-editor').cropit('isZoomable')+$(".cropit-image-zoom-input").val());
	$('.image-editor').cropit('zoom',  $(".cropit-image-zoom-input").val());
  });
  
  
  
  $(".cropit-image-zoom-input1").on('slidestop', function (event) {
  //  console.log("slidestop event fired");
	 // console.log("zoomable"+$('.image-editor').cropit('isZoomable')+$(".cropit-image-zoom-input").val());
	$('#image-editor2').cropit('zoom',  $(".cropit-image-zoom-input1").val());
  });

  
});



</script>


  
 


 </div>
  </div>
 

 <div data-role="page" id="login" data-url="login">  

<div data-role="header" style="overflow:hidden; text-align:center;">
<center><img src="logo.png" style="margin: 10px auto 0;    max-width: 15vh;    width: 100%;    display: block;">
<p>	<h3 style="margin-block-end:2px;">KARNATAKA ROLLER SKATING ASSOCIATION</h3>
Affiliated to Roller Skating Federation of India<br>
Recognized by Sports Authority of Karnataka</p></center>
<h1 style="text-align:center;  font-size:22px !important;     padding: .5em 0; !important"><?php echo $configs['eventtitle']; ?></h1>

      </div><!-- /header -->
 
 

<div data-role="main" class="ui-content">
<?php
	$club=$_SESSION["username"];
	
	if($club !="")
	{
	//	echo $club;
		?>
	<script type="text/javascript">
window.location = "index.php#page1";
</script>  
<?php
	}
	else
	{
		?>
		
				<div class="row">
					<div class="col-xs">
       <center>
		
<h2 ><span>Mysore - 2018</span></h2>
<h5>Organised & Conducted by</h5>
<h5>Karnataka Roller Skating Association</h5>
 <h5>Hosted by</h5>
<h5>Mysore District Roller Skating Association</h5>
<h4>14th to 17th Nov. 2018</h4> 

<!--<a onclick="$('#venue').show();"><button>Venue</button></a>-->
<!-- <a href="#"><button>Tentative Schedule</button></a> -->




</center>	</div>	</div>
		<div class="row">
    <!-- Lead story block -->


	
	<div class="col-xs">
        <div class="box">
           <div class="nd2-card" >

					<div class="card-media">
						
					</div>

					<div class="card-supporting-text">
						

				
  <form name="login-form" class="login-form" action="dashboard.php" method="post"  >
  <div style="padding:10px 20px;">
   <h3><center>District Login</center></h3>
            <h4>Please sign in</h4>
			<div class="ui-field-contain">
    

            <label for="district" >Username:</label>
            
			 <select  name="username" id="district" required="required" data-theme="a">

<option>Bagalkot</option>
<option>Bangalore Urban</option>
<option>Bangalore Rural</option>
<option>Belgaum</option>
<option>Bellary</option>
<option>Bidar</option>
<option>Bijapur</option>
<option>Chamarajanagar</option>
<option>Chikballapur</option>
<option>Chikmagalur</option>
<option>Chitradurga</option>
<option>Dakshina Kannada</option>
<option>Davanagere</option>
<option>Dharwad</option>
<option>Gadag</option>
<option>Gulbarga</option>
<option>Hassan</option>
<option>Haveri</option>
<option>Kodagu</option>
<option>Kolar</option>
<option>Koppal</option>
<option>Mandya</option>
<option>Mysore</option>
<option>Raichur</option>
<option>Ramanagara</option>
<option>Shimoga</option>
<option>Tumakuru</option>
<option>Udupi</option>
<option>Uttara Kannada</option>
<option>Yadgir</option>



  
    </select> 
	
	</div>
	
	<div class="ui-field-contain">
            <label for="password" class="ui-hidden-accessible">Password:</label>
            <input type="password" name="password" id="password" value="" placeholder="password" data-theme="a">
			
			</div>
			<div class="ui-field-contain">
            <button type="submit" class="ui-btn ui-corner-all ui-shadow clr-btn-green ui-btn-icon-left ui-icon-check">SUBMIT</button>
				</div>
        </div>
    </form>
	
	
	



					</div>      </div>
					
					 <div class="box" >

					

					<!--<div>
					<center>
		<h4>ARTISTIC MUSIC UPLOAD <a href="#musicupload" class="ui-btn ui-btn-inline ui-btn-raised">Click Here</a></h4>
		</center>
		</div> -->
		</div>
		
					
					<center>
					
					<!-- Display the countdown timer in an element -->

<h3>Registration Closes on 10th Nov. 2018. 11.59PM</h3>
<h2 id="demo" style="animation-name: flash;
    animation-duration:2.1s;
    animation-iteration-count: infinite; color:blue;"></h2>
	(remaining)
<script>
// Set the date we're counting down to
var countDownDate = new Date("Nov 10, 2018 23:59:00").getTime();

// Update the count down every 1 second
var x = setInterval(function() {

  // Get todays date and time
  var now = new Date().getTime();

  // Find the distance between now and the count down date
  var distance = countDownDate - now;

  // Time calculations for days, hours, minutes and seconds
  var days = Math.floor(distance / (1000 * 60 * 60 * 24));
  var hours = Math.floor((distance % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60));
  var minutes = Math.floor((distance % (1000 * 60 * 60)) / (1000 * 60));
  var seconds = Math.floor((distance % (1000 * 60)) / 1000);

  // Display the result in the element with id="demo"
  document.getElementById("demo").innerHTML = days + "d " + hours + "h "
  + minutes + "m " + seconds + "s ";

  // If the count down is finished, write some text 
  if (distance < 0) {
    clearInterval(x);
    document.getElementById("demo").innerHTML = "Closing Soon..";
  }
}, 1000);
</script>
					
					
					<h4 style="color:purple;">Please use Google Chrome Browser Only.</h4></center>
    </div>
	
	
	
	</div>
	

		

		

				</div>
				
				<div class=row">
					 
		
				</div>
			
			
				
			
				
				
<?php
	}
	?>
</div>
</div>
  <div data-role="dialog" id="successpop">
	<div data-role="header">
		<h1 class='nd-title' id="poptitle">SUCCESS.</h1>
	</div>

	<div data-role="content">
	    <p id="alertmessage"></p>
	  <!-- <a href="#" id="printappbtn" data-role="button" target="_blank" data-inline="true" class="ui-btn ui-btn-primary ui-btn-raised clr-green"><i class='zmdi zmdi-print'></i> Print Form</a> -->
	    <a href="#" onclick="location.reload();" data-rel="back" data-role="button" data-inline="true" class="ui-btn ui-btn-raised  ui-btn-primary"><i class='zmdi zmdi-cancel'></i>Close</a>
	</div>
</div>


 <div data-role="page" id="entrypage" data-url="entrypage">
	<div data-role="header" style="overflow:hidden; text-align:center;">
	<h3 style="text-align:center;"><?php echo $configs['eventtitle']; ?></h3>
<h1 style="text-align:center;" id="formhead">Entry Form</h1>
 <!-- <div data-role="navbar">
        <ul>
            <li><a href="index.php#page1">Entries</a></li>
            <li><a href="logout.php">Logout <?php echo $_SESSION["username"] ?></a></li>
        </ul>
    </div><!-- /navbar -->
	
      </div><!-- /header -->
	
<div data-role="main" class="ui-content">
 

    <div class="nd2-no-menu-swipe">

			
			<div  class="ui-content" data-inset="false">


				<form id="entryform">


				 <div class="row">

		<div class="col-xs-12 col-sm-6 col-md-4">

       				<div class="box">

						<label for="sname">FullName (Given Name - Middle Name - Surname)<br/>As per DOB Certificate / Passport:</label>
                        <input required="required" type="text" name="sname" id="sname" value="" data-clear-btn="true" placeholder="Type Skater Name here...">
                        <label for="dob">Date of Birth: (Don't use Slash "/")</label>
                        <input required="required" type="date" name="dob" id="dob" value="" data-clear-btn="true" placeholder="" onchange="calcagegroup();">
                         
                         <label for="age">Age :</label>
                          <input required="required" type="text" name="aget" id="aget" value="" data-clear-btn="true" placeholder=""  readonly>
                           <input required="required" type="hidden" name="age" id="age" value="" data-clear-btn="true" placeholder="">
                         <label for="ag">Age Group:</label>
                          <input required="required" type="text" name="ag" id="ag" value="" data-clear-btn="true" placeholder=""  readonly>
                            <input required="required" type="hidden" name="agorder" id="agorder" value="" data-clear-btn="true" placeholder="">

                          <fieldset data-role="controlgroup" data-type="horizontal" data-mini="true">
                            <legend>Gender</legend>
                                 <label for="gender1">Male</label>
                            <input type="radio" name="gender" id="gender1" value="Male" checked="checked">
                            <label for="gender2">Female</label>
                            <input type="radio" name="gender" id="gender2" value="Female">
                            </fieldset>
                                <label for="phone">Phone / Mobile :</label>
                        <input required="required" type="text" name="phone" id="phone" value="" data-clear-btn="true" placeholder="" >
                        <label for="clubname">District:</label>
						<select  name="clubname" id="clubname" required="required" data-theme="a" data-clear-btn="true">
						<?php
						$uname= $_SESSION['username'];
						if($uname=="secretary")
						{			  
						  	echo'<option>Bagalkot</option>
<option>Bangalore Urban</option>
<option>Bangalore Rural</option>
<option>Belgaum</option>
<option>Bellary</option>
<option>Bidar</option>
<option>Bijapur</option>
<option>Chamarajanagar</option>
<option>Chikballapur</option>
<option>Chikmagalur</option>
<option>Chitradurga</option>
<option>Dakshina Kannada</option>
<option>Davanagere</option>
<option>Dharwad</option>
<option>Gadag</option>
<option>Gulbarga</option>
<option>Hassan</option>
<option>Haveri</option>
<option>Kodagu</option>
<option>Kolar</option>
<option>Koppal</option>
<option>Mandya</option>
<option>Mysore</option>
<option>Raichur</option>
<option>Ramanagara</option>
<option>Shimoga</option>
<option>Tumakuru</option>
<option>Udupi</option>
<option>Uttara Kannada</option>
<option>Yadgir</option>

';
					
						}
						else
						{		  
							echo '<option>'.$uname.'</option>';

						}
						
						?>
					    </select>	        
                            <label for="address">Fathername & Address:</label>
                          <input type="text" name="address" id="address" value="" data-clear-btn="true" placeholder="">
						  
						   <label for="school">School / College Name & Address</label>
                          <input type="text" name="school" id="school" value="" data-clear-btn="true" placeholder="">
					<!--	   <label for="syllabus">Syllabus</label>
                        <select  name="syllabus" id="syllabus"  data-theme="a" data-clear-btn="true">
<option> </option>
<option>STATE</option>
<option>CBSE</option>
<option>ICSE</option>
<option>ISE</option>
</select>  -->
						  
                           <label for="blood">Blood Group</label>
                          <input type="text" name="blood" id="blood" value="" data-clear-btn="true" placeholder="">

					</div>
					<div class="box">
					<!-- <label for="uploadedphoto">Uploaded Photo</label>
					<img  id="uploadedphoto" name="uploadedphoto" height="240px" /> -->
					</div>
	<!--photo upload start -->				
					 <div class="box">
	<br/><br/>
     <div class="image-editor">
	   
       <div class="ui-field-contain">
    <label for="photofile">Select Photo (JPG OR PNG):</label>
     <input type="file" name="photofile" id="photofile" class="cropit-image-input" accept="image/*" required="required" />
</div>
                    <!--      <input type="file" name="photofile" id="photofile" class="cropit-image-input ui-hidden-accessible" style=" visibility: hidden; display:none;" /> -->
						  
						 
        <div class="cropit-preview box" style=" margin: 0 auto;" placeholder="Recent PP" > 

		</div>
        <div class="ui-field-contain">
		
    <label for='range1a'>Resize image</label>
       <input type='range' name='range1a' id='range1a' class="cropit-image-zoom-input" min='0' max='2' value='0' />
 
		</div>
		
       <!-- <input type="range" class="cropit-image-zoom-input"> -->
	    <div class="ui-field-contain">
		   <label for='rotate1'>Rotate</label>
       <a name='rotate1' id="photorotccw" class="rotate-ccw ui-btn ui-btn-inline ui-mini"><i class="zmdi-rotate-left zmdi zmd-2x" ></i></a>
      <a name='rotate1'  id="photorotcw" class="rotate-cw ui-btn ui-btn-inline ui-mini"><i class="zmdi-rotate-right zmdi zmd-2x"></i></a>
        <input type="hidden" name="photo-data" id="photo-data" class="hidden-image-data" />
      </div>
	  
      </div>
	  
	

	 
	
	
</div>

<!--endo of photo & dob upload -->
		</div>
        
        <div class="col-xs-12 col-sm-6 col-md-4">
<div class="box">
<fieldset data-role="controlgroup" data-type="vertical" data-mini="true">
                            <legend>Main Discipline :</legend>
							
						 <!--	<input type="radio" name="skatertype" id="skatertype3"  onclick="calcagegroup();" value="Under8-Quad"  onchange="setraces();" >
                            <label for="skatertype3">Below 6 & 6 to 8 -Quad</label>
							   <input type="radio" name="skatertype" id="skatertype14"  onclick="calcagegroup();" value="Under8-Inline"  onchange="setraces();" >
                            <label for="skatertype14">Below 6 & 6 to 8 -Inline</label>
                           <input type="radio" name="skatertype" id="skatertype4"  onclick="calcagegroup();" value="Tenacity"  onchange="setraces();" >
                            <label for="skatertype4">Tenacity (All Agegroups) </label>  -->
							
                            <input type="radio" name="skatertype" id="skatertype1"  onclick="calcagegroup();" value="Speed-Quad"  onchange="//setraces();">
                            <label for="skatertype1">Speed-Quad</label>
                            <input type="radio" name="skatertype" id="skatertype2"  onclick="calcagegroup();" value="Speed-Inline"  onchange="//setraces();">
                            <label for="skatertype2">Speed-Inline</label>
                       
														<input type="radio" name="skatertype" id="skatertype5"  onclick="calcagegroup();" value="Artistic"  onchange="setraces();" >
                            <label for="skatertype5">Artistic</label>
							
							<input type="radio" name="skatertype" id="skatertype6"  onclick="calcagegroup();" value="Roller-Hockey"  onchange="setraces();" >
                            <label for="skatertype6">Roller Hockey</label>
							
							<input type="radio" name="skatertype" id="skatertype7"  onclick="calcagegroup();" value="Inline-Hockey"  onchange="setraces();" >
                            <label for="skatertype7">Inline Hockey</label>
							<input type="radio" name="skatertype" id="skatertype12" onclick="calcagegroup();" value="Inline-Freestyle"  onchange="setraces();" >
                            <label for="skatertype12">Inline Freestyle</label>
						<!--	<input type="radio" name="skatertype" id="skatertype8" onclick="calcagegroup('2');" value="Alpine"  onchange="setraces();" >
                            <label for="skatertype8" >Alpine</label>
							<input type="radio" name="skatertype" id="skatertype9" onclick="calcagegroup('2');" value="Downhill"  onchange="setraces();" >
                            <label for="skatertype9">Downhill</label>
							<input type="radio" name="skatertype" id="skatertype10" onclick="calcagegroup('2');" value="Roller-Derby"  onchange="setraces();" >
                            <label for="skatertype10">Roller Derby</label>
							<input type="radio" name="skatertype" id="skatertype11" onclick="calcagegroup('2');" value="Roller-Freestyle"  onchange="setraces();" >
                            <label for="skatertype11">Roller Freestyle</label>
							
							<input type="radio" name="skatertype" id="skatertype13"  onclick="calcagegroup('2');" value="Skateboarding"  onchange="setraces();" >
                            <label for="skatertype13">Skateboarding</label>  -->
							
							
							
							
                        </fieldset>



					</div>
					
					<div id="otherdisciplines">
<p>Additional Discipline for "Above 12" Age Group. </p>
	<fieldset data-role="controlgroup">
  <legend>Other Disciplines (DEMO)</legend>
  <input type="checkbox" name="alpine" id="alpine" value="P">
  <label for="alpine">Inline Alpine</label>
   <input type="checkbox" name="downhill" id="downhill" value="P" >
  <label for="downhill">Inline Downhill </label>
  <input type="checkbox" name="rollerderby" id="rollerderby" value="P">
  <label for="rollerderby">Roller Derby </label>
  <input type="checkbox" name="rollerfreestyle" id="rollerfreestyle" value="P">
  <label for="rollerfreestyle">Roller Freestyle </label>
 <!--put type="checkbox" name="inlinefreestyle" id="inlinefreestyle" >
  <label for="inlinefreestyle">Inline Freestyle</label> -->
  <input type="checkbox" name="skateboarding" id="skateboarding" value="P">
  <label for="skateboarding">Skateboarding </label>
    <input type="checkbox" name="precision" id="precision" value="P">
  <label for="precision">Precision </label>
    <!--  <input type="checkbox" name="showgroup" id="showgroup" value="P">
  <label for="showgroup">Show Group </label> -->

  
   
</fieldset>
</div> 


<div class="box">
  <!--dob img -->
	   <div id="image-editor2">
	  
       <div class="ui-field-contain">
    <label for="photofile1">Select Scanned DOB Proof (JPG or PNG) :</label>
     <input type="file" name="photofile1" id="photofile1" class="cropit-image-input" required="required" accept="image/*" />
</div>
                    <!--      <input type="file" name="photofile" id="photofile" class="cropit-image-input ui-hidden-accessible" style=" visibility: hidden; display:none;" /> -->
						  
		 			 
        <div class="cropit-preview box" style=" margin: 0 auto; background-color:#ccc; background-image:none !important;" placeholder="DOB Proof" > 

		</div>
        <div class="ui-field-contain">
		
    <label for='range1ab'>Resize image</label>
       <input type='range' name='range1ab' id='range1ab' class="cropit-image-zoom-input1" min='0' max='2' value='0' />
 
		</div> 
		
       <!-- <input type="range" class="cropit-image-zoom-input1"> -->
	    <div class="ui-field-contain">
		   <label for='rotate'>Rotate</label>
       <a name='rotate' id="dobrotccw" class="rotate-ccw ui-btn ui-btn-inline ui-mini"><i class="zmdi-rotate-left zmdi zmd-2x" ></i></a>
      <a name='rotate' id="dobrotcw" class="rotate-cw ui-btn ui-btn-inline ui-mini"><i class="zmdi-rotate-right zmdi zmd-2x"></i></a>
        <input type="hidden" name="dob-data" id="dob-data" class="hidden-dob-data" />
      </div>
	  
      </div>
	 <!--end of dob img cropit -->
</div>

</div>
<div class="col-xs-12 col-sm-6 col-md-4">

<div class="box">
	<!--events-->					
<div id="sqraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Speed-Quad Events</legend>
 <!--  <p>Please Select (Maximum) <br/>3 out of 4Races <br/></p> -->
  <input type="checkbox" name="rink1" id="rink1" value="P" >
  <label for="rink1">Rink - I (500 M)</label>
   <input type="checkbox" name="rink2" id="rink2" value="P">
  <label for="rink2">Rink - II (1000 M)</label>

   <input type="checkbox" name="road1" id="road1" value="P">
  <label for="road1">Road - I (1 Lap)</label>
  <input type="checkbox" name="road2" id="road2" value="P">
  <label for="road2">Road - II (1500 / 3000 M)</label>
  
    

</fieldset>
</div>
<div id="siraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Speed-Inline Events</legend>
  
  <!--<p>Please Select (Maximum) <br/>3 out of 6 Races for 8 to 12 Age Group<br/>and a skater can additionally select Relay .<br/><br/>4 out of 8 Races for 12 to 16 & Above 16 Age Groups and a skater can additionally select Relay & Marathon.<br/> </p> -->
    <input type="checkbox" name="rink3" id="rink3" value="P">
  <label for="rink3">Rink - III (500 M)</label>
  <input type="checkbox" name="rink4" id="rink4" value="P">
  <label for="rink4">Rink - IV (1000 M)</label>
  
    <input type="checkbox" name="p2p" id="p2p" value="P">
  <label for="p2p">Point to Point + Eli. - Rink (10000 M) </label>
    
       <input type="checkbox" name="elim" id="elim" value="P">
  <label for="elim">Elimination - Rink (5000 / 15000 M)</label>
   
      <input type="checkbox" name="road3" id="road3" value="P">
  <label for="road3">Road - III (100 M)</label>
<input type="checkbox" name="road4" id="road4" value="P">
  <label for="road4">Road - IV (1 Lap)</label>
 <input type="checkbox" name="road5" id="road5" value="P">
  <label for="road5">Road - V (3000 M)</label>
  
     <input type="checkbox" name="p2prd" id="p2prd" value="P">
  <label for="p2prd">Point to Point - Road (10000 M)</label>
  
    <input type="checkbox" name="elimrd" id="elimrd" value="P">
  <label for="elimrd">Elimination - Road (20000 M)</label>
  <input type="checkbox" name="relay" id="relay" value="P">
  <label for="relay" style="color:blue;">Relay (3000 M) (Must have 3 Skaters)</label>
    <input type="checkbox" name="marathon" id="marathon" disabled="true" value="P">
  <label for="marathon" style="color:blue;">Marathon (42 KM)</label>
  

</fieldset>
</div>
<div id="u8qraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Under8-Quad Events</legend>
  <input type="checkbox" name="u8race1q" id="u8race1q" value="P" >
  <label for="u8race1q">Race - I</label>
   <input type="checkbox" name="u8race2q" id="u8race2q" value="P">
  <label for="u8race2q">Race - II</label>
  

</fieldset>
</div>

<div id="u8iraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Under8-Inline Events</legend>
  <input type="checkbox" name="u8race1i" id="u8race1i" value="P" >
  <label for="u8race1i">Race - I</label>
   <input type="checkbox" name="u8race2i" id="u8race2i" value="P">
  <label for="u8race2i">Race - II</label>
  

</fieldset>
</div>


<div id="tenraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Tenacity Events</legend>
  <input type="checkbox" name="tenrace1" id="tenrace1" value="P">
  <label for="tenrace1">Race - I</label>
   <input type="checkbox" name="tenrace2" id="tenrace2" value="P">
  <label for="tenrace2">Race - II</label>
   
</fieldset>
</div>

<div id="artisticraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Artistic Events</legend>
  <p>Please select maximum 4 out 6 events.</p>
  <input type="checkbox" name="figure" id="figure" value="P">
  <label for="figure">Figure</label>
   <input type="checkbox" name="free" id="free" value="P">
  <label for="free">Free</label>
    <input type="checkbox" name="pair" id="pair" value="P">
  <label for="pair">Pair</label>
  
  
  <label for="pairpartnername">Partner Name : </label>
  <input type="text" name="pairpartnername" id="pairpartnername" placeholder="Type Partner Name" value="" />
  <label for="pairpartnerag">Partner Age Group : </label>
  <input type="text" name="pairpartnerag" id="pairpartnerag" placeholder="Type Partner Age Group" value="" />
  
  
    <input type="checkbox" name="solodance" value="P" id="solodance">
  <label for="solodance">Solo Dance</label>
  
    <input type="checkbox" name="coupledance" id="coupledance" value="P">
  <label for="coupledance">Couple Dance</label>
  
  <label for="coupledancepartnername">Partner Name : </label>
   <input type="text" name="coupledancepartnername" id="coupledancepartnername" placeholder="Type Partner Name" value="" />
   <label for="coupledancepartnerag">Partner Age Group : </label>
  <input type="text" name="coupledancepartnerag" id="coupledancepartnerag" placeholder="Type Partner Age Group" value="" />
  
    <input type="checkbox" name="inlinefree" id="inlinefree"  value="P">
  <label for="inlinefree">Inline Free</label>
  
  <input type="checkbox" name="quartet" id="quartet"  value="P">
  <label for="quartet">Quartet</label>
  
   
</fieldset>
</div>

<div id="inlinefreestyleraces" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Inline Freestyle Events</legend>
  <input type="checkbox" name="classicslalom" id="classicslalom"  value="P">
  <label for="classicslalom">Classic Slalom</label>
   <input type="checkbox" name="speedslalom" id="speedslalom"  value="P">
  <label for="speedslalom">Speed Slalom</label>
  
  
   
</fieldset>
</div>



<div id="hockeyraces1" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Roller Hockey Events</legend>
  <input type="checkbox" name="rollerhockey1" id="rollerhockey1"  value="P">
  <label for="rollerhockey1">Roller Hockey</label>
 <!--  <input type="checkbox" name="inlinehockey" id="inlinehockey">
  <label for="inlinehockey">Inline Hockey</label> -->
  
  
   
</fieldset>
</div>


<div id="hockeyraces2" style="display:none;">
	<fieldset data-role="controlgroup">
  <legend>Inline Hockey Events</legend>
 <!--   <input type="checkbox" name="rollerhockey" id="rollerhockey">
  <label for="rollerhockey">Roller Hockey</label> -->
   <input type="checkbox" name="inlinehockey1" id="inlinehockey1"  value="P">
  <label for="inlinehockey1">Inline Hockey</label>
  
  
   
</fieldset>
</div>

<div id="hockeyadd" style="display:none;">
	<!--<fieldset data-role="controlgroup">-->
   <label for="hockeyplayertype">Position</label>
<select name="hockeyplayertype" id="select-choice-1b" data-native-menu="true">
    <option value="Player">Player</option>
    <option value="Captain">Captain</option>
    <option value="GoalKeeper1">GoalKeeper1</option>
    <option value="GoalKeeper2">GoalKeeper2</option>
    <option value="GoalKeeper3">GoalKeeper3</option>
</select>
  <label for="jerseyno">Jersey No :</label>
  <input type="text" name="jerseyno" id="jerseyno" value="" data-clear-btn="true" placeholder="Jersey Number">

  	<!-- </fieldset> -->

</div>




	<!--events end-->	
	<!--events end-->	
</div>



					</div>
                    
                    
</div>
<div class="row">
<div class="col-xs">
<p align='justify'></p>
</div>
</div>

<div class="row">
<div class="col-xs">
<input type="hidden" value="" name="photourl" id="photourl"/>
<input type="hidden" value="" name="applno" id="applno"/>
<input type="hidden" value="" name="mode" id="mode"/>

 <!--  <input type="checkbox" name="regstatus" id="regstatus">
  <label for="regstatus">Registered for 1st All Karnataka Invitational Speed Skating Tournament May 2018 at Perumbavur </label> -->


<input type="submit" id="submitbutton" value="I Agree to KRSA Rules & Submit" class="ui-btn clr-btn-green" /> <br/>
<img  id="uploadeddob" name="uploadeddob" />

</div>

</div>


			</form>


			</div>

		</div>
        
        
        
        
    
    
    
    
    </div>

	    </div>
		

<div data-role="page" id="musicupload" data-url="musicupload">  

	<div data-role="header" style="overflow:hidden; text-align:center;">
<h1 style="text-align:center;" id="formhead">UPLOAD MUSIC FILES (MP3)</h1>

	
      </div><!-- /header -->
 
 

<div data-role="main" class="ui-content">
<div class="box row">
<div class="col-xs">
<form name="musicform"  action="upload.php" method="post"  >
  <div style="padding:10px 20px;">
	<div class="ui-field-contain">
            <label for="skaterappno">Application No</label>
            <input type="text" name="appno" id="appno" value="" placeholder="Application No" data-theme="a">
			
			</div>
			
				<div class="ui-field-contain">
                <label for="musicdob">Date of Birth: (Don't use Slash "/")</label>
                        <input required="required" type="date" name="musicdob" id="musicdob" value="" data-clear-btn="true" placeholder="">
			
			</div>
			
	<div class="ui-field-contain">
	<legend>Free</legend>
            <label for="freeshortmusic">Free Short (Not Applicable for 8 to 12)</label>
            <input type="file" name="freeshortmusic" id="freeshortmusic" value="" placeholder="freeshortmusic" data-theme="a">
			</div>
				<div class="ui-field-contain">
			   <label for="freelongmusic">Free Long</label>
            <input type="file" name="freelongmusic" id="freelongmusic" value="" placeholder="freelongmusic" data-theme="a">
			</div>
			
				
	<legend>Inline Free</legend>
	<div class="ui-field-contain">
            <label for="inlinefreeshortmusic">Inline Free Short (Not Applicable for 8 to 12)</label>
            <input type="file" name="inlinefreeshortmusic" id="inlinefreeshortmusic" value="" placeholder="inlinefreeshortmusic" data-theme="a">
			</div>
				<div class="ui-field-contain">
			   <label for="inlinefreelongmusic">Inline Free Long</label>
            <input type="file" name="inlinefreelongmusic" id="inlinefreelongmusic" value="" placeholder="inlinefreelongmusic" data-theme="a">
			</div>
			
			<legend>Pair Skating</legend>
	<div class="ui-field-contain">
            <label for="pairshortmusic">Pair Short (Not Applicable for 8 to 12)</label>
            <input type="file" name="pairshortmusic" id="pairshortmusic" value="" placeholder="pairshortmusic" data-theme="a">
			</div>
				<div class="ui-field-contain">
			   <label for="pairlongmusic">Pair Long</label>
            <input type="file" name="pairlongmusic" id="pairlongmusic" value="" placeholder="pairlongmusic" data-theme="a">
			</div>
			
			<legend>Solo Dance</legend>
	<div class="ui-field-contain">
            <label for="compulsarydancesolo">Compulsary Dance Track No. (Only for 8 to 12)</label>
            <input type="text" name="compulsarydancesolo" id="compulsarydancesolo" value="" placeholder="compulsarydancesolo" data-theme="a">
			</div>
				<div class="ui-field-contain">
			   <label for="styledancesolo">Solo Style Dance (Not Applicable for 8 to 12)</label>
            <input type="file" name="styledancesolo" id="styledancesolo" value="" placeholder="styledancesolo" data-theme="a">
			</div>
			<div class="ui-field-contain">
			   <label for="freedancesolo">Solo Free Dance  (Not Applicable for 8 to 12)</label>
            <input type="file" name="freedancesolo" id="freedancesolo" value="" placeholder="freedancesolo" data-theme="a">
			</div>
			
				<legend>Couple Dance</legend>
	<div class="ui-field-contain">
            <label for="compulsarydancecouple">Compulsary Dance Track No. (Only for 8 to 12)</label>
            <input type="text" name="compulsarydancecouple" id="compulsarydancecouple" value="" placeholder="compulsarydancecouple" data-theme="a">
			</div>
				<div class="ui-field-contain">
			   <label for="styledancecouple">Couple Style Dance (Not Applicable for 8 to 12)</label>
            <input type="file" name="styledancecouple" id="styledancecouple" value="" placeholder="styledancecouple" data-theme="a">
			</div>
			<div class="ui-field-contain">
			   <label for="freedancecouple">Couple Free Dance  (Not Applicable for 8 to 12)</label>
            <input type="file" name="freedancecouple" id="freedancecouple" value="" placeholder="freedancecouple" data-theme="a">
			</div>
			
			<div class="ui-field-contain">
            <button type="submit" class="ui-btn ui-corner-all ui-shadow clr-btn-green ui-btn-icon-left ui-icon-check">UPLOAD</button>
				</div>
        </div>
    </form>
	
	</div>
</div>

</div>

</div>


 <div data-role="page" id="teammanager" data-url="teammanager">  

	<div data-role="header" style="overflow:hidden; text-align:center;">
<h1 style="text-align:center;" id="formhead">Update Team Managers</h1>
  <div data-role="navbar">
        <ul>
            <li><a href="index.php#page1">Entries</a></li>
            <li><a href="logout.php">Logout <?php echo $_SESSION["username"] ?></a></li>
        </ul>
    </div><!-- /navbar -->
	
      </div><!-- /header -->
 
 

<div data-role="main" class="ui-content">
<?php
	$club=$_SESSION["username"];
	
	if($club !="")
	{
	//	echo $club;
		?>
<!--content start -->

<script>
$(function(){
	//acknowledgement message
    var message_status = $("#status");
    $("td[contenteditable=true]").blur(function(){
        var field_userid = $(this).attr("id") ;
        var value = $(this).text() ;
        $.post('ajax.php' , field_userid + "=" + value, function(data){
            if(data != '')
			{
				message_status.show();
				message_status.text(data);
				//hide the message
				//setTimeout(function(){message_status.hide()},1000);
			}
        });
    });
	
	 $("teammsave").click(function(){
      //  var field_userid = $(this).attr("id") ;
     //   var value = $(this).text() ;
      //  $.post('ajax.php' , field_userid + "=" + value, function(data){
         //   if(data != '')
		//	{
			//	message_status.show();
			//	message_status.text(data);
				//hide the message
			//	setTimeout(function(){message_status.hide()},3000);
				
				message_status.show();
				message_status.text("Saved");
				setTimeout(function(){message_status.hide()},3000);
			//}
       // });
    });
	
	
	 jQuery('.s_download').click(function(){
			var semail = jQuery("#itzurkarthi_email").val();
			if(semail == '')
			{
				alert('Enter Email');
				return false;
			}
			var str = "sub_email="+semail
			jQuery.ajax({
				type: "POST",
				url: "download.php",
				data: str,
				cache: false,
				success: function(htmld){
						jQuery('#down_update').html(htmld);
				}
			});
	  });
	
});
</script>
<style>
table.zebra-style {
	font-family:"Lucida Sans Unicode", "Lucida Grande", Sans-Serif;
	text-align:left;
	border:1px solid #ccc;
	margin-bottom:25px;
	width:90%
}
table.zebra-style th {
	color: #444;
	font-size: 13px;
	font-weight: normal;
	padding: 10px 8px;
}
table.zebra-style td {
	color: #777;
	padding: 8px;
	font-size:13px;
	border:1px solid black;
}
table.zebra-style tr.odd {
	background:#f2f2f2;
}

.container {

}
#status { padding:10px; background:#88C4FF; color:#000; font-weight:bold; font-size:12px; margin-bottom:10px; display:none; width:90%; }
</style>


<div class="container"><br>

  <div id="status"></div>
  
<table class="table zebra-style">
    <thead>
      <tr>
        <th>#</th>
        <th>State / U.T.</th>
		<th>Discipline</th>
		<th>TeamManager</th>
		<th>TM's - Phone</th>
		<th>LadyTeamManager</th>
		<th>LadyTM's - Phone</th>
		<th>Coach</th>
		<th>Coach's Phone</th>
		
              </tr>
    </thead>
    <tbody>
	
	<?php
	
		include "config.php";
	$team=$club;
	$databaseQuery = 'SELECT * FROM `teammagers` WHERE `Team`="'.$con->real_escape_string($team).'"';
	$result3 = mysqli_query($con,$databaseQuery) or die('Query failed: ' . mysqli_error());
		while($row = mysqli_fetch_array($result3))
  {
	   $ID=trim($row["ID"]);
	   $team=trim($row["Team"]);
	     $discipline=trim($row["Discipline"]);
		   $teammanager=trim($row["TeamManager"]);
		     $tmphone=trim($row["TMPhone"]);
			   $ladyteammanager=trim($row["LadyTeamManager"]);
			     $ladytmphone=trim($row["LadyTMPhone"]);
				   $coach=trim($row["Coach"]);
				     $coachphone=trim($row["CoachPhone"]);
					 
	  echo'    <tr ><td>1</td><td id="Team:'.$ID.'" contenteditable="false">'.$team.'</td><td id="Discipline:'.$ID.'" contenteditable="false">'.$discipline.'</td><td id="TeamManager:'.$ID.'" contenteditable="true">'.$teammanager.'</td><td id="TMPhone:'.$ID.'" contenteditable="true">'.$tmphone.'</td><td id="LadyTeamManager:'.$ID.'" contenteditable="true">'.$ladyteammanager.'</td><td id="LadyTMPhone:'.$ID.'" contenteditable="true">'.$ladytmphone.'</td><td id="Coach:'.$ID.'" contenteditable="true">'.$coach.'</td><td id="CoachPhone:'.$ID.'" contenteditable="true">'.$coachphone.'</td> </tr> ';
  }
	
	?>
     
    </tbody>
 </table>
 <br>
 <button class="ui-btn" id="teammsave"> SAVE </button>
<br>


<br>



</div>

<!-- content end -->
<?php
	}
	else
	{
		loginbox();
	}
	?>
</div>
</div>

 

  </body>
</html>