Changeset 104 for trunk/client/modules/Elezioni/gruppo.php
- Timestamp:
- May 29, 2011, 1:20:58 AM (13 years ago)
- Location:
- trunk/client
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/client
-
Property svn:ignore
set to
config.php
-
Property svn:ignore
set to
-
trunk/client/modules/Elezioni/gruppo.php
r103 r104 179 179 */ 180 180 $visvot=''; 181 182 if (!$csv) echo "<div><h5>$pagina</h5></div>"; 183 if (!$csv) echo "<div style=\"text-align:left; margin-left:20px;\">"; 184 181 185 if(strstr( $op,'candidato')){ 182 186 // $numliste=mysql_num_rows($res_lis); 183 187 $visvot="cand"; 184 188 if (!$csv){ 189 190 185 191 $res_lis = mysql_query("SELECT id_lista, descrizione,num_lista from ".$prefix."_ele_lista where id_cons=$id_cons $condcirc order by num_lista",$dbi); 186 192 //elenco delle liste per la scelta 187 echo "<p> Scegli la lista:193 echo "<p>"._SCEGLI_LISTA.": 188 194 <select name=\"id_lista\" class=\"modulo\" onChange=\"top.location.href=this.form.pag.value+this.form.id_lista.options[this.form.id_lista.selectedIndex].value;return false\">"; 189 195 while(list($id_rif,$descrizione,$num_lis) = mysql_fetch_row($res_lis)) { … … 279 285 if (!(0<$offset and $offset<=$num_cand)) $offset=$num_cand; 280 286 if (!$csv) { 281 echo "<br /><table> 282 <tr><td><h5>$pagina</h5></td></tr>"; 283 echo "<tr><td>"._DA.": <select name=\"min\" class=\"modulo\">"; 287 if(strstr( $op,'lista')){$scelta=_SCEGLI_LISTA;}else{$scelta=_SCEGLI_CANDI;} 288 echo "<p>$scelta "._DA.": <select name=\"min\" class=\"modulo\">"; 284 289 while(list($id_rif,$descrizione,$num_lis) = mysql_fetch_row($res_cand)) { 285 290 if (!$min) $min=$num_lis; … … 290 295 291 296 } 292 echo "</select> </td></tr>";293 echo " <tr><td> "._A.": <select name=\"offset\" class=\"modulo\">";297 echo "</select>"; 298 echo " "._A.": <select name=\"offset\" class=\"modulo\">"; 294 299 mysql_data_seek($res_cand,0); 295 300 while(list($id_rif,$descrizione,$num_lis) = mysql_fetch_row($res_cand)) { … … 301 306 302 307 } 303 echo "</select></td></tr></table>"; 304 echo "<table><tr><td>"; 308 echo "</select></p>"; 309 //echo "<div style=\"text-align:left; margin-left:20px;\">"; 310 if(!$circo){ 311 echo "<p>"._SCEGLI." $tipo1 n. <input name=\"minsez\" value=\"$minsez\" size=\"4\" ></input>"; 312 echo _A." n. <input name=\"offsetsez\" value=\"$offsetsez\" size=\"4\" ></input> (max. $num_sez)"; 313 } 314 # pagine 315 $diff=($offsetsez-$minsez); 316 if ($minsez>1){ 317 $minsez_p= ($minsez-$diff)>1 ? $minsez-$diff-1:1; 318 319 $offsetsez_p=$offsetsez-$diff-1; 320 echo "<div style=\"float: right; width:200px;margin-left:10px;margin-right:400px;font-size:12px \"><a href=\"modules.php?name=Elezioni&file=index&id_cons_gen=$id_cons_gen&id_comune=$id_comune&op=$op&min=$min&offset=$offset&minsez=$minsez_p&offsetsez=$offsetsez_p&perc=$perc&id_lista=$id_lista\"> <- $tipo2 Precedenti</a></div>"; 321 }else{echo "";} 322 323 if ($offsetsez<$num_sez){ 324 $minsez_s=$minsez+$diff+1; 325 $offsetsez_s= ($offsetsez+$diff)>$num_sez ? $num_sez: $offsetsez+$diff+1; 326 327 echo "<div style=\"float: left; width:200px; margin-left:10px;\"><a href=\"modules.php?name=Elezioni&file=index&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez_s&offsetsez=$offsetsez_s&perc=$perc&id_lista=$id_lista\"> $tipo2 Successive -></a></div>"; 328 }else{echo "";} 329 330 331 332 333 305 334 if(!$circo) 306 echo "$tipo1 n. <input name=\"minsez\" value=\"$minsez\" size=\"4\" ></input>"; 307 echo "</td>"; 308 echo "<td>"; 309 if(!$circo) 310 echo _A." n. <input name=\"offsetsez\" value=\"$offsetsez\" size=\"4\" ></input> (max. $num_sez)"; 311 echo "</td> 312 <td align=\"right\">"._MOSTRA." $tipo2 <br/>"._PERCOL."<input type=\"radio\" name=\"orvert\" $righe value=\"0\"></input><br/>"._PERRIGHE." <input 335 336 echo "<div style=\"margin-left:10px;\"><br/>"._MOSTRA." $tipo2 "._PERCOL."<input type=\"radio\" name=\"orvert\" $righe value=\"0\"></input>"._PERRIGHE." <input 313 337 type=\"radio\" name=\"orvert\" $colonne value=\"1\"></input>"; 314 338 echo "<input type=\"hidden\" name=\"name\" value=\"Elezioni\"></input> 315 </td></tr>"; 316 $diff=($offsetsez-$minsez); 317 if ($minsez>1){ 318 $minsez_p= ($minsez-$diff)>1 ? $minsez-$diff-1:1; 319 320 $offsetsez_p=$offsetsez-$diff-1; 321 echo "<tr><td valign=\"middle\"><div align=\"right\"><a href=\"modules.php?name=Elezioni&file=index&id_cons_gen=$id_cons_gen&id_comune=$id_comune&op=$op&min=$min&offset=$offset&minsez=$minsez_p&offsetsez=$offsetsez_p&perc=$perc&id_lista=$id_lista\"> <- Precedenti</a></div></td>"; 322 }else{echo "<tr><td></td>";} 323 if ($offsetsez<$num_sez){ 324 $minsez_s=$minsez+$diff+1; 325 $offsetsez_s= ($offsetsez+$diff)>$num_sez ? $num_sez: $offsetsez+$diff+1; 326 327 echo "<td><div><a href=\"modules.php?name=Elezioni&file=index&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez_s&offsetsez=$offsetsez_s&perc=$perc&id_lista=$id_lista\"> Successive -></a></div></td><td></td></tr>"; 328 }else{echo "<td></td><td></td></tr>";} 329 330 331 332 echo "<tr>"; 339 </div>"; 340 341 342 343 echo "<p>"; 333 344 if (!strstr( $op,'candidato')) { 334 echo " <td>"._VIS_PERC.": <input type=\"checkbox\" name=\"perc\" value=\"true\"";345 echo ""._VIS_PERC.": <input type=\"checkbox\" name=\"perc\" value=\"true\""; 335 346 if($perc=='true') echo " checked=\"true\""; 336 echo "></input>< /td>";337 } 338 echo " <td>";347 echo "></input><br/>"; 348 } 349 echo ""; 339 350 if($circo) 340 351 echo "<input type=\"hidden\" name=\"id_circ\" value=\"$id_circ\"></input>"; … … 345 356 echo "<input type=\"hidden\" name=\"pag2\" value=\"modules.php?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=\"></input>"; 346 357 347 echo " <input type=\"submit\" name=\"update\" value=\""._OK."\"></input>";358 echo " <input type=\"submit\" name=\"update\" value=\""._RICARICA."\"></input></p></div>"; 348 359 349 360 … … 385 396 386 397 $datipdf="<b>"._COMUNE." $descr_comune</b> - "._RISULTATI.": $descr_cons<br/><b>$pagina</b><br/><br/> $list1 $list2 $list3 "; 398 399 400 401 402 403 404 405 # verificare la stampa sulle circoscrizioni 406 echo "<div style=\"text-align:right;width:900px;margin-left:10px;margin-right:20px;font-size:12px \">"._ESPORTA."<br />"; 407 if($circo) echo "<a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&id_circ=$id_circ&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/printer.gif\" alt=\"Stampa\" /></a>"; 408 else{ 409 echo "<a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/printer.gif\" alt=\"Stampa\" /></a>"; 410 echo "<a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&xls=1&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/csv.gif\" alt=\"Export Csv\" /></a>"; 411 echo "<a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&pdf=1&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/pdf.gif\" alt=\"Export Pdf\" /></a>"; 412 } 413 echo "</div></form>"; 414 /* 387 415 if (!$circo) 388 416 echo "dalla $tipo3 n. <b>$minsez</b> alla $tipo3 n. <b>$offsetsez</b> di <b>$num_sez</b> $tipo2<br/><br/>"; 389 417 else echo "<br/><br/>"; 390 418 391 392 393 394 395 # verificare la stampa sulle circoscrizioni396 if($circo) echo "</td><td><a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&id_circ=$id_circ&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/printer.gif\" alt=\"Stampa\" /></a>";397 else{398 echo "</td><td><a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/printer.gif\" alt=\"Stampa\" /></a>";399 echo "<a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&xls=1&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/csv.gif\" alt=\"Export Csv\" /></a>";400 echo "<a href=\"".$_SERVER['PHP_SELF']."?name=Elezioni&op=$op&id_cons_gen=$id_cons_gen&id_comune=$id_comune&csv=1&orvert=$orvert&min=$min&offset=$offset&minsez=$minsez&offsetsez=$offsetsez&perc=$perc&id_lista=$id_lista&pdf=1&datipdf=$datipdf\" ><img class=\"image\" src=\"modules/Elezioni/images/pdf.gif\" alt=\"Export Pdf\" /></a>";401 }402 echo "</td></tr></table></div></form>";403 404 419 if (strstr( $op,'candidato')) echo $list2; 405 420 */ 406 421 407 422 } 408 423 if (!$csv){ 409 //echo "<table border=\"0\" width=\"100%\"><tr><td align=\"center\"><h5> Sezioni scrutinate";410 //if ($tipo_cons!=4) echo ": $tot_scr su $tot_sez";411 //echo "</h5></td></tr></table>";424 echo "<div style=\"text-align:right;width:900px;margin-left:10px;margin-right:2px;font-size:12px \"><h5> Sezioni scrutinate"; 425 if ($tipo_cons!=4) echo ": $tot_scr su $tot_sez "; 426 echo "</h5> </div>"; 412 427 } 413 428 $y=1; … … 448 463 449 464 ################### <span class=\"red\"><i>".$temp3[$key]." %</i></span> 450 $ar[$z][0]=$res[0]; if($grpercscru) {$ar[$z][0].="<br ><span class=\"red\"><i>$grpercscru%</i></span>";if(!strstr($ar[0][0],'scrutinio')) $ar[0][0].="<br><span class=\"red\"><i>% scrutinio</i></span>"; }465 $ar[$z][0]=$res[0]; if($grpercscru) {$ar[$z][0].="<br /><span class=\"red\"><i>$grpercscru%</i></span>";if(!strstr($ar[0][0],'scrutinio')) $ar[0][0].="<br /><span class=\"red\"><i>% scrutinio</i></span>"; } 451 466 $pos[$z]=$res[0]; 452 467 #$valar[$z]=array();
Note:
See TracChangeset
for help on using the changeset viewer.