Changeset 322


Ignore:
Timestamp:
Jun 6, 2019, 1:18:52 AM (5 years ago)
Author:
roby
Message:
 
Location:
trunk
Files:
2 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/client/modules.php

    r283 r322  
    165165$sql = $dbi->prepare("SELECT id_cons,id_conf FROM ".$prefix."_ele_cons_comune where id_cons_gen='$id_cons_bak' and id_comune='$id_combak'");
    166166$sql->execute();
    167 $row = $sql->fetchAll(PDO::FETCH_ASSOC);
    168 $id_cons=$row[1];$hondt=$row[2];
     167list($id_cons,$hondt) = $sql->fetch(PDO::FETCH_NUM);
    169168
    170169// incluso in consiglieri.php, ma io carico le vecchie variabili per compatibilit'a all'indietro
  • trunk/client/modules/Elezioni/backup.php

    r265 r322  
    11<?php
    22$param=strtolower($_SERVER['REQUEST_METHOD']) == 'get' ? $_GET : $_POST;
     3global $prefix,$dbi;
    34if (isset($param['id_cons_gen']))
    45         $id_cons_gen2=intval($param['id_cons_gen']);
  • trunk/client/modules/Elezioni/backup2.php

    r321 r322  
    11<?php
    2 global $dbi,$id_cons_gen,$id_comune,$prefix;
     2global $dbi,$prefix;
     3$id_comune=intval($_GET['id_comune']);
     4$id_cons_gen=intval($_GET['id_cons_gen']);
    35$sql="select id_cons from ".$prefix."_ele_cons_comune where id_cons_gen='$id_cons_gen' and id_comune='$id_comune'" ;
    46        $res = $dbi->prepare("$sql");
     
    5759
    5860function scarica_array($sql,$tab){
     61        global $dbi;
    5962        $res_comune = $dbi->prepare("$sql");
    6063        $res_comune->execute();
    6164        echo "[$tab]\n";
    62         while ($lista = $sql->fetch(PDO::FETCH_BOTH)) {
     65        while ($lista = $res_comune->fetch(PDO::FETCH_BOTH)) {
    6366                $x=0;
    6467                foreach ($lista as $key=>$val) {$riga[$key]=base64_encode($val);
Note: See TracChangeset for help on using the changeset viewer.