| Line 19... |
Line 19... |
| 19 |
// | |
|
19 |
// | |
|
| 20 |
// | You should have received a copy of the GNU General Public License |
|
20 |
// | You should have received a copy of the GNU General Public License |
|
| 21 |
// | along with Foobar; if not, write to the Free Software |
|
21 |
// | along with Foobar; if not, write to the Free Software |
|
| 22 |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
22 |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
| 23 |
// +------------------------------------------------------------------------------------------------------+
|
23 |
// +------------------------------------------------------------------------------------------------------+
|
| 24 |
// CVS : $Id: more_recherche.class.php,v 1.3 2005-05-19 12:46:12 jpm Exp $
|
24 |
// CVS : $Id: more_recherche.class.php,v 1.4 2005-05-25 13:49:22 jpm Exp $
|
| 25 |
/**
|
25 |
/**
|
| 26 |
* Classe permettant d'effectuer des recherches sur les métas informations des menus.
|
26 |
* Classe permettant d'effectuer des recherches sur les métas informations des menus.
|
| 27 |
*
|
27 |
*
|
| 28 |
* Permet de rechercher et classer les menus en fonction d'une chaine.
|
28 |
* Permet de rechercher et classer les menus en fonction d'une chaine.
|
| 29 |
*
|
29 |
*
|
| Line 32... |
Line 32... |
| 32 |
//Auteur original :
|
32 |
//Auteur original :
|
| 33 |
*@author Jean-Pascal MILCENT <jpm@tela-botanica.org>
|
33 |
*@author Jean-Pascal MILCENT <jpm@tela-botanica.org>
|
| 34 |
//Autres auteurs :
|
34 |
//Autres auteurs :
|
| 35 |
*@author aucun
|
35 |
*@author aucun
|
| 36 |
*@copyright Tela-Botanica 2000-2004
|
36 |
*@copyright Tela-Botanica 2000-2004
|
| 37 |
*@version $Revision: 1.3 $ $Date: 2005-05-19 12:46:12 $
|
37 |
*@version $Revision: 1.4 $ $Date: 2005-05-25 13:49:22 $
|
| 38 |
// +------------------------------------------------------------------------------------------------------+
|
38 |
// +------------------------------------------------------------------------------------------------------+
|
| 39 |
*/
|
39 |
*/
|
| Line 40... |
Line 40... |
| 40 |
|
40 |
|
| 41 |
// +------------------------------------------------------------------------------------------------------+
|
41 |
// +------------------------------------------------------------------------------------------------------+
|
| Line 115... |
Line 115... |
| 115 |
if ($a['poids'] = $b['poids']) {
|
115 |
if ($a['poids'] = $b['poids']) {
|
| 116 |
return 0;
|
116 |
return 0;
|
| 117 |
}
|
117 |
}
|
| 118 |
}
|
118 |
}
|
| 119 |
usort($aso_resultats, 'comparer');
|
119 |
usort($aso_resultats, 'comparer');
|
| - |
|
120 |
$pds_max = 0;
|
| - |
|
121 |
if (isset($aso_resultats[0]['poids'])) {
|
| 120 |
$pds_max = $aso_resultats[0]['poids'];
|
122 |
$pds_max = $aso_resultats[0]['poids'];
|
| - |
|
123 |
}
|
| 121 |
for ($i = 0 ; $i < count($aso_resultats) ; $i++) {
|
124 |
for ($i = 0 ; $i < count($aso_resultats) ; $i++) {
|
| 122 |
$aso_resultats[$i]['score'] = round((100 / $pds_max) * $aso_resultats[$i]['poids'], 1);
|
125 |
$aso_resultats[$i]['score'] = round((100 / $pds_max) * $aso_resultats[$i]['poids'], 1);
|
| 123 |
}
|
126 |
}
|
| Line 124... |
Line 127... |
| 124 |
|
127 |
|
| Line 172... |
Line 175... |
| 172 |
}
|
175 |
}
|
| Line 173... |
Line 176... |
| 173 |
|
176 |
|
| 174 |
/* +--Fin du code ----------------------------------------------------------------------------------------+
|
177 |
/* +--Fin du code ----------------------------------------------------------------------------------------+
|
| 175 |
*
|
178 |
*
|
| - |
|
179 |
* $Log: not supported by cvs2svn $
|
| - |
|
180 |
* Revision 1.3 2005/05/19 12:46:12 jpm
|
| - |
|
181 |
* Correction bogue accesskey.
|
| - |
|
182 |
* Ajout d'un id à la liste.
|
| - |
|
183 |
* Arrondissement des score.
|
| 176 |
* $Log: not supported by cvs2svn $
|
184 |
*
|
| 177 |
* Revision 1.2 2005/04/14 17:39:34 jpm
|
185 |
* Revision 1.2 2005/04/14 17:39:34 jpm
|
| 178 |
* Amélioration du moteur de rechercher :
|
186 |
* Amélioration du moteur de rechercher :
|
| 179 |
* - pourcentage
|
187 |
* - pourcentage
|
| 180 |
* - ajout d'info
|
188 |
* - ajout d'info
|