Index: trunk/admin/modules/Elezioni/ele_associazioni.php
===================================================================
--- trunk/admin/modules/Elezioni/ele_associazioni.php	(revision 317)
+++ trunk/admin/modules/Elezioni/ele_associazioni.php	(revision 318)
@@ -194,4 +194,5 @@
 			if($rescomu->rowCount())
 				list($fasciacom)=$rescomu->fetch(PDO::FETCH_NUM);
+			else $fasciacom=0;
 		} else $fasciacom=0;
 		$sql="SELECT id_conf, descrizione from ".$prefix."_ele_conf order by id_conf desc";
Index: trunk/admin/modules/Elezioni/ele_controlli.php
===================================================================
--- trunk/admin/modules/Elezioni/ele_controlli.php	(revision 317)
+++ trunk/admin/modules/Elezioni/ele_controlli.php	(revision 318)
@@ -278,4 +278,9 @@
 		##############################
 	$err=0;
+	$stato=0;
+	$sql="select count(0) from ".$prefix."_ele_controlli where tipo='lista' and id_sez='$id_sez' "; 
+	$res = $dbi->prepare("$sql");
+	$res->execute();
+	if($res->rowCount()) $stato=1;
 	$tipo='lista';
 	$sql="SELECT genere FROM ".$prefix."_ele_tipo as t1 left join ".$prefix."_ele_consultazione as t2 on t1.tipo_cons=t2.tipo_cons where id_cons_gen='$id_cons_gen'";
@@ -283,9 +288,13 @@
 	$res->execute();
 	list($genere)=$res->fetch(PDO::FETCH_NUM);
-	$sql="SELECT preferenze,disgiunto,solo_gruppo,id_fascia FROM ".$prefix."_ele_cons_comune where id_cons='$id_cons'";
-	$res = $dbi->prepare("$sql");
-	$res->execute();
-	list($prefs,$disg,$solog,$fascia)=$res->fetch(PDO::FETCH_NUM);
-	if($id_lista){
+	$sql="SELECT preferenze,disgiunto,solo_gruppo,id_fascia,id_conf FROM ".$prefix."_ele_cons_comune where id_cons='$id_cons'";
+	$res = $dbi->prepare("$sql");
+	$res->execute();
+	list($prefs,$disg,$solog,$fascia,$idconf)=$res->fetch(PDO::FETCH_NUM);
+	$sql="SELECT supdisgiunto FROM ".$prefix."_ele_conf where id_conf='$idconf'";
+	$res = $dbi->prepare("$sql");
+	$res->execute();
+	list($disglg)=$res->fetch(PDO::FETCH_NUM);
+	if($id_lista && $stato==0){
 		$err=controllo_votic($id_cons,$id_sez,$id_lista);
 		$tipo='lista';
@@ -315,5 +324,5 @@
 				$err=controllo_votic($id_cons,$id_sez,$idg);
 				if($err){ $tipo='lista'; $id_lista=$idg; break; }
-					$sql="SELECT sum(voti), sum(nulli_lista),sum(solo_lista) FROM ".$prefix."_ele_voti_lista where id_sez='$id_sez' and id_lista='$idg'";
+				$sql="SELECT sum(voti), sum(nulli_lista),sum(solo_lista) FROM ".$prefix."_ele_voti_lista where id_sez='$id_sez' and id_lista='$idg'";
 				$res2 = $dbi->prepare("$sql");
 				$res2->execute();
@@ -329,5 +338,5 @@
 				}				
 			}
