Case Sensitive Searching on IIS hosted Coppermine Case Sensitive Searching on IIS hosted Coppermine
 

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Main Menu

Case Sensitive Searching on IIS hosted Coppermine

Started by cnl24, March 05, 2007, 08:38:23 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

cnl24

Hi,
We have a customer hosting on our Windows 2003 server and would like to know how to use case sensitive searching on their website? They are a professional photographer and have a huge library of photos that can be searched so this is an essential thing for them. I am no programmer, so if anyone has a solution then please can you give it to me in some kind of english  :)
Many thanks in advance,
CNL24

Nibbler

Best way is to use a case sensitive collation in the db. If you don't want to edit the db then you'd need to make a code change each time you update Coppermine.

include/search.inc.php

find

if (in_array($param, $allowed))$fields[] = "$param LIKE '%$word%'";

change to

if (in_array($param, $allowed))$fields[] = "$param LIKE BINARY '%$word%'";