[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date
][Minivend by thread
]
Re: Trouble with Search string! (uppercase/lowercase)
Sounds very promising.
Thank you for helping us to bear our burden of multiple languages and
currencies.
Chris
mikeh@minivend.com wrote:
>
> ****** message to minivend-users from mikeh@minivend.com ******
>
> Quoting mikeh@minivend.com (mikeh@minivend.com):
> >
> > Quoting jojo@buchonline.net (jojo@buchonline.net):
> > >
> > > Search for LLER -> FAILURE!
> > >
> >
> > Here is a little test program that checks this:
> >
> > use POSIX;
> > use locale;
> >
> > print "Current LC_CTYPE locale is ", setlocale(LC_CTYPE), "\n";
> > $string = 'MÜLLER';
> > $target = 'müller';
> >
> > print $string =~ /$target/i ? 'YES' : 'No';
> > print "\n";
> >
> > setlocale(LC_CTYPE, 'de_DE');
> > print "Current LC_CTYPE locale is ", setlocale(LC_CTYPE), "\n";
> >
> > print $string =~ /$target/i ? 'YES' : 'No';
> > print "\n";
> >
> >
> > Works here. Try setting LC_CTYPE to the proper locale before
> > running MV.
> >
>
> No, it doesn't work here on MiniVend. Try adding this line at line 264 of
> Vend/TextSearch.pm:
>
> use locale;
>
> I put it in MV4 and will do some tests to check for it...I might look
> at my LC_.... settings in the setlocale routine as well. It is unclear
> how far I should go in changing locale based on user settings, and I am
> reworking it all anyway. I think I might have a settable array of the
> LC_MONETARY, LANG, LC_CTYPE, and LC_COLLATE that can be accessed by
> the new actions.
>
> Also on the locale front, I am adding an auto-locale setting capability
> with the Accept-Language: header, and I have added a setting that
> looks for (German locale as example) index.de_DE over index.html if
> that is the current locale.
>
> --
> Mike Heins http://www.minivend.com/ ___
> Internet Robotics |_ _|____
> 131 Willow Lane, Floor 2 | || _ \
> It's a little-known fact Oxford, OH 45056 | || |_) |
> that the Y1K problem caused <mikeh@minivend.com> |___| _ <
> the Dark Ages. -- unknown 513.523.7621 FAX 7501 |_| \_\
> -
> To unsubscribe from the list, DO NOT REPLY to this message. Instead, send
> email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
> Archive of past messages: http://www.minivend.com/minivend/minivend-list