-			if ($validil+$contestatil+$nullil+$bianchi+$vnulli!=$votit and $validil+$contestatil+$nullil+$bianchi+$vnulli>0) {$err=1;$tipo='lista';}
+			if ($totlis!=$validil or ($validil+$contestatil+$nullil+$bianchi+$vnulli!=$votit and $validil+$contestatil+$nullil+$bianchi+$vnulli>0)) {$err=1;$tipo='lista';}
 #			if(($solog && !$disg && $tnl!=$nullil) || $totsl!=$solol) {$err=1;$tipo='lista';}
 		}else{			
@@ -343,6 +352,7 @@
 				while(list($id_lista)=$res2->fetch(PDO::FETCH_NUM)){
 					$err=controllo_votic($id_cons,$id_sez,$id_lista);
-					if($err){ $tipo='lista'; break; }				
+					if($err){ $tipo='lista'; $id_lista=$idg; break; }				
 				}
+				if($err) break;
 				$sql="SELECT sum(voti), sum(nulli_lista),sum(solo_lista) FROM ".$prefix."_ele_voti_lista where id_sez='$id_sez' and id_lista in (select id_lista from ".$prefix."_ele_lista where id_gruppo='$idg')";
 				$res2 = $dbi->prepare("$sql");
@@ -350,5 +360,5 @@
 				$totgru+=$votig;
 				$totsg+=$svg;
-				if($res2->rowCount()){
+				if($res2->rowCount() && !$disglg){
 					list($votil,$nl,$svl)=$res2->fetch(PDO::FETCH_NUM);
 					$totlis+=$votil;
@@ -374,5 +384,4 @@
 
 	if($err){
-		if(!$id_lista) $id_lista=0;
 		$sql="insert into ".$prefix."_ele_controlli value('$id_cons','$id_sez','$tipo','$id_lista')";
 		$res = $dbi->prepare("$sql");
Index: trunk/client/footer.php
===================================================================
--- trunk/client/footer.php	(revision 317)
+++ trunk/client/footer.php	(revision 318)
@@ -6,5 +6,5 @@
 /* info@eleonline.it  luciano@aniene.net rgigli@libero.it               */
 /************************************************************************/
-global $csv,$is_mobile;
+global $csv,$is_mobile,$descr_com;
 if (!$csv)
 piede();
Index: trunk/client/modules/Elezioni/blocchi/gom_affluenze.php
===================================================================
--- trunk/client/modules/Elezioni/blocchi/gom_affluenze.php	(revision 317)
+++ trunk/client/modules/Elezioni/blocchi/gom_affluenze.php	(revision 318)
@@ -63,5 +63,5 @@
 
 			$sql="select sum(t3.voti_complessivi)  from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos";		
-            if ($genere==0){$query.=" and t3.id_gruppo=$id_gruppo";}
+            if ($genere==0){$sql.=" and t3.id_gruppo=$id_gruppo";}
 			$res_aff = $dbi->prepare("$sql");
 			$res_aff->execute();
@@ -71,5 +71,5 @@
 			$sql="select sum(t1.maschi+t1.femmine)  from ".$prefix."_ele_voti_parziale as t3 left join ".$prefix."_ele_sezioni as t1 on t3.id_sez=t1.id_sez left join ".$prefix."_ele_sede as t2 on t1.id_sede=t2.id_sede where t3.id_cons='$id_cons' and t3.data='$data' and t3.orario='$orario' $circos";		
 			
-			if ($genere==0){$query.=" and id_gruppo=$id_gruppo";}
+			if ($genere==0){$sql.=" and id_gruppo=$id_gruppo";}
 			$res1234 = $dbi->prepare("$sql");
 			$res1234->execute();
Index: trunk/client/modules/Elezioni/consiglieri.php
===================================================================
--- trunk/client/modules/Elezioni/consiglieri.php	(revision 317)
+++ trunk/client/modules/Elezioni/consiglieri.php	(revision 318)
@@ -637,5 +637,5 @@
 		$z=0;
 		$arvin[$x][$pos++]=$desliste[$lst]; 
-		$sql = "SELECT concat(substring(concat('0',t1.num_cand),-2),') ',t1.cognome,' ',substring(t1.nome from 1 for 1),'.') as descr,sum(t2.voti) as voti from ".$prefix."_ele_candidati as t1, ".$prefix."_ele_voti_candidati as t2 where t1.id_lista='$id_lista' and t1.id_cand=t2.id_cand GROUP BY descr order by voti desc,num_cand";
+		$sql = "SELECT concat(substring(concat('0',t1.num_cand),-2),') ',t1.cognome,' ',substring(t1.nome from 1 for 1),'.') as descr,sum(t2.voti) as voti from ".$prefix."_ele_candidati as t1, ".$prefix."_ele_voti_candidati as t2 where t1.id_lista='$id_lista' and t1.id_cand=t2.id_cand GROUP BY descr order by voti desc,t1.num_cand";
 $res_can = $dbi->prepare("$sql");
 $res_can->execute();
@@ -738,5 +738,5 @@
 		if(!$premio and $key==$gruppo) $arvin[$x][$pos++]=$desliste[$lst];
 		else $arper[$x][$pos++]=$desliste[$lst]; 
-		$sql = "SELECT concat(substring(concat('0',t1.num_cand),-2),') ',t1.cognome,' ',substring(t1.nome from 1 for 1),'.') as descr,sum(t2.voti) as voti from ".$prefix."_ele_candidati as t1, ".$prefix."_ele_voti_candidati as t2 where t1.id_lista='$id_lista' and t1.id_cand=t2.id_cand GROUP BY descr order by voti desc,num_cand";
+		$sql = "SELECT concat(substring(concat('0',t1.num_cand),-2),') ',t1.cognome,' ',substring(t1.nome from 1 for 1),'.') as descr,sum(t2.voti) as voti from ".$prefix."_ele_candidati as t1, ".$prefix."_ele_voti_candidati as t2 where t1.id_lista='$id_lista' and t1.id_cand=t2.id_cand GROUP BY descr order by voti desc,t1.num_cand";
 $res_can = $dbi->prepare("$sql");
 $res_can->execute();
Index: trunk/client/modules/Elezioni/funzioni.php
===================================================================
--- trunk/client/modules/Elezioni/funzioni.php	(revision 317)
+++ trunk/client/modules/Elezioni/funzioni.php	(revision 318)
@@ -259,5 +259,5 @@
       
   
-	$sql="select id_cons from ".$prefix."_$tab where id_cons='$id_cons' group by id_sez ";
+	$sql="select id_sez  from ".$prefix."_$tab where id_cons='$id_cons' group by id_sez ";
 	$res = $dbi->prepare("$sql");
 	$res->execute();
@@ -288,5 +288,5 @@
 					and t2.id_lista=t3.id_lista
 					and t1.id_gruppo=t3.id_gruppo
-					group by t1.id_gruppo
+					group by t1.id_gruppo, t1.num_gruppo, t1.descrizione
 					order by somma desc";
 				}else{
@@ -295,5 +295,5 @@
         			left join ".$prefix."_ele_voti_gruppo as t2 on (t1.id_gruppo=t2.id_gruppo)
 					where 	t1.id_cons='$id_cons' and t1.id_cons=t2.id_cons $circondt1
-					group by t2.id_gruppo
+					group by t1.id_gruppo, t1.num_gruppo, t1.descrizione
 					order by somma desc";
 			    }
@@ -303,5 +303,5 @@
         		left join ".$prefix."_$tab as t2 on (t1.id_lista=t2.id_lista)
 				where 	t1.id_cons='$id_cons' and t1.id_cons=t2.id_cons
-				group by t2.id_lista
+				group by t1.id_lista, t1.num_lista, t1.descrizione
 				order by somma desc";
 			}
Index: trunk/client/modules/Elezioni/gruppo.php
===================================================================
--- trunk/client/modules/Elezioni/gruppo.php	(revision 317)
+++ trunk/client/modules/Elezioni/gruppo.php	(revision 318)
@@ -204,5 +204,5 @@
 			$res_sez->execute();
 		}
-		if($res_sez) list($tot_sez,$numsezmin,$numsezmax)=$res_sez->fetch(PDO::FETCH_NUM); 
+		if($res_sez->rowCount()) list($tot_sez,$numsezmin,$numsezmax)=$res_sez->fetch(PDO::FETCH_NUM); 
 		$sql="SELECT count(num_sez) from ".$prefix."_ele_sezioni where id_cons=$id_cons";
 		$res_sez = $dbi->prepare("$sql");
@@ -249,5 +249,5 @@
 			if ($circo) $condcirc="and t5.id_circ=$id_circ";
 
-			$sqlvoti="select $tab2, t1.num_cand, concat(t1.cognome,' ', t1.nome), sum(t2.voti),'','','','','' 
+			$sqlvoti="select $tab2, t1.num_cand, concat(t1.cognome,' ', t1.nome) as nome, sum(t2.voti),'','','','','' 
 			from ".$prefix."_ele_candidati as t1, ".$prefix."_ele_voti_candidati as t2, "
 			.$prefix."_ele_sezioni as t3, ".$prefix."_ele_sede as t4, ".$prefix."_ele_circoscrizione as t5
@@ -258,5 +258,5 @@
 			and t3.id_sede=t4.id_sede
 			and t4.id_circ=t5.id_circ $condcirc
-			group by t1.num_cand,$tab3
+			group by t1.num_cand,$tab3, nome
 			order by $tab3,t1.num_cand";
 			$res_voti = $dbi->prepare("$sqlvoti");
@@ -296,5 +296,5 @@
 
 			if ($circo) $condcirc="and t5.id_circ=$id_circ";			
-			if ($tab=="gruppo")
+			if ($tab=="gruppo" or $genere==4)
 					$votigl=" sum(t3.validi),sum(t3.nulli),sum(t3.bianchi),sum(t3.contestati),sum(t3.voti_nulli)";
 			else
@@ -319,5 +319,5 @@
 			
 			
-			group by $t.num_$tab15,$tab3
+			group by $t.num_$tab15,$tab3,$tab2, $t.descrizione
 			order by $tab3,$t.num_$tab15";
 			$res_voti = $dbi->prepare("$sqlvoti");
@@ -509,9 +509,4 @@
 			$voticompl=0;
 			$ominsez=$minsez-1;
-			$sevaltot=0;
-			$senultot=0;
-			$sebiatot=0;
-			$secontot=0;
-			$sevnutot=0;
 			$valar=array();$percar=array();
 		      ////////////////////////////////////////////////////////////////////
@@ -528,4 +523,9 @@
 			$res_numsez->execute();#				for ($z=1;$z<=($offsetsez-$ominsez);$z++) {
 			while($res=$res_numsez->fetch(PDO::FETCH_NUM)) {
+			$sevaltot=0;
+			$senultot=0;
+			$sebiatot=0;
+			$secontot=0;
+			$sevnutot=0;
 				$z=$res[0];
 ##############inserimento percentuale di scrutinio nella sezione
@@ -544,8 +544,5 @@
 				}	
 				elseif($op=="lista_sezione"){
-					if($genere==4)
-						$sqlr="select sum(validi),0 from ".$prefix."_ele_sezioni where id_sez='".$res[1]."'";
-					else
-						$sqlr="select sum(validi),sum(contestati_lista+solo_gruppo+voti_nulli_lista) from ".$prefix."_ele_sezioni where id_sez='".$res[1]."'";
+					$sqlr="select sum(validi),sum(contestati_lista+solo_gruppo+voti_nulli_lista) from ".$prefix."_ele_sezioni where id_sez='".$res[1]."'";
 					$sqlv="select sum(voti) from ".$prefix."_ele_voti_lista where id_sez='".$res[1]."'";
 					$resperc = $dbi->prepare("$sqlr");
@@ -576,7 +573,8 @@
 			$maxpos=max($pos);
 			////////////////////////////////////////////////////////////////////
-
+			
 			if ($res_voti->rowCount())
 			while (list($num_circ,$desc_circ,$num_cand,$nome,$voti,$sevalidi,$senulli,$sebianchi,$secontestati,$sevonulli) = $res_voti->fetch(PDO::FETCH_NUM)){
+#				if($genere==4) $sevalidi=$voti;
 				$z=array_search($num_circ, $pos); 
 				if (!isset($votitot[($z)])) {
@@ -589,4 +587,6 @@
 				}
 				$votitot[($z)]+=$voti;
+				if(!isset($valsez[$z])) $valsez[$z]=0;
+				$valsez[$z]=$sevalidi;
 				$voticompl+=$voti;
 			}
@@ -620,14 +620,19 @@
 						$valar[($z)][$num_cand]=$voti;
 					}
+
 					foreach ($valar as $key=>$val){ 
 						if(isset($votitot[($key)]))
 							$percar[$key]=arrayperc($val,$votitot[($key)]);
-						}
-						if($res_voti->rowCount()) {
-							$res_voti = $dbi->prepare("$sqlvoti");
-							$res_voti->execute();			 
-						}	
+							
+					}
+				#	if($res_voti->rowCount()) {
+						$res_voti = $dbi->prepare("$sqlvoti");
+						$res_voti->execute();			 
+					#}
+					
 					while (list($num_circ,$desc_circ,$num_cand,$nome,$voti,$sevalidi,$senulli,$sebianchi,$secontestati,$sevonulli) = $res_voti->fetch(PDO::FETCH_NUM)){
 						if($num_cand<$min or $num_cand>$offset) continue;
+				if($genere==4) $sevalidi=$voti;
+
 						if (!isset($temp[$num_cand])) $temp[$num_cand]=0;
 						$temp[$num_cand]+=$voti;
@@ -643,4 +648,5 @@
 									$percento=$voti."<br /><span class=\"red\" style=\"font-size:80%;\"><i>".number_format($percar[$z][$num_cand],2)." %</i></span>";
 								}
