php_extension mbstring is recommended to be installed/enabled
Anybody able to tell me:
a) will this improve speed or functionality of my installation
b) how to do it if it will benefit my site!
starting with Moodle 1.5 and widely used in next Moodle 1.6 a lot of strings functions are being processed by a new text library in order to be able to handle different charsets properly, specially the UTF-8 one.
This library tries to do its work by using the mbstring or iconv libraries and, if they aren't present, a fallback mechanism to use internal functions is used instead. As these internal functions are written in PHP code, they will be slower that their mbstring/iconv counterparts.
And this is the primary reason to recommend mbstring/iconv. They are solid libraries and pretty faster than the alternative internal (PHP) functions.
Hope this helps!
Are you using Linux or Windows and do you have a hosted moodle or direct access? Also it would be helpful if you could attach your php.ini and your the output from phpinfo (in moodle 1.6 this is in Administration, Miscellaneous, Environment - there is a button at the bottom of the page).
I am using Windows and it is direct access. Attached is the php.ini file. How would you like me to display the phpinfo file?
For the phpinfo, there is a more efficient method: at the command prompt, type php -i > phpinfo.txt. Attach the phpinfo.txt to your post.
php ver 5.1.2
php_mbstring.dll does exist and is version 126.96.36.199
Multibyte Support => enabled
Multibyte string engine => libmbfl
Multibyte (japanese) regex support => enabled
Multibyte regex (oniguruma) version => 3.7.1
So all's well and your php is using the library in the background.
I Appreciate all the help and time this has taken.
I have linux (RH enterprice 4) and need help installin or enable the MSBTRING. i need to recompilate de Php, instaling a RPM or editing the php.ini.
muy amable por responder tan rápido ;)
Please guys i have same question of Jose. I really need answer. I'd like to enable the mbstring under Linux. The following is the mbstring section in my php.ini. Should i change or uncomment anything to enable it.
; language for internal character representation.
; internal/script encoding.
; Some encoding cannot work as internal encoding.
; (e.g. SJIS, BIG5, ISO-2022-*)
;mbstring.internal_encoding = EUC-JP
; http input encoding.
;mbstring.http_input = auto
; http output encoding. mb_output_handler must be
; registered as output buffer to function
;mbstring.http_output = SJIS
; enable automatic encoding translation accoding to
; mbstring.internal_encoding setting. Input chars are
; converted to internal encoding by setting this to On.
; Note: Do _not_ use automatic encoding translation for
; portable libs/applications.
;mbstring.encoding_translation = Off
; automatic encoding detection order.
; auto means
;mbstring.detect_order = auto
; substitute_character used when character cannot be converted
; one from another
;mbstring.substitute_character = none;
; overload(replace) single byte functions by mbstring functions.
; mail(), ereg(), etc are overloaded by mb_send_mail(), mb_ereg(),
; etc. Possible values are 0,1,2,4 or combination of them.
; For example, 7 for overload everything.
; 0: No overload
; 1: Overload mail() function
; 2: Overload str*() functions
; 4: Overload ereg*() functions
;mbstring.func_overload = 0