Fork me on GitHub

Rapport de message :*
 

extgallery : resultat recherche avec aperçu image

Titre du sujet : extgallery : resultat recherche avec aperçu image
par Nikita sur 11/02/2009 16:48:38

Bonjour

j'ai refait le fichier search.inc d'extgallery pour pouvoir afficher l'aperçu des images trouvées

voila mon fichier modifié
<?php
function extgallery_search($queryarray$andor$limit$offset$userid){
global 
$xoopsDB;

$sql "SELECT photo_id, photo_title, photo_name, photo_date, uid FROM ".$xoopsDB->prefix("extgallery_publicphoto")." WHERE photo_approved=1";
if ( 
$userid != ) {
$sql .= " AND uid=".$userid." ";
}
if ( 
is_array($queryarray) && $count count($queryarray) ) {
$sql .= " AND ((photo_title LIKE '%$queryarray[0]%')";
for(
$i=1;$i $count;$i++){
$sql .= $andor " ;
$sql .= "(photo_title LIKE '%$queryarray[$i]%')";
}
        
$sql .= ") ";
    }
$sql .= "ORDER BY photo_date DESC" // si condition de tri
$result $xoopsDB->query($sql,$limit,$offset);

$ret = array();
$i 0;
while(
$myrow $xoopsDB->fetchArray($result)){
$ret[$i]['image'] = "../../uploads/extgallery/public-photo/thumb/thumb_".$myrow['photo_name']."";
$ret[$i]['link'] = "public-photo.php?photoId==".$myrow['photo_id'].""// lien sur la page qui affichera le texte
$ret[$i]['title'] = $myrow['photo_title'];
$ret[$i]['time'] = $myrow['photo_date'];
$ret[$i]['uid'] = $myrow['uid']; $i++;
} return 
$ret;

?>


j'aimerais maintenant que cette vignette soit affichée mais en taille plus réduite , quelqu'un peut m'aider ?
Propulsé avec XOOPS | Graphisme adapté par Tatane, Grosdunord, Montuy337513

61 Personne(s) en ligne (51 Personne(s) connectée(s) sur Forum) | Utilisateur(s): 0 | Invité(s): 61 | Plus ...