#19874 [WFx]: Compile error related to readlin

From: Date: Tue, 28 Jan 2003 21:27:17 +0000
Subject: #19874 [WFx]: Compile error related to readlin
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-31503@lists.php.net to get a copy of this message
ID: 19874 User updated by: hz11@nyu.edu -Summary: Case-insensitive strpos() Reported By: hz11@nyu.edu Status: Wont fix Bug Type: Feature/Change Request -Operating System: All +Operating System: FreeBSD 4.6.2-RELEASE -PHP Version: 4.3.0-pre1 +PHP Version: 4.2.2 New Comment: Yeah, this is the obvious way around it, but it's pretty crude. I use strpos() for speed, especially on large string, and if you need to first copy the entire string and convert it lowercase, I might as well use stristr(). Implementing stripos() would be so trivial, I can't see a reason not to do it. I'd do it myself, however, to keep the quality of PHP high, it'd be better for someone with Zend/PHP C experience to write it. Could stripos() be available in the next minor point release even? Many thanks, Hans Previous Comments: ------------------------------------------------------------------------ [2003-01-28 15:10:51] pollita@php.net Consider using: $position = strpos(strtolower($haystack),strtolower($needle)); ------------------------------------------------------------------------ [2002-10-11 20:29:09] hz11@nyu.edu Maybe I'm missing something, but a case-insensitive strpos() would be handy. Yeah, there's obvious ways around it, but a native function would be great. Regards, Hans ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=19874&edit=1

« previous php.bugs (#31503) next »