RE: [PHP-DB] What is REG_BADRPT, and why do I get it?

From: Date: Thu, 17 Jan 2002 10:21:33 +0000
Subject: RE: [PHP-DB] What is REG_BADRPT, and why do I get it?
Groups: php.db 
Request: Send a blank email to php-db+get-15926@lists.php.net to get a copy of this message
It's not anything to do with the special regular expression characters again is it? -----Original Message----- From: Beau Lebens [mailto:B.Lebens@curtin.edu.au] Sent: 17 January 2002 01:38 To: 'Markus Lervik'; php-db@lists.php.net Subject: RE: [PHP-DB] What is REG_BADRPT, and why do I get it? on a guess - echo the value of $search_name in between each call to see what happens to it as it goes through - you may find that something is going haywire in there somewhere (or that it's blank) -b // -----Original Message----- // From: Markus Lervik [mailto:markus.lervik@vaasa.fi] // Sent: Monday, 14 January 2002 9:42 PM // To: php-db@lists.php.net // Subject: [PHP-DB] What is REG_BADRPT, and why do I get it? // // // // Hello! // // I have quite a weird problem. When I use ereg or ereg_replace // I get a REG_BADRPT warning, like so : // // Warning: REG_BADRPT in /var/www/html/mag/search.php on line 35 // Warning: REG_BADRPT in /var/www/html/mag/search.php on line 36 // // The offending lines are // // if(ereg("*",$search_name)) { ereg_replace("*","%",$search_name); } // if(ereg("?",$search_name)) { ereg_replace("?","_",$search_name); } // // but just two lines above them I have // // if(ereg("*",$search_id)) { ereg_replace("*","%",$search_id); } // if(ereg("?",$search_id)) { ereg_replace("?","_",$search_id); } // // and two similar lines of code below them, yet PHP doesn't complain // about them. Anyone have any ideas as to what's causing the warning? // // // Cheers, // Markus // // -- // Markus Lervik // Linux-administrator with a kungfoo grip // Vaasa City Library - Regional Library // markus.lervik@vaasa.fi // +358-6-325 3589 / +358-40-832 6709 // // -- // PHP Database Mailing List (http://www.php.net/) // To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net // For additional commands, e-mail: php-db-help@lists.php.net // To contact the list administrators, e-mail: // php-list-admin@lists.php.net // -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net For additional commands, e-mail: php-db-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net --- Incoming mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.314 / Virus Database: 175 - Release Date: 11/01/02 --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.314 / Virus Database: 175 - Release Date: 11/01/02

« previous php.db (#15926) next »