Search albums by username Search albums by username
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Search albums by username

Started by chrisyew, November 05, 2004, 02:21:48 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

chrisyew

Hi,
I'm trying to seach for all the albums/photos by a particular user, so if I key in the username of that person in the Search of Coppermine, it does not give me any album/photo created by the username. Why is this so and how can I search for all albums/photos created by a user (including those not in the User Gallery)?

Thank you.

Nibbler

You can get latest uploads through the user's profile page. To modify the search, alter include/search.inc.php:

find:
if ($query_all) $sql .= "OR filename LIKE '$match_word' " . "OR title LIKE '$match_word' " . "OR caption LIKE '$match_word' " . "OR user1 LIKE '$match_word' " . "OR user2 LIKE '$match_word' " . "OR user3 LIKE '$match_word' " . "OR user4 LIKE '$match_word' ";

change to :

if ($query_all) $sql .= "OR filename LIKE '$match_word' " . "OR title LIKE '$match_word' " . "OR caption LIKE '$match_word' " . "OR user1 LIKE '$match_word' " . "OR user2 LIKE '$match_word' " . "OR user3 LIKE '$match_word' " . "OR user4 LIKE '$match_word' OR owner_name LIKE '$match_word'";

chrisyew

Hi Nibbler,

Thank you for your info.

The Last Additions in the user's profile - I'm rather confused by the term "Last Additions": do they mean all the photos by that user or only the Last (ten or twenty) Additions?

Will try out the search mod.

Chris Yew

Casper

It is actually all the photos uploaded by that user, in last uploaded order.
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here