NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
[resolved] Call to undefined function mb_strlen()


Joined: 21 Jun 2008
Posts: 6
Reply with quote
I get this error when I'm debug-stepping trough my script.
I tried to get the PHP version, it reads 5.2.0.
I'm puzzled. Shocked Please give me a hand.

Code:

<?php
    echo "\n" . phpversion();
    $str = "\nMuzica asta e de doi lei.";
    echo "\n" . mb_strlen ($str, '8bit');
    exit();
    // ...
?>

I found a German forum, where the guy complains that it's code, containing calls to mb_strlen works in the webbrowser, but fails to execute from within the console. Is there a chance that the same problem is here?

I'm in the dark. Please help.

Claudius
View user's profileFind all posts by ciacobSend private message
Guru master

Joined: 05 Jul 2004
Posts: 660
Location: Belgium
Reply with quote
To have support for mb_strlen you need to have the php_mbstring module enabled in your php.ini (disabled by default)
Also, regarding the guy on the forum you mention. It is very possible that the CLI php version uses a different INI file than the webbrowser version.

To figure out which file is used, just use the output of the phpinfo() function, it will tell you what file is being used.
View user's profileFind all posts by BlizzSend private messageVisit poster's website
[resolved] Call to undefined function mb_strlen()
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic