From b4df6129636351cb39829edc6f45e03f9c962d9f Mon Sep 17 00:00:00 2001
From: "Committo,Ergo:sum" <esj@rezo.net>
Date: Thu, 23 Mar 2006 11:21:20 +0000
Subject: [PATCH] =?UTF-8?q?signaler=20qu'un=20element=20de=20la=20base=20e?=
 =?UTF-8?q?st=20ind=C3=A9fini.=20corrige=20#143.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 ecrire/exec/articles.php    | 2 ++
 ecrire/exec/breves_voir.php | 2 +-
 ecrire/exec/mots_edit.php   | 4 ++--
 ecrire/exec/sites.php       | 4 ++--
 4 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/ecrire/exec/articles.php b/ecrire/exec/articles.php
index d1c1856e00..5207078e4c 100644
--- a/ecrire/exec/articles.php
+++ b/ecrire/exec/articles.php
@@ -89,6 +89,8 @@ afficher_hierarchie($id_rubrique);
 
 fin_grand_cadre();
 
+if (!$id_rubrique) {echo _T('public:aucun_article'); exit;}
+
 //
 // Affichage de la colonne de gauche
 //
diff --git a/ecrire/exec/breves_voir.php b/ecrire/exec/breves_voir.php
index c70da1f3dc..37c5ebf3ce 100644
--- a/ecrire/exec/breves_voir.php
+++ b/ecrire/exec/breves_voir.php
@@ -50,7 +50,7 @@ debut_grand_cadre();
 afficher_hierarchie($id_rubrique);
 
 fin_grand_cadre();
-
+if (!$id_rubrique) {echo _T('public:aucune_breve'); exit;}
 debut_gauche();
 
 debut_boite_info();
diff --git a/ecrire/exec/mots_edit.php b/ecrire/exec/mots_edit.php
index 743f0979e8..55dc19bee8 100644
--- a/ecrire/exec/mots_edit.php
+++ b/ecrire/exec/mots_edit.php
@@ -124,7 +124,7 @@ if ($row = spip_fetch_array($result)) {
 	$type = $row['type'];
 	$extra = $row['extra'];
 	$id_groupe = $row['id_groupe'];
-}
+ } else $id_mot = 0;
 
 debut_page("&laquo; $titre_mot &raquo;", "documents", "mots");
 debut_gauche();
@@ -144,7 +144,7 @@ if ($id_mot) {
 	voir_en_ligne ('mot', $id_mot);
 
 	fin_boite_info();
-}
+ } else {echo _T('info_mot_sans_groupe'); exit;}
 
 //////////////////////////////////////////////////////
 // Logos du mot-clef
diff --git a/ecrire/exec/sites.php b/ecrire/exec/sites.php
index bc493f8551..92fa1367b8 100644
--- a/ecrire/exec/sites.php
+++ b/ecrire/exec/sites.php
@@ -256,7 +256,7 @@ if ($row = spip_fetch_array($result)) {
 
 	$extra=$row["extra"];
 	
-	}
+ } else $id_syndic = 0;
 
 if ($nom_site)
 	$titre_page = "&laquo; $nom_site &raquo;";
@@ -277,7 +277,7 @@ afficher_hierarchie($id_rubrique);
 
 fin_grand_cadre();
 
-
+ if (!$id_syndic) {echo _T('public:aucun_site'); exit;}
 
 debut_gauche();
 
-- 
GitLab