From 179450cce05c34184210be43d6e6eddfe4bffe95 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 28 Aug 2004 12:18:14 +0000 Subject: [PATCH] Fix: register_globals=off Qual: Utilisation de la fonction commune form_confirm au lieu du code en dur. --- htdocs/comm/action/fiche.php | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/htdocs/comm/action/fiche.php b/htdocs/comm/action/fiche.php index 37b0831be72..08dd7e467a4 100644 --- a/htdocs/comm/action/fiche.php +++ b/htdocs/comm/action/fiche.php @@ -115,7 +115,7 @@ if ($_POST["action"] == 'add_action') if ($_POST["action"] == 'confirm_delete' && $_POST["confirm"] == 'yes') { $actioncomm = new ActionComm($db); - $actioncomm->delete($id); + $actioncomm->delete($_GET["id"]); Header("Location: index.php"); } @@ -312,21 +312,7 @@ if ($_GET["id"]) // Confirmation suppression action if ($_GET["action"] == 'delete') { - print '
'; - print ''; - print ''; - - print ''; - - print '\n"; - print ''; - print '
Supprimer l\'action
Etes-vous sur de vouloir supprimer cette action ?'; - $htmls = new Form($db); - - $htmls->selectyesno("confirm","no"); - - print "
'; - print "
\n"; + $html->form_confirm("fiche.php?id=".$_GET["id"],"Supprimer l'action","Etes-vous sûr de vouloir supprimer cette action ?","confirm_delete"); } $act = new ActionComm($db); @@ -375,7 +361,7 @@ if ($_GET["id"]) // Affichage fiche action en mode visu print_titre ("Action commerciale"); - print ''; + print '
'; print ''; print ''; print ''; @@ -383,7 +369,7 @@ if ($_GET["id"]) print ''; print ''; print ''; - print ''; + print ''; if ($act->objet_url) { print '';
Type'.$act->type.'
Société'.$act->societe->nom.'Contact'.$act->contact->fullname.'
'.$langs->trans("Author").''.strftime('%d %B %Y %H:%M',$act->date).''.$langs->trans("Author").''.$act->author->fullname.'
Pourcentage réalisé'.$act->percent.' %
Pourcentage réalisé'.$act->percent.' %
Objet lié