Changeset 70480 in spip-zone for _plugins_/selection_d_objets/branches/1/selection_objet_fonctions.php
- Timestamp:
- Mar 6, 2013, 4:44:21 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
_plugins_/selection_d_objets/branches/1/selection_objet_fonctions.php
r70395 r70480 35 35 /*Etablit le titre de l'objet*/ 36 36 function titre_objet_sel($objet,$contexte){ 37 37 38 $exceptions=charger_fonction('exceptions','inc'); 38 39 $exception_titre=$exceptions('titre'); … … 44 45 $titre=$f[1]; 45 46 } 46 elseif($objet) $titre=$objet.'_'.$id_objet; 47 elseif($objet){ 48 $table_sql = table_objet_sql($objet); 49 $tables=lister_tables_objets_sql(); 50 $titre_objet=_T($tables[$table_sql]['texte_objet']); 51 $id=$contexte['id_objet']; 52 if($objet='selection_objet')$id=$contexte['id_selection_objet']; 53 $titre=$titre_objet.' '.$id; 54 } 47 55 48 56 } … … 137 145 $exception_objet=$exceptions(); 138 146 139 140 if($exception_objet['objet'][$objet]){147 if($objet){ 148 if($exception_objet['objet'][$objet]){ 141 149 $objet=$exception_objet['objet'][$objet]; 142 150 $table='spip_'.$objet; 143 } 144 else $table='spip_'.$objet.'s'; 145 if(!$where)$where='id_'.$objet.'='.$id_objet; 146 147 if(!$contexte=sql_fetsel('*',$table,$where))$contexte=array(); 148 151 } 152 else $table='spip_'.$objet.'s'; 153 if(!$where)$where='id_'.$objet.'='.$id_objet; 154 155 if(!$contexte=sql_fetsel('*',$table,$where))$contexte=array(); 156 157 } 158 else $contexte=array(); 159 149 160 //Filtrer les champs vides 150 161 foreach($env as $k=>$v){
Note: See TracChangeset
for help on using the changeset viewer.