Advanced search  

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

Pages: [1]   Go Down

Author Topic: search troubles in custom fields  (Read 3836 times)

0 Members and 1 Guest are viewing this topic.

jardin

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
search troubles in custom fields
« on: December 27, 2005, 06:57:28 pm »

I add seven custom fields applying a technique found in the forum. All is working well except the search function where I'm not able to search in my new fields.

Any idea ?
« Last Edit: December 27, 2005, 11:41:22 pm by GauGau »
Logged

Nibbler

  • Guest
Re: search troubles in custom fields
« Reply #1 on: December 27, 2005, 06:59:38 pm »

What mod are you refering to ?
Logged

jardin

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: search troubles in custom fields
« Reply #2 on: December 27, 2005, 10:11:01 pm »

I applied this mod to CPG 1.4.2

http://forum.coppermine-gallery.net/index.php?topic=7803.0

Result is visible at

http://biereetjardin.free.fr/coppermine/

new custom fields I'm interested in are couleur, precocite, poids (associated with tomates album)

Thanks for help
Logged

Nibbler

  • Guest
Re: search troubles in custom fields
« Reply #3 on: December 27, 2005, 10:40:40 pm »

You need to add the new fields into the list of fields that can be legally searched. Look for this array

Code: [Select]
$allowed = array('title', 'caption', 'keywords', 'owner_name', 'filename', 'pic_raw_ip', 'pic_hrd_ip', 'user1', 'user2', 'user3', 'user4');
in include/search.inc.php and in thumbnails.php and add in the new fields, eg

Code: [Select]
$allowed = array('title', 'caption', 'keywords', 'owner_name', 'filename', 'pic_raw_ip', 'pic_hrd_ip', 'user1', 'user2', 'user3', 'user4', 'user5', 'user6');
Are you using the 1.4 search page ?
Logged

jardin

  • Coppermine newbie
  • Offline Offline
  • Posts: 3
Re: search troubles in custom fields
« Reply #4 on: December 27, 2005, 11:28:11 pm »

Thanks Nibbler,

All is OK now, I forgot to modify the thumbnails.php file
Logged
Pages: [1]   Go Up
 

Page created in 0.026 seconds with 20 queries.