Yeah, I ran into this same problem. If you are doing your own build from
the php source when you run configure you have to make sure to include "
--enable-mbstring" this is not enabled by default in the PHP 5 configure
script. (version 5.1.4 for us)
For example here's the configure command for our php build:
./configure --with-apxs2=/usr/local/apache2/bin/apxs --with-mysql
--with-libxml-dir=/usr/local/lib --with-libiconv-dir=/usr/local/lib
--enable-mbstring
(your paths to apache and other libraries may vary)
then:
make
sudo make install
The above example is a pretty minimal PHP build (you may want other stuff
for other php programs you may run), but this worked for Semantic
Mediawiki.
If you are installing from some rpm or other package utility then the build
you have for that package did not include the multibyte option so it's no
good, try a different package or better yet consider a manual build/install
from source like we do. I find is often much more reliable and I can
include just what I want/need.
By the way I do my own build from source of apache 2, but I was able to get
away with the MySQL rpm that was already in the version of Linux my SA set
up. But in quite often when I set up a new web server I build from source
MySQL also.
Mike
Mike Axelrod
Solution Architect
Enterprise Architecture & Integration Team
Excellus, Inc.
S Page
<[EMAIL PROTECTED]
ink.net> To
Sent by: David Macdonald
semediawiki-user- <[EMAIL PROTECTED]>
[EMAIL PROTECTED] cc
rceforge.net [EMAIL PROTECTED]
net
Subject
10/12/2006 11:46 Re: [Semediawiki-user] Call to
PM undefined function mb_strpos() -
when using wildcards in queries
David Macdonald wrote:
> I've installed SemanticMediawiki version 0.5 in my Wiki. Simple queries
> work okay, but if I put a wildcard in a query, I get a PHP error. A
> sample query:
>
> <ask>[[category:Pc]][[asset:=*]]</ask>
>
> gives this error when the page is previewed or saved:
>
> Fatal error: Call to undefined function mb_strpos() in
>
e:\wikiweb\testwiki\extensions\SemanticMediaWiki\includes\SMW_InlineQueries.php
> on line 416
>
> Versions:
>
> MediaWiki: 1.7.1
> PHP: 5.1.1 (cgi-fcgi)
According to http://us2.php.net/manual/en/function.mb-strpos.php ,
mb_strpos() has always been part of PHP version 5, however you need to
configure in multibyte string support.
http://us2.php.net/manual/en/ref.mbstring.php talks about this.
I'm running the same PHP version (PHP: 5.1.1 (apache2handler)) as part
of the XAMPPLITE Windows bundle and the function works without any
special configuration. My only relevant setting is
extension=php_mbstring.dll (without a semicolon in front) in php5.ini.
Check to see that you have this and the DLL is present in your php\ext
directory. For runtime info about extensions, look for a phpinfo.php in
your Web server and run it, or create a test.php file with just
<?php
phpinfo();
?>
in it and run that.
By the way, SMW uses multibyte-aware functions because a semantic
property could have a special symbol or character in it encoded in
multiple bytes, one of which matches '|'. You *could* reconfigure your
site to use a single-byte encoding like ISO-8559-1 or Windows 1252
(instead of MediaWiki's default UTF-8) and replace mb_strpos() with
strpos(), but that's very limiting.
Good luck,
--
=S Page
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job
easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Semediawiki-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/semediawiki-user
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Semediawiki-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/semediawiki-user