type)."', name='".addslashes($p->name)."', requete='".addslashes($p->requete)."', comment='".addslashes($p->comment)."', autorisations='1', parameters='".addslashes($p->parameters)."' "; echo $exp ; } break; case "empr_caddie" : header("Content-Type: application/download\n"); header("Content-Disposition: atachement; filename=\"empr_caddie_proc_".$id.".sql\""); $req="select type, name, requete, comment, autorisations, parameters from empr_caddie_procs where idproc='$id' "; $res = mysql_query($req,$dbh); if ($p=mysql_fetch_object($res)) { $exp="INSERT INTO empr_caddie_procs set type='".addslashes($p->type)."', name='".addslashes($p->name)."', requete='".addslashes($p->requete)."', comment='".addslashes($p->comment)."', autorisations='1', parameters='".addslashes($p->parameters)."' "; echo $exp ; } break; case "actionsperso" : header("Content-Type: application/download\n"); header("Content-Disposition: atachement; filename=\"admin_proc_".$id.".sql\""); $req="select name, requete, comment, autorisations, parameters from procs where idproc='$id' "; $res = mysql_query($req,$dbh); if ($p=mysql_fetch_object($res)) { $exp="INSERT INTO procs set name='".addslashes($p->name)."', requete='".addslashes($p->requete)."', comment='".addslashes($p->comment)."', autorisations='1', parameters='".addslashes($p->parameters)."' "; echo $exp ; } break; } break; } mysql_close($dbh);