source: trunk/admin/modules/Elezioni/backup.php@ 284

Last change on this file since 284 was 284, checked in by roby, 6 years ago
File size: 762 bytes
RevLine 
[2]1<?php
2$param=strtolower($_SERVER['REQUEST_METHOD']) == 'get' ? $_GET : $_POST;
3if (isset($param['id_cons_gen']))
4 $id_cons_gen2=intval($param['id_cons_gen']);
5if (isset($param['id_comune']))
6 $id_comune2=intval($param['id_comune']);
[256]7$sql="select descrizione from ".$prefix."_ele_consultazione where id_cons_gen='$id_cons_gen2'";
8$sth = $dbi->prepare("$sql");
9$sth->execute();
[284]10//$row = $sth->fetch(PDO::FETCH_BOTH);
11//$nomeFile=$row[0];
12list($nomeFile)=$sth->fetch(PDO::FETCH_NUM);
[2]13#$nomeFile="backup";
14header( 'Content-Type: application/octet-stream' );
15header( 'Content-Disposition: attachment; filename="'.$nomeFile.'"' );
16#header( 'Content-Length:'.strlen( $content ) );
17header( 'Content-Transfer-Encoding: binary' );
18include("backup2.php");
19exit(0);
20
21?>
Note: See TracBrowser for help on using the repository browser.