juste un test pour vérifier qu'on ne fait pas un opendir d'un truc qui n'existe pas, et correction d'un petit bug (manquait les points pour concat les chaines)
This commit is contained in:
parent
27ae7510fb
commit
94714d0c41
@ -3,6 +3,7 @@
|
|||||||
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2004 Sebastien Di Cintio <sdicintio@ressource-toi.org>
|
* Copyright (C) 2004 Sebastien Di Cintio <sdicintio@ressource-toi.org>
|
||||||
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
|
* Copyright (C) 2004 Benoit Mortier <benoit.mortier@opensides.be>
|
||||||
|
* Copyright (C) 2004 Eric Seigne <eric.seigne@ryxeo.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU General Public License as published by
|
* it under the terms of the GNU General Public License as published by
|
||||||
@ -62,7 +63,7 @@ if ($_GET["action"] == 'set')
|
|||||||
require_once($file);
|
require_once($file);
|
||||||
|
|
||||||
$obj = new $classname();
|
$obj = new $classname();
|
||||||
$sql = "delete from ".MAIN_DB_PREFIX."expedition_methode where rowid = "$obj->id";";
|
$sql = "delete from ".MAIN_DB_PREFIX."expedition_methode where rowid = ".$obj->id.";";
|
||||||
$db->query($sql);
|
$db->query($sql);
|
||||||
$sql='';
|
$sql='';
|
||||||
$sql = "insert into ".MAIN_DB_PREFIX."expedition_methode (rowid,code,libelle,description,status) VALUES (".$obj->id.",'".$obj->code."','".$obj->name."','".addslashes($obj->description)."',".$_GET["statut"].");";
|
$sql = "insert into ".MAIN_DB_PREFIX."expedition_methode (rowid,code,libelle,description,status) VALUES (".$obj->id.",'".$obj->code."','".$obj->name."','".addslashes($obj->description)."',".$_GET["statut"].");";
|
||||||
@ -167,6 +168,7 @@ print '<td align="center" colspan="2">Actif</td>';
|
|||||||
print '<td align="center" colspan="2">Défaut</td>';
|
print '<td align="center" colspan="2">Défaut</td>';
|
||||||
print "</tr>\n";
|
print "</tr>\n";
|
||||||
|
|
||||||
|
if(is_dir($dir)) {
|
||||||
$handle=opendir($dir);
|
$handle=opendir($dir);
|
||||||
|
|
||||||
while (($file = readdir($handle))!==false)
|
while (($file = readdir($handle))!==false)
|
||||||
@ -220,7 +222,11 @@ while (($file = readdir($handle))!==false)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
closedir($handle);
|
closedir($handle);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
print "<tr><td><b>ERROR</b>: $dir is not a directory !</td></tr>\n";
|
||||||
|
}
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
@ -240,6 +246,7 @@ print "</tr>\n";
|
|||||||
|
|
||||||
clearstatcache();
|
clearstatcache();
|
||||||
|
|
||||||
|
if(is_dir($dir)) {
|
||||||
$handle=opendir($dir);
|
$handle=opendir($dir);
|
||||||
|
|
||||||
while (($file = readdir($handle))!==false)
|
while (($file = readdir($handle))!==false)
|
||||||
@ -291,7 +298,11 @@ while (($file = readdir($handle))!==false)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
closedir($handle);
|
closedir($handle);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
print "<tr><td><b>ERROR</b>: $dir is not a directory !</td></tr>\n";
|
||||||
|
}
|
||||||
print '</table>';
|
print '</table>';
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user