Announcement

#1 2017-05-16 00:07:33

dummer-esel
Member
2017-01-25
57

Search albums only

Hello/Hi/Greetings,

I have a request to improve the search:

Currently, all photos are being displayed which can lead to a big mess if you have more than 2.000 photos (but a good album/category structure).

If I search for a word, I'd like to show only galleries in the results.
For example, look in names of the album "path" and also tags, but only display the album (including thumbnail and description) and maybe the path to the album (in case there are more sub-categories).

This would be an awesome feature. For now, I have the search function deactivated because it's useless with this quantity of photoes.

Piwigo version: 2.9.0
PHP version: any
MySQL version: any

Thanks!

Offline

 

#2 2017-08-29 21:09:50

dummer-esel
Member
2017-01-25
57

Re: Search albums only

still a big wish on my list... maybe someone has a solution to this? :-)

Offline

 

#3 2017-08-31 05:43:19

executive
Member
2017-08-16
1214

Re: Search albums only

Should be possible with a simple SQL query. Just need someone with the time to do it.

Offline

 

#4 2017-09-03 01:38:52

dummer-esel
Member
2017-01-25
57

Re: Search albums only

Like what? And where should I put the SQL query?
If you can give me an example, then I can maybe experiment with it... :-)

Offline

 

#5 2017-09-03 05:39:40

executive
Member
2017-08-16
1214

Re: Search albums only

That's all I can tell you without diving into the code. If I start deciphering the code then I might as well do it myself. :)

Offline

 

#6 2017-09-03 11:42:08

dummer-esel
Member
2017-01-25
57

Re: Search albums only

And how do you know then that it's possible with a simple SQL query?

Offline

 

#7 2017-09-03 20:43:57

executive
Member
2017-08-16
1214

Re: Search albums only

You just want me to figure this out for you, don't ya? ;)

Last edited by executive (2017-09-03 20:45:30)

Offline

 

#8 2017-09-03 20:44:50

dummer-esel
Member
2017-01-25
57

Re: Search albums only

That would be awesome! :-D

Offline

 

#9 2017-09-03 20:49:42

executive
Member
2017-08-16
1214

Re: Search albums only

But you need this function, not me. Logic suggests that you should invest the time. Do you have programming experience?

Offline

 

#10 2018-09-24 12:03:35

dummer-esel
Member
2017-01-25
57

Re: Search albums only

executive wrote:

Do you have programming experience?

I have some basics in SQL and PHP... but have never done anything with Piwigo.

In the mysql database I created a query that returns the categories (albums) that have the word 'africa' in the name, plus afterwards the categories that have this word in the comments:

SELECT * FROM `850dS_categories` WHERE name LIKE '%africa%' UNION SELECT * FROM `850dS_categories` WHERE comment LIKE '%africa%'

Now, I guess it would be possible to get all the information to build this standard category box (with image, description, link, ...), however I hope that there already is some kind of funcion/template/?? within Piwigo?

And how can I add a search box and show these results in my gallery?

Offline

 

#11 2018-09-26 05:40:06

executive
Member
2017-08-16
1214

Re: Search albums only

Smartalbum extension

Offline

 

#12 2018-09-26 15:04:04

dummer-esel
Member
2017-01-25
57

Re: Search albums only

executive wrote:

Smartalbum extension

I can't see how this extension solves the problem...?

Offline

 

#13 2018-09-27 05:07:16

executive
Member
2017-08-16
1214

Re: Search albums only

It allows you to create albums based on custom filters.

I thought it's what you meant by "show the results in my gallery". Sorry if I'm wrong.

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2024 · Contact