mbregex compile err: during the first start!

Post support questions that relate to the Windows 2003/2000/XP operating systems.

Moderators: Developers, Moderators

Post Reply
bordione
Posts: 1
Joined: Mon Sep 24, 2007 10:46 am

mbregex compile err: during the first start!

Post by bordione »

Hi,
I'm a new user in this forum and new users on php and I need some help!
system information
Os w2003
apache 2.2
php 5.1.4
cactid 8.6.j for windows
cacti 8.6j

error # 1) I follow all instruction but when I start http://myhost/cacti I have this error
"Warning: mb_ereg_replace() [function.mb-ereg-replace]: mbregex compile err: premature end of char-class in C:\wwwroot\cacti\include\config.php on line 65"
error # 2) I changed (ereg_replace) by (str_replace) to solve this problem but after I had this message
Warning: include(C:\wwwroot\cacti\include/adodb/adodb.inc.php) [function.include]: failed to open stream: No such file or directory in C:\wwwroot\cacti\include\config.php on line 151

error #3) I changed all "/" by "\" in my config.php file but it seems that the program try to search the "lib" information under the "include" directory.
:cry: :cry:
So, I think it's basic problem but I didn't find any solution ...
Thanks Richard
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Post by BSOD2600 »

1) read http://forums.cacti.net/viewtopic.php?t=11747

2) You shouldn't need to be editing source files. What version of mysql did you install?

3) Did you follow my installation guide? if not, please do so.
Filosof
Posts: 1
Joined: Mon Mar 03, 2008 9:38 am

Post by Filosof »

Original Cacti code
(include/global.php, line:86-87)

Code: Select all

$config["base_path"] = strtr(ereg_replace("(.*)[\/\\]include", "\\1", dirname(__FILE__)), "\\", "/");
$config["library_path"] = ereg_replace("(.*[\/\\])include", "\\1lib", dirname(__FILE__));
right code for those, who read php.net^

Code: Select all

$config["base_path"] = strtr(ereg_replace("(.*)[\/\\\\]include", "\\1", dirname(__FILE__)), "\\", "/");
$config["library_path"] = ereg_replace("(.*[\/\\\\])include", "\\1lib", dirname(__FILE__));
User avatar
BSOD2600
Cacti Moderator
Posts: 12171
Joined: Sat May 08, 2004 12:44 pm
Location: USA

Post by BSOD2600 »

If this is a patch, please report it http://www.cacti.net/bugs.php
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

That code has been removed in main branch for the next version of Cacti. No need for a bug report.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest