Index: /trunk/client/modules/Elezioni/blocchi/01_votanti.php
===================================================================
--- /trunk/client/modules/Elezioni/blocchi/01_votanti.php	(revision 72)
+++ /trunk/client/modules/Elezioni/blocchi/01_votanti.php	(revision 73)
@@ -54,11 +54,13 @@
 	while (list($tot_votanti,$validi,$nulli,$bianchi,$contestati,$id,$si,$no) = mysql_fetch_row($res)){
 		$tot_votanti=$validi+$bianchi+$nulli+$contestati;
+		$arvoti=array($validi,$nulli,$bianchi,$contestati);
+		$arperc=arrayperc($arvoti,$tot_votanti);
 		if($tot_votanti){
 			if($genere==0 and $validi) {$perc_si=number_format($si*100/$validi,2);$perc_no=number_format(100 - $si*100/$validi,2);}
 			else {$perc_si="0.00"; $perc_no="0.00";}
-		$perc_validi=number_format($validi*100/$tot_votanti,2);
-		$perc_nulli=number_format($nulli*100/$tot_votanti,2);
-		$perc_bianchi=number_format($bianchi*100/$tot_votanti,2);
-		$perc_conte=number_format($contestati*100/$tot_votanti,2);
+		$perc_validi=number_format($arperc[0],2);#number_format($validi*100/$tot_votanti,2);
+		$perc_nulli=number_format($arperc[1],2);
+		$perc_bianchi=number_format($arperc[2],2);
+		$perc_conte=number_format($arperc[3],2);
 		}else {$perc_validi="0.00";$perc_nulli="0.00";$perc_bianchi="0.00";$perc_conte="0.00";}
 		if($tot_aventi)
@@ -79,19 +81,19 @@
 		if ($genere==0) {echo "<br/>Referendum n. <b>[$num_gruppo]</b><br/>";}
 		echo "
-		<tr bgcolor=\"#ffffff\"><td ><b>"._AVENTI."</b></td><td>$tot_aventi</td><td><span class=\"red\">100%</span></td></tr>
+		<tr bgcolor=\"#ffffff\"><td ><b>"._AVENTI."</b></td><td align=\"right\">$tot_aventi</td><td align=\"right\"><span class=\"red\">100.00%</span></td></tr>
 
-		<tr bgcolor=\"#ffffff\"><td><b>"._VOTANTI."</b></td><td>$tot_votanti</td><td><span class=\"red\">$perc_votanti%</span></td></tr>";
+		<tr bgcolor=\"#ffffff\"><td><b>"._VOTANTI."</b></td><td align=\"right\">$tot_votanti</td><td align=\"right\"><span class=\"red\">$perc_votanti%</span></td></tr>";
 	if ($genere==0){		
-		echo "<tr bgcolor=\"#ffffff\"><td>"._SI."</td><td>$si</td><td><span class=\"red\">$perc_si%</span></td></tr>
+		echo "<tr bgcolor=\"#ffffff\"><td>"._SI."</td><td align=\"right\">$si</td><td align=\"right\"><span class=\"red\">$perc_si%</span></td></tr>
 		
-		<tr bgcolor=\"#ffffff\"><td>"._NO."</td><td>$no</td><td><span class=\"red\">$perc_no%</span></td></tr>";
+		<tr bgcolor=\"#ffffff\"><td>"._NO."</td><td align=\"right\">$no</td><td align=\"right\"><span class=\"red\">$perc_no%</span></td></tr>";
 		}
-		echo "<tr bgcolor=\"#ffffff\"><td>"._VALIDI."</td><td>$validi</td><td><span class=\"red\">$perc_validi%</span></td></tr>
+		echo "<tr bgcolor=\"#ffffff\"><td>"._VALIDI."</td><td align=\"right\">$validi</td><td align=\"right\"><span class=\"red\">$perc_validi%</span></td></tr>
 		
-		<tr bgcolor=\"#ffffff\"><td>"._NULLI."</td><td>$nulli</td><td><span class=\"red\">$perc_nulli%</span></td></tr>
+		<tr bgcolor=\"#ffffff\"><td>"._NULLI."</td><td align=\"right\">$nulli</td><td align=\"right\"><span class=\"red\">$perc_nulli%</span></td></tr>
 		
-		<tr bgcolor=\"#ffffff\"><td>"._BIANCHI."</td><td>$bianchi</td><td><span class=\"red\">$perc_bianchi%</span></td></tr>
+		<tr bgcolor=\"#ffffff\"><td>"._BIANCHI."</td><td align=\"right\">$bianchi</td><td align=\"right\"><span class=\"red\">$perc_bianchi%</span></td></tr>
 		
-		<tr bgcolor=\"#ffffff\"><td>"._CONTESTATI."</td><td>$contestati</td><td><span class=\"red\">$perc_conte%</span></td></tr>
+		<tr bgcolor=\"#ffffff\"><td>"._CONTESTATI."</td><td align=\"right\">$contestati</td><td align=\"right\"><span class=\"red\">$perc_conte%</span></td></tr>
 
 		</table>";
Index: /trunk/client/modules/Elezioni/blocchi/02_risultati.php
===================================================================
--- /trunk/client/modules/Elezioni/blocchi/02_risultati.php	(revision 72)
+++ /trunk/client/modules/Elezioni/blocchi/02_risultati.php	(revision 73)
@@ -21,5 +21,5 @@
     echo "<table>";
     for($x=0;$x<count($gruppo);$x++){
-	echo "<tr><td><strong><big>&middot;</big></strong></td><td>".$gruppo[$x]." </td><td><b><span style=\"color:#ff0000;\">".$pro[$x] ."%</span></b></td></tr>\n";
+	echo "<tr><td><strong><big>&middot;</big></strong></td><td>".$gruppo[$x]." </td><td  align=\"right\"><b><span style=\"color:#ff0000;\">".$pro[$x] ."%</span></b></td></tr>\n";
     }
     echo "</table>";
Index: /trunk/client/modules/Elezioni/funzioni.php
===================================================================
--- /trunk/client/modules/Elezioni/funzioni.php	(revision 72)
+++ /trunk/client/modules/Elezioni/funzioni.php	(revision 73)
@@ -428,5 +428,6 @@
 					$temp2tot=0;$temp2=array();
 					while (list($key,$voti)= each($temp)) {
-						$temp2[$key]=(ceil($voti*1000/$sevaltot)-($voti*1000/$sevaltot)); 
+						if($voti)
+							$temp2[$key]=(ceil($voti*10000/$sevaltot)-($voti*10000/$sevaltot)); 
                     	$valperc=number_format($voti*100/$sevaltot,2);
 						$temp3[$key]=$valperc;
