PhpDig.net

PhpDig.net (http://www.phpdig.net/forum/index.php)
-   Troubleshooting (http://www.phpdig.net/forum/forumdisplay.php?f=22)
-   -   Warning: mb_ereg_replace() [function.mb-ereg-replace] ... (http://www.phpdig.net/forum/showthread.php?t=1869)

kaffeebronko 02-22-2005 05:13 AM

Warning: mb_ereg_replace() [function.mb-ereg-replace] ...
 
Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/lightpower.de/htdocs/suche/libs/search_functions.php on line 174

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/lightpower.de/htdocs/suche/libs/search_functions.php on line 175

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/lightpower.de/htdocs/suche/libs/search_functions.php on line 176

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/lightpower.de/htdocs/suche/libs/search_functions.php on line 177

:what:

kaffeebronko 02-22-2005 05:15 AM

Warning: mb_ereg_replace() [function.mb-ereg-replace] ...
 
Hi!
I'm trying to get phpdig running... I got all the pages indexed correctly but when I try to search this comes out:
(can anybody help me please? -> thx!)

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/xxx/htdocs/suche/libs/search_functions.php on line 174

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/xxx/htdocs/suche/libs/search_functions.php on line 175

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/xxx/htdocs/suche/libs/search_functions.php on line 176

Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in /home/xxx/htdocs/suche/libs/search_functions.php on line 177
:what:

Charter 02-22-2005 04:44 PM

What versions: PHP, MySQL, PhpDig?

kaffeebronko 02-22-2005 11:50 PM

Sorry...

PHP 5.0.3
MySQL 4.1.10
PhpDig 1.8.8-rc1

Charter 02-22-2005 11:55 PM

Do you have the .htaccess file that came with PhpDig 1.8.8 RC1 in your PhpDig directory?

kaffeebronko 02-23-2005 12:59 AM

Yes, this is the content at the moment ( I didn't change anything...)

# start htaccess file
PHP_VALUE default_charset UTF-8
PHP_VALUE mbstring.func_overload 0
PHP_VALUE mbstring.encoding_translation On
# end htaccess file

Charter 02-23-2005 01:01 AM

Try changing PHP_VALUE mbstring.func_overload 0 to PHP_VALUE mbstring.func_overload 7

kaffeebronko 02-23-2005 01:27 AM

I tried that in the php.ini yesterday. But anyway I tried it in the .htaccess - file after your posting, but it didn't seem work. Do you know any other hint? Would be cool... thanks.

Charter 02-23-2005 01:37 AM

You can set PHP_VALUE mbstring.func_overload 7 back to PHP_VALUE mbstring.func_overload 0 in the .htaccess file, as zero is what I considered when I made the code.

The thing is that the robot_functions.php file has similar statements, so it's weird that you didn't see errors like this when indexing, or did you?

kaffeebronko 02-23-2005 01:47 AM

While Indexing the sites the program works very well... all things are ok... I proved it in the database. Only if I to search with the search.php script then I see this Warnings...

Charter 02-23-2005 02:19 AM

Did you change any of the code? Again weird, because robot_functions.php contains similar statements, oh and so does phpdig_functions.php. :confused:

kaffeebronko 02-23-2005 02:42 AM

No I didn't change any of the code... I did a fresh install 3 times. The last time I just edited the /includes/config.php and the /includes/connect.php..

connect.php:

define('PHPDIG_DB_PREFIX','');
define('PHPDIG_DB_HOST','localhost');
define('PHPDIG_DB_USER','xxx');
define('PHPDIG_DB_PASS','xxx');
define('PHPDIG_DB_NAME','phpdig');

and in the config.php I changed:

define('PHPDIG_ADM_AUTH','1'); // activates/deactivates login
define('PHPDIG_ADM_USER','xxx'); // login username
define('PHPDIG_ADM_PASS','xxx'); // login password

That's the only things I changed in my last install...

Charter 02-23-2005 02:46 AM

Are you able to try PhpDig 1.8.8 RC1 on PHP 4.3.10?

kaffeebronko 02-23-2005 03:13 AM

yes... will take a moment... I'll try to downgrade the testserver...

Charter 02-23-2005 04:02 AM

Okay, cool. I don't yet see why robot_functions.php and phpdig_functions.php work okay but search_functions.php barfs.

kaffeebronko 02-23-2005 05:11 AM

ok... I downgraded my PHP to 4.3.10. The Warn-Messages don't appear again, but no search results... I'm sure that the tested words are spidered and in the database.
What could that be? Maybe you can help me?

Charter 02-23-2005 05:26 AM

What language are the pages you indexed?

kaffeebronko 02-23-2005 05:30 AM

english and german but mostly german...

Charter 02-23-2005 05:37 AM

What if you search on a word without umlauts?

kaffeebronko 02-23-2005 05:49 AM

nothing... no search results... :-( mmmm... I got no idea...

Charter 02-23-2005 05:57 AM

Maybe something weird happened with PHP v.5.0.3, but I'm just not sure. Try using define('DETECT_ORDER','UTF-8,ISO-8859-1,ASCII'); in the config file, install new PhpDig tables using a different prefix, make sure the new prefix is in the connect.php file, and index a few pages. Let me know if you get results.

kaffeebronko 02-23-2005 07:03 AM

Thanks! That was it!
I used your new define row and deleted the database for the phpdig-program.
Then I updated the script and Indexed the site one again... This time it works! ;-)

I hope it was helping you too for debugging your software...

kaffeebronko 02-23-2005 10:56 PM

Hi! It's me again... It dosen't seem work at a PHP 5.0.3 System. When I modify the code with your new define row while I'm using PHP 4.3.10 all works fine. But when I upgradet to php 5 again the search script don't works...

Charter 02-26-2005 07:35 PM

I'm not sure why PhpDig v.1.8.8 RC1 and PHP v.5.0.3 don't get along. Perhaps there is a new option that needs to be set, but I don't have an answer at the moment.


All times are GMT -8. The time now is 02:41 AM.

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 2001 - 2005, ThinkDing LLC. All Rights Reserved.