+								
 								$ar[($z)][$num_cand]=$percento;
 							}	
@@ -659,5 +665,5 @@
 							if (($maxpos)>=$num_circ and $minpos<=$num_circ){ 
 							//$posvoti++;
-								$ar[($z)][$posvoti+1]="<b>$sevalidi</b>";
+								$ar[($z)][$posvoti+1]="<b>$valsez[$z]</b>";
 								$ar[($z)][$posvoti+2]="<b>$senulli</b>";
 								$ar[($z)][$posvoti+3]="<b>$sebianchi</b>";
@@ -673,8 +679,8 @@
 					if(isset($temp)) {
 					if (!isset($tab15) or !$tab15) $tab15="candidati";
-                    if($tab15=="gruppo"){
+                    if($tab15=="gruppo" or $genere==4){
                           $votigl=" sum(validi),sum(nulli),sum(bianchi),sum(contestati),sum(voti_nulli)";
                     }elseif($votog){
-                          $votigl=" sum(validi_lista),sum(nulli),sum(bianchi),sum(contestati_lista),sum(voti_nulli)";
+                          $votigl=" sum(validi),sum(nulli),sum(bianchi),sum(contestati),sum(voti_nulli)";
                     }else{
                         if($dettnulli) $votigl=" sum(validi_lista),sum(nulli),sum(bianchi),sum(contestati_lista),sum(voti_nulli_lista)";
Index: trunk/client/modules/Elezioni/index.php
===================================================================
--- trunk/client/modules/Elezioni/index.php	(revision 317)
+++ trunk/client/modules/Elezioni/index.php	(revision 318)
@@ -616,5 +616,5 @@
 		}
 		 $sql="select t1.id_sez,sum(t1.voti)  from ".$prefix."_ele_voti_$tab as t1, ".$prefix."_ele_$tab as t2 where t1.id_$tab=t2.id_$tab and t1.id_cons='$id_cons' and t2.id_circ='$id_circ' group by t1.id_sez";
-	}else $sql="select id_cons  from ".$prefix."_ele_voti_".$tab." where id_cons='$id_cons'  group by id_sez ";
+	}else $sql="select id_sez  from ".$prefix."_ele_voti_".$tab." where id_cons='$id_cons'  group by id_sez ";
 	$res = $dbi->prepare("$sql");
 	$res->execute();
Index: trunk/client/modules/Elezioni/language/lang-en.php
===================================================================
--- trunk/client/modules/Elezioni/language/lang-en.php	(revision 317)
+++ trunk/client/modules/Elezioni/language/lang-en.php	(revision 318)
@@ -355,4 +355,6 @@
 define("_VALIDI","Valid Ballots");
 define("_NULLI","Non Valid Ballots");
+define("_SNULLE","Invalid Papers");
+define("_SBIANCHE","White Papers");
 define("_BIANCHI","Blank Ballots");
 define("_CONTESTATI","Contested Ballots");
Index: trunk/client/modules/Elezioni/language/lang-it.php
===================================================================
--- trunk/client/modules/Elezioni/language/lang-it.php	(revision 317)
+++ trunk/client/modules/Elezioni/language/lang-it.php	(revision 318)
@@ -105,4 +105,6 @@
 define("_VALIDI","Voti Validi");
 define("_NULLI","Voti Nulli");
+define("_SNULLE","Schede Nulle");
+define("_SBIANCHE","Schede Bianche");
 define("_BIANCHI","Voti Bianchi");
 define("_CONTESTATI","Voti Contestati");
Index: trunk/client/temi/realistic/style.css
===================================================================
--- trunk/client/temi/realistic/style.css	(revision 318)
+++ trunk/client/temi/realistic/style.css	(revision 318)
@@ -0,0 +1,683 @@
+a:link {
+	text-decoration: none;
+	color: #660033;
+}
+a:visited {
+	text-decoration: none;
+	color: #660000;
+}
+a:hover {
+	color: #CC2222;
+}
+body , html {
+	font-family: Verdana, Arial, Helvetica, sans-serif;
+	font-size: 13px;
+	font-style: normal;
+	font-weight: normal;
+	margin-right: 0;
+	margin-left: 0;
+	margin-top: 0;
+	text-align: center;
+	background-color: #FFFFFF;
+	color: #333333;
+}
+
+div#container{
+    
+   /* width: 798;*/
+    margin: 0px auto;   /*centra */
+    
+    }
+
+table {
+	margin-right: auto;
+	margin-left: auto;
+	text-align: left;
+	margin-top: 0px;
+	
+}
+td {
+	font-family: Verdana, Arial, Helvetica, sans-serif;
+	font-size: 13px;
+	margin-top: 0px;
+	margin: 0;
+}
+
+hr {
+	color: #000000;
+	background-color: #FFFFFF;
+	border-bottom: 1px dotted #CCCCCC;
+}
+form {
+	
+	font-size: 12px;
+	color: #000066;
+	text-decoration: none;
+	margin-right: 0px;
+	margin-left: 0px;
+	margin-top: 0px;
+	margin-bottom: 0px;
+	width: 100%;
+}
+p {
+	font-family: Verdana, Arial, Helvetica, sans-serif;
+	font-size: 13px;
+	padding-right: 8px;
+	padding-bottom: 0px;
+	padding-left: 8px;
+	padding-top: 0px;
+	margin: 2px 2px 4px;
+}
+h1 {
+	font-size: 16px;
+	font-weight: bold;
+	color: #222266;
+	text-decoration: none;
+	border-bottom-width: 1px;
+	border-bottom-style: dotted;
+	border-bottom-color: #222266;
+	margin-top: 6px;
+	margin-bottom: 8px;
+	padding-right: 0px;
+	padding-left: 0px;
+}
+h2 {
+	font-size: 14px;
+	font-weight: bold;
+	color: #660000;
+	text-decoration: none;
+	border-bottom-width: 1px;
+	border-bottom-style: dotted;
+	border-bottom-color: #CCCCCC;
+	margin-top: 9px;
+	margin-bottom: 2px;
+	padding-right: 1px;
+	padding-left: 4px;
+}
+h4 {
+	font-size: 14px;
+	color: #003366;
+	text-decoration: none;
+	background-position: center;
+	bottom: 9px;
+	margin: 20px;
+	text-align: center;
+	border: 1px dotted #666666;
+	padding: 2px;
+	width: auto;
+	background-color: #EEEFEF;
+	font-variant: small-caps;
+}
+h5 {
+	font-size: 14px;
+	font-weight: bold;
+	color: #000;
+	text-decoration: none;
+	border-bottom-width: 1px;
+	border-bottom-style:solid ;
+	border-bottom-color: #666666;
+	margin-top: 0px;
+	margin-bottom: 4px;
+	padding-right: 1px;
+	padding-left: 4px;
+	background-color: #E0E0E0;
+	background-position: center;
+	text-align: center;
+}
+h6 {
+	font-size: 12px;
+	font-weight: bold;
+	color: #333333;
+	text-decoration: none;
+	border-bottom-style: dotted;
+	padding-left: 4px;
+	background-position: center;
+	border-bottom-color: #EEEEEE;
+	border-bottom-width: 1px;
+	padding-top: 3px;
+	padding-right: 2px;
+	padding-bottom: 0px;
+	bottom: 9px;
+	margin-top: 1px;
+	margin-bottom: 3px;
+}
+
+
+/* usate per blocco */
+
+.sidebar {
+	
+	text-align:left;
+	margin-top:0px;
+	width: 200px;	
+	border: none;
+	padding: 0px;
+	/*background-color:#b0b0b0;*/
+}
+.sidebar a{
+color:#5D81A6;
+}
+.sidebar a:hover{
+text-decoration: underline;
+/*color:#FFFFFF;*/
+}
+.sidebar a:visited{
+color:#5D81A6;
+}
+
+
+
+.footbar {
+	background-image: url(images/footer.jpg);
+	font-size: 10px;
+	color: #330000;
+	padding-right: 10px;
+	padding-bottom: 2px;
+	padding-left: 8px;
+	padding-top: 2px;
+	height: 24px;
+}
+.modulo {
+	text-decoration: none;
+	border: 1px solid #666699;
+	font-size: 10px;
+}
+.moduloform {
+	text-decoration: none;
+	border: 1px solid #666699;
+	font-size: 13px;
+	text-align: left;
+}
+.modulo-extranet {
+	text-decoration: none;
+	border: 1px dotted #000033;
+	width: 100px;
+	background-color: #FFFFFF;
+	color: #CCCCCC;
+}
+.modulo-button {
+	color: #663366;
+	text-decoration: none;
+	background-color: #FFFFEE;
+	border: 1px solid #660033;
+	width: 50%;
+	text-align: center;
+	font-size: 10px;
+	padding: 3px;
+}
+.modulosmall {
+	font-size: 9px;
+	color: #000066;
+	text-decoration: none;
+	background-color: #FFFFFF;
+	border: 0px;
+	width: 100%;
+	margin: 0px;
+	padding: 2px;
+}
+.modulo-table {
+	font-size: 10px;
+	color: #000066;
+	text-decoration: none;
+	background-color: #FFFFFF;
+	border-top: 1px dotted #000033;
+	border-bottom: 1px dotted #000033;
+	width: 100%;
+}
+.modulo-titolo {
+	font-size: 13px;
+	font-weight: bold;
+	color: #336633;
+	text-decoration: none;
+	border-top: 1px dotted #000033;
+	margin-top: 10px;
+	margin-bottom: 0px;
+	margin-right: 0px;
+	margin-left: 0px;
+	padding: 0px;
+	background-color: #EFEFEF;
+	text-align: left;
+	width: 100%;
+}
+.table-main {
+	border: 1px solid #DEDEDC;
+	font-size: 13px;
+	background-position: center top;
+	padding: 0px;
+	color: #666666;
+	text-align:center;
+	width: 950px;
+	/*width: 90%;*/
+}
+
+.table-blocco {
+border: 1px solid #DEDEDC;
+font-size: 10px;
+background-position: center top;
+padding: 0px;
+color: #666666;
+}
+
+					
+
+
+.table-central {
+	border-top-width: 1px;
+	border-right-width: 1px;
+	border-bottom-width: 1px;
+	border-left-width: 1px;
+	border-right-style: dotted;
+	border-left-style: dotted;
+	border-top-color: #CC3300;
+	border-right-color: #CC3300;
+	border-bottom-color: #CC3300;
+	border-left-color: #CC3300;
+	border-top-style: none;
+	border-bottom-style: none;
+	height: 100%;
+	width: 100%;
+	margin: 0px;
+	padding: 8px;
+}
+.table-info {
+	font-size: 10px;
+	padding-right: 4px;
+	padding-bottom: 2px;
+	padding-left: 2px;
+	padding-top: 4px;
+	margin: 2px 2px 4px;
+}
+.table-main-secondary {
+	background-position: center top;
+	border-top: none;
+	border-left: 1px dotted #DEDEDC;
+	border-bottom: none;
+	border-right: none;
+}
+.table-docs {
+	font-size: 9px;
+	padding: 1px;
+	color: #000000;
+	/* margin: 4px 4px 40px;*/
+	border-bottom: thin dotted #666666;
+	text-align:center;
+}
+.omniainternet {
+	font-size: 13px;
+	color: #993366;
+	text-decoration: none;
+	background-position: center;
+	bottom: 5px;
+	margin: 20px;
+	text-align: center;
+	border: 1px dotted #FF6666;
+	padding: 2px;
+	width: auto;
+	background-color: #FFEFEF;
+	font-variant: small-caps;
+}
+.message {
+	font-size: 13px;
+	color: #EE3366;
+	text-decoration: none;
+	background-position: center;
+	bottom: 5px;
+	margin: 10px auto;
+	text-align: left;
+	border: 1px dotted #FF6666;
+	padding: 2px;
+	width: 450px;
+	background-color: #FFFFEF;
+}
+.td-main {
+	
+	border-top: none;
+	border-right: 1px dotted #DEDEDC;
+	border-bottom: none;
+	border-left: 1px dotted #DEDEDC;
+}
+.news {
+	font-size: 10px;
+	border: none;
+	padding-right: 8px;
+	padding-bottom: 0px;
+	padding-left: 8px;
+	padding-top: 0px;
+	color: #330000;
+}
+.headlines {
+	font-size: 10px;
+	color: #333333;
+	text-decoration: none;
+	margin-top: 10px;
+	margin-bottom: 16px;
+	width: 366px;
+	text-align: left;
+	border: 0px dotted #FFFFFF;
+}
+
+
+
+.tavola {
+	background-image: url(images/back.gif);
+	font-size: 13px;
+	border: none;
+	color: #330000;
+}
+
+/* tabelle specifiche */
+	
+.piccolo {
+	BACKGROUND: none; 
+	COLOR: #cccccc; 
+	FONT-SIZE: 10px; 
+	FONT-WEIGHT: normal; 
+	FONT-FAMILY: Verdana, Helvetica; 
+	TEXT-DECORATION: none}
+		
+.table-80 {
+	margin: 0px auto;
+	font-size: 13px;
+	border: none;
+	color: #330000;
+	width: 80%;
+}		
+.table-762 {
+	text-align: center;
+	margin: 0px auto;
+	font-size: 13px;
+	border: none;
+	color: #330000;
+	width: 762px;
+        margin-top: 0px;
+	
+	padding: 0px;
+}		
+.td-image {
+	text-align: center;	
+	border: none;
+	margin: 0px;
+	padding: 0px;
+}
+.image {
+	/*float: center;*/
+	border: none;
+	margin: 0px;
+	padding: 0px;
+}
+
+.td-2 {
+	
+	margin: 0px 0 0 0px;
+		
+	border: none;
+	background-color: #d2d2d2;
+	padding: 0px;
+        FONT-SIZE: 13px; 
+        FONT-FAMILY: Verdana, Helvetica;
+	text-align: center; 
+}			
+.td-5 {
+	
+	margin: 0px 0 0 0px;
+	width: 5%;	
+	border: none;
+	background-color: #d2d2d2;
+	padding: 0px;
+        FONT-SIZE: 13px; 
+        FONT-FAMILY: Verdana, Helvetica;
+	text-align: center; 
+}	
+
+.td-30 {
+	
+	
+	width: 30%;	
+	text-align: left; 
+	
+	
+        FONT-SIZE: 13px; 
+        FONT-FAMILY: Verdana, Helvetica;
+}	
+.td-149 {
+	float: right;
+	margin-top:0px;
+	/*margin: 0px 0 0 0px;*/
+	width: 200px;	
+	border: none;
+	background-color: #d2d2d2;
+	padding: 0px;
+}	
+.td-130 {
+	float: right;
+	margin: 0px 0 0 1px;
+	width: 130px;	
+	border: none;
+	background-color: #d2d2d2;
+	padding: 0px;
+	
+}
+.td-130c {
+	float: right;
+	text-align:left;
+	margin: 0px 0 0 1px;
+	width: 130px;	
+	border: none;
+	
+	padding: 0px;
+}		
+.td-vuoto {
+	
+	
+	width: 100%;	
+	border: none;
+	text-align: left; 
+	
+}
+.td-vuotoc {
+	
+	
+	width: 100%;	
+	border: none;
+	text-align: center; 
+	
+}
+
+.td-89 {
+	
+	
+	width: 89%;	
+	border: none;
+	text-align: left; 
+	
+}
+.td-640 {
+	float: left;
+	margin: 0px 0 0 10px;
+	width: 610px;	
+	border: none;
+	background-color: #ffffff;
+	padding: 0px;
+	text-align: left; 
+}	
+
+
+div#sx{
+    width: 610px;
+    float: left;
+    text-align: left;   
+    }
+
+div#dx{
+    width: 200px;
+    float: right;
+    text-align: left;   
+    }
+
+div#divbutton{
+    width: 798px;
+    
+    text-align: right;      
+    }
+
+
+div#flash{
+    width: 410px;
+    float: left;
+    text-align: left;   
+    }
+
+
+
+.noblocco {
+border: 0px;
+margin-right:0px;
+margin-left:130px;
+text-align: right;
+vertical-align: middle;
+width:18px;
+height:18px;
+}
+
+
+.normal{
+    margin: 0px 0 0 1px;
+    float: left;
+    text-align: left;   
+    }
+
+.stemmapic {
+	/*float: center;*/
+	border: none;
+	margin: 0px;
+	padding: 0px;
+	width:30px;
+	height:30px;
+}		
+.stemma {
+	/*float: center;*/
+	border: none;
+	margin: 0px;
+	padding: 0px;
+	width:50px;
+	height:50px;
+	text-align: center;
+}		
+
+/**********************************************************************BOTTONI W3C*****************************************************/
+
+.w3cbutton3 {
+  margin: 0px 0px 0px 5px;
+  width: 95px;
+  border: 1px solid #6A6A6A;
+  font-family: helvetica,arial,sans-serif;
+  font-size: 10px;
+  float: left;
+}
+
+.w3cbutton3 a {
+  display: block;
+  width: 100%;
+}
+
+.w3cbutton3 a:link, .w3cbutton3 a:visited {
+  background-color: #8CC8C7;
+  color: #2A290B;
+  text-decoration: none;
+}
+
+.w3cbutton3 a:hover {
+  background-color: #C9F4F3;
+  color: #2A290B;
+  text-decoration: none;
+}
+
+.w3cbutton3 span.w3c {
+  font-weight: bold;
+  padding: 0 0.4em;
+  background-color: #FFFFCC;
+  color: #0C479D;
+}
+
+.w3cbutton3 span.spec {
+  color: #333333;
+}
+
+.w3cbutton3 span.specRed {
+  color: #FF0000;
+}
+
+
+/******************** font e backcolor******************************/
+.blu 	{
+	BACKGROUND: none;
+	font-weight: bold; 
+	COLOR: #003366; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica
+}
+
+
+.red 	{
+	BACKGROUND: none; 
+	COLOR: #ff0000; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica
+}
+
+.redbig 	{
+	BACKGROUND: none; 
+	COLOR: #ff0000; 
+	FONT-SIZE: 16px; 
+	FONT-FAMILY: Verdana, Helvetica
+}
+
+.bgw	{
+	BACKGROUND: #ffffff; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica;
+	text-align: center;
+}
+
+.bggray 	{
+	BACKGROUND: #d2d2d2; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica;
+	text-align: center;
+}
+
+.bggray2 	{
+	BACKGROUND: #EFEFEF; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica;
+	text-align: center;
+	}
+
+.bggray3 	{
+	BACKGROUND: #EFEFEF; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica;
+	text-align: left;
+	}
+
+.normale {
+	BACKGROUND: none; 
+	COLOR: #000000; 
+	FONT-SIZE: 12px; 
+	FONT-FAMILY: Verdana, Helvetica;
+	text-align: left;
+}
+
+.nobordo {
+border: 0px;
+text-align: center;
+vertical-align: middle;
+}
+
+.bordo {
+border: 1px solid #ff0000;
+text-align: left;
+vertical-align: middle;
+}
+
+
Index: trunk/install/sql/eleonline.sql
===================================================================
--- trunk/install/sql/eleonline.sql	(revision 317)
+++ trunk/install/sql/eleonline.sql	(revision 318)
@@ -449,5 +449,5 @@
   `num_gruppo` int(2) UNSIGNED NOT NULL DEFAULT '0',
   `id_circ` int(11) NOT NULL DEFAULT '0',
-  `num_circ` int(2) UNSIGNED NOT NULL,
+  `num_circ` int(2) UNSIGNED NOT NULL DEFAULT '0',
   `descrizione` text,
   `simbolo` text,
@@ -544,5 +544,5 @@
   `id_cons_gen` int(11) NOT NULL DEFAULT '0',
   `orario` time NOT NULL DEFAULT '00:00:00',
-  `data` date NOT NULL DEFAULT '0000-00-00'
+  `data` date NOT NULL DEFAULT '1970-01-01'
 ) ENGINE=MyISAM DEFAULT CHARSET=latin1;
 
@@ -718,5 +718,5 @@
   `id_parz` int(11) NOT NULL,
   `orario` time NOT NULL DEFAULT '00:00:00',
-  `data` date NOT NULL DEFAULT '0000-00-00',
+  `data` date NOT NULL DEFAULT '1970-01-01',
   `voti_uomini` int(7) NOT NULL DEFAULT '0',
   `voti_donne` int(7) NOT NULL DEFAULT '0',
