How to modify Phoca Gallery Search Plugin?

Phoca Gallery plugins - plugins for Phoca Gallery extension
chandrasecar
Phoca Member
Phoca Member
Posts: 13
Joined: 17 Feb 2010, 21:21

How to modify Phoca Gallery Search Plugin?

Post by chandrasecar »

How to make, that photos are displayed on page after search with preview possibility?

For example on this site it is introduced - http://www.anakaonews.com

It is necessary for my site - http://basemfoto.ru
On my site is installed Phoca Gallery Search Pluggin.

There is file in Joomla: /components/com_search/views/search/tmpl/default_results.php
This file shows results of search.

For example to show a picture it is necessary to write After line 42:

Code: Select all

<?php 
$v="<img src=' /images/phocagallery/thumbs/phoca_thumb_m_act-017.jpg'>";
echo $v;
?>
But for each result there should be shown own picture. The way to a picture should be read out from a database. But how?

There is one more file: /plugins/search/phocagallery.php
In this file written down SQL query to a database. See line 144.

Help please.
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: How to modify Phoca Gallery Search Plugin?

Post by Jan »

Hi, I think you need to customize it, maybe the best way is to try contact the developer of the site you have added here :idea:

Jan
If you find Phoca extensions useful, please support the project
chandrasecar
Phoca Member
Phoca Member
Posts: 13
Joined: 17 Feb 2010, 21:21

Re: How to modify Phoca Gallery Search Plugin?

Post by chandrasecar »

I am the developer. But I badly know PHP & SQL.

It is necessary to read out a picture title in PhocaGallery from a database. Picture name on FTP = picture title in PhocaGallery.
In the given example picture title and picture name is "act-017".
How into this code instead of "act-017" to insert the picture title?

Code: Select all

<?php
$v="<img src=' /images/phocagallery/thumbs/phoca_thumb_m_act-017.jpg'>";
echo $v;
?>
I think, It should work :idea:
User avatar
Jan
Phoca Hero
Phoca Hero
Posts: 48403
Joined: 10 Nov 2007, 18:23
Location: Czech Republic
Contact:

Re: How to modify Phoca Gallery Search Plugin?

Post by Jan »

no experiences there, maybe some str_replace function to replace the image path string :idea:
If you find Phoca extensions useful, please support the project
Post Reply