
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="fr" lang="fr">

<head>
    <meta http-equiv="Content-Type" content="text/html; charset=" />
    <meta http-equiv="Content-Script-Type" content="text/javascript" />
    <meta http-equiv="Content-Language" content="fr" />

<title>Calendrier par club</title>
<link href="/css/baskethainaut_pub.css" rel="stylesheet" type="text/css" />
<script language="javascript" type="text/javascript" src="/js/ajaxv2.js"></script>
<style type="text/css">
<!--
body {
	background-color: #FFFFDD;
}
-->
</style></head>

<body>
<form id="frmNone" name="frmNone">
<div id="divHourglass" class="centered_div" style="zIndex:100;display:none"><img src="/images/uninstant_ani.gif"></div>

<table border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td colspan="2" class="pTitrePage">Saison 2009-2010 : Calendrier par club</td>
  </tr>
  <tr>
    <td colspan="2">&nbsp;</td>
  </tr>
  <tr>
    <td class="txtDetail">1. Choisissez le mode de visualisation:</td>
    <td><span class="txtDetail">
      <input name="radioViewMode" type="radio" id="radioViewMode" value="chrono" checked="checked" />
Par ordre chronologique des rencontres 
	<input type="radio" name="radioViewMode" id="radioViewMode" value="serie" />
Par s&eacute;rie</span></td>
  </tr>
  <tr>
    <td width="333" class="txtDetail">2. Veuillez s&eacute;lectionner un club: </td>
    <td width="561"><span id="divCboClubs"></span>
    <input type="button" name="btnShowCalendarByClub" id="btnShowCalendarByClub" value="Afficher le calendrier" /></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td class="txtDetail">&nbsp;</td>
  </tr>
  <tr>
    <td colspan="2"><div id="divCalendrierParClub"></div></td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>
</form>
<script language="javascript" type="text/javascript">
	
	var objBtnShowCalendar = document.getElementById('btnShowCalendarByClub');
	objBtnShowCalendar.onclick = function() {
		var objCboClubs = document.getElementById('cboClubs');
		if(objCboClubs.selectedIndex != 0){
			fShowHourGlass();
			var vClubId = objCboClubs.options[objCboClubs.selectedIndex].value;
			var strViewMode = fGetCheckedRadioValue(document.frmNone.radioViewMode);
			switch (strViewMode){
			
				case 'chrono' :
					doAJAXCallv2('calendrier_par_club5_fGetCalendrierByClub.asp', 'POST', 'clubid=' + vClubId + '&viewmode=' + strViewMode, fShowResponseAjax,'divCalendrierParClub');
					break
				case 'serie' :
					doAJAXCallv2('calendrier_par_club4_fGetCalendrierByClub.asp', 'POST', 'clubid=' + vClubId + '&viewmode=' + strViewMode, fShowResponseAjax,'divCalendrierParClub');
					break
			}
		}
	}
	
	function fGetCheckedRadioValue(colRadio){
		//alert(colRadio);
		for (var i = 0; i < colRadio.length; i++)  {
			if (colRadio[i].checked)  {
				return colRadio[i].value;
			}
		}
	}
	
	function fShowCboClubs(){
		fShowHourGlass();
		doAJAXCallv2('/aspcommon/ajax_fGetDDL.asp', 'POST', "vtarget=clubs_list_p1&vtargetParam=|ma|", fShowResponseAjax,'divCboClubs');
	}

	function fShowResponseAjax(objXML,strDiv){
		var response = objXML.responseText;
		var divTarget = document.getElementById(strDiv);
		divTarget.innerHTML = response;
		fHideHourGlass();
	}		

	function fShowHourGlass(){
		document.getElementById('divHourglass').style.display = 'inline';
	}	
	
	function fHideHourGlass(){
		document.getElementById('divHourglass').style.display = 'none';
	}		
	
	fShowCboClubs();
</script>
</body>
</html>
