source: trunk/client/temi/tour/button.php@ 388

Last change on this file since 388 was 25, checked in by roby, 15 years ago

Continua sostituzione funzioni ereg

File size: 3.7 KB
Line 
1<?php
2/************************************************************************/
3/* Eleonline - Raccolta e diffusione dei dati elettorali */
4/* by Luciano Apolito & Roberto Gigli */
5/* http://www.eleonline.it */
6/* info@eleonline.it luciano@aniene.net rgigli@libero.it */
7/************************************************************************/
8
9# linguaggio x demo
10###########################
11if(!function_exists("language")){
12
13function language(){
14###########################
15
16global $lang,$name,$op,$file,$filelang,$id_comune,$op,$id_cons,$id_cons_gen;
17$filename=$filelang;
18// linguaggio
19
20$menulist='';
21// scelta linguaggio
22 $langdir = dir("modules/Elezioni/language");
23 while($func=$langdir->read()) {
24 if(substr($func, 0, 5) == "lang-") {
25 $menulist .= "$func ";
26 }
27 }
28 closedir($langdir->handle);
29 $menulist = explode(" ", $menulist);
30 sort($menulist);
31 for ($i=0; $i < sizeof($menulist); $i++) {
32 if($menulist[$i]!="") {
33 $tl = preg_replace("/lang-/","",$menulist[$i]);
34 $tl = preg_replace("/.php/","",$tl);
35 $altlang = ucfirst($tl);
36
37 if ($lang==$tl) $bordo="class=\"bordo\"";else $bordo="class=\"nobordo\"";
38 echo "<a href=\"modules.php?name=$name&amp;op=$op&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;newl=$tl\"><img $bordo src=\"modules/Elezioni/images/$tl.gif\" alt=\"$altlang\" title=\"$altlang\" /></a> ";
39 }
40 }
41
42}
43}
44# flash x demo
45
46###############################
47if(!function_exists("flash")){
48function flash(){
49###############################
50global $flash,$name,$id_comune,$op,$id_cons,$id_cons_gen;
51
52if ($flash=='1'){
53 echo "<a href=\"modules.php?name=$name&amp;op=$op&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;flash=0\"><img class=\"nobordo\" src=\"modules/Elezioni/images/flashno.gif\" alt=\"NoFlash\" title=\"NoFlash\" /></a>";
54
55}else{
56
57echo "<a href=\"modules.php?name=$name&amp;op=$op&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;flash=1\"><img class=\"nobordo\" src=\"modules/Elezioni/images/flashyes.gif\" alt=\"YesFlash\" title=\"YesFlash\" /></a>";
58
59}
60
61}
62}
63
64# blocco no
65############################
66if(!function_exists("noblocco")){
67function noblocco(){
68############################
69global $blocco,$name,$id_comune,$op,$id_cons,$id_cons_gen;
70
71if ($blocco=='1'){
72 echo "<a href=\"modules.php?name=$name&amp;op=$op&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;block=0\"><img class=\"nobordo\" src=\"modules/Elezioni/images/close.gif\" alt=\"NoBlocco\" title=\"NoBlocco\" /></a>";
73
74}else{
75
76 echo "<a href=\"modules.php?name=$name&amp;op=$op&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;block=1\"><img class=\"nobordo\" src=\"modules/Elezioni/images/open.gif\" alt=\"YesBlocco\" title=\"YesBlocco\" /></a>";
77
78}
79
80}
81}
82
83# tour
84
85
86############################
87if(!function_exists("tour")){
88function tour(){
89############################
90global $tour,$name,$id_comune,$op,$id_cons,$id_cons_gen;
91
92if ($tour=='1'){
93
94echo "<a href=\"modules.php?name=$name&amp;op=$op&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;tour=0&amp;csv=0&amp;block=1\">
95 <img class=\"nobordo\" src=\"modules/Elezioni/images/stop.gif\" alt=\"NoBlocco\" title=\"Stop\" /></a>";
96
97}else{
98
99
100
101 echo "<a href=\"modules.php?name=$name&amp;csv=1&amp;block=0&amp;id_comune=$id_comune&amp;id_cons=$id_cons&amp;id_cons_gen=$id_cons_gen&amp;tour=1\">
102
103
104 <img class=\"nobordo\" src=\"modules/Elezioni/images/play.gif\" alt=\"YesBlocco\" title=\"Play\" /></a>";
105
106}
107
108}
109}
110
111?>
Note: See TracBrowser for help on using the repository browser.