Developers corner > Developer Lobby

Joomla Search


Im trying to get the joomla search to show thumbnails from rsgallery. ive spoken to joymonkey who has it functioning on his website however he is using a previous version 1.12?. here are the changes to the rsgallery search bot.

   $linkurl = $mosConfig_live_site."/index.php?option=com_rsgallery2&page=inline";
   $thumburl = $mosConfig_live_site."/index.php?option=com_rsgallery2&page=getthumb&id=";
   $link = $mosConfig_live_site."/".$imagedir."";
   //. "\n CONCAT('$linkurl','&id=',,'&catid=',a.gallery_id,'&limitstart=',a.ordering-1) AS href"
   $query = "SELECT CONCAT('<div>',a.title,'</div>') AS title,"
   . "\n a.descr AS text,"
   . "\n a.params AS text,"
   . "\n AS created,"
   . "\n '0' AS browsernav,"
   . "\n CONCAT('\"></a><img style=\"float:left;padding-right:10px;\" src=\"','$thumburl',,'\"> <a href=\"$linkurl','&id=',,'&catid=',a.gallery_id,'&limitstart=',a.ordering-1) AS href"
   . "\n FROM jos_rsgallery2_files AS a"
   . "\n INNER JOIN jos_rsgallery2_galleries"
   . "\n ON"
   . "\n WHERE ($where)"
   . "\n AND jos_rsgallery2_galleries.published = 1"
   . "\n ORDER BY $order"
   $database->setQuery( $query, 0, $limit );

this basically outputs the URL of thumbnail and adds the image.

my gallery isnt displaying the thumbnail so im guessing the generation of the thumb URL has changed since version 1.12. im using latest 1.14.

can anyone tell me how to generate the thumbnail URL or how i can mod the rsgallery2.searchbot.php to show the images.

the reason for trying to change the joomla search instead of the rsgallery 2 search is that it cant handle 2 words which are not a phrase. e.g. in my params i have "bike race 12"

a search for "bike 12" would not return that image.

many thanks


 all im after is how to dynamically get the thumb url.


i guess the url for the thumb would be :

--- Code: ---CONCAT ($mosConfig_live_site.,  '/images/rsgallery/thumb/' , , '.jpg')

--- End code ---


JJ Choo:
Hi, anyone already got this working, please share the code. Thanks.


[0] Message Index

Go to full version