webtatic php mbstring将模块添加到centos6.6

时间:2014-12-23 14:06:02

标签: php centos6 mbstring

我一直在使用webtatic php 5.4.34发布来开发facebook应用程序但是突然停止了这个错误 ---------- PHP致命错误:在第306行的/var/www/html/facebook/src/Facebook/HttpClients/FacebookCurlHttpClient.php中调用未定义的函数Facebook \ HttpClients \ mb_strlen() ----------

它需要mbstring模块(这被添加到facebook php函数来解决http头问题而且不能被注释掉,我希望这样做)

Webtatic指令在安装中提到了一个点,我可能有机会选择安装php模块,但是已经安装了php54w我决定升级到php56w,希望这个选项使用mbstring会出现。

所以我现在升级到centos 6.6,然后尝试安装php56w,但得到这个众所周知的错误:php56w-与php54w-common-5.4.34-1.w6.x86_64的常见冲突。

这个解决方案适用于php54w,但正如你现在看不到的那样,你能否提出修复建议

另外,有没有更好的方法来解决丢失的mbstring模块

[root@SECURE21 html]# rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm
Retrieving https://mirror.webtatic.com/yum/el6/latest.rpm
Preparing… ########################################### [100%]
package webtatic-release-6-5.noarch is already installed
[root@SECURE21 html]#
[root@SECURE21 html]#
[root@SECURE21 html]# yum install php56w php56w-opcache
Loaded plugins: fastestmirror, replace
Setting up Install Process
Loading mirror speeds from cached hostfile
* base: anorien.csc.warwick.ac.uk
* extras: mirror.econdc.com
* updates: centos.openitc.uk
* webtatic: uk.repo.webtatic.com
Resolving Dependencies
–> Running transaction check
—> Package php56w.x86_64 0:5.6.2-1.w6 will be installed
–> Processing Dependency: php56w-common(x86-64) = 5.6.2-1.w6 for package: php56w-5.6.2-1.w6.x86_64
–> Processing Dependency: php56w-cli(x86-64) = 5.6.2-1.w6 for package: php56w-5.6.2-1.w6.x86_64
–> Processing Dependency: php56w-cli = 5.6.2-1.w6 for package: php56w-5.6.2-1.w6.x86_64
—> Package php56w-opcache.x86_64 0:5.6.2-1.w6 will be installed
–> Running transaction check
—> Package php56w-cli.x86_64 0:5.6.2-1.w6 will be installed
—> Package php56w-common.x86_64 0:5.6.2-1.w6 will be installed
–> Processing Conflict: php56w-common-5.6.2-1.w6.x86_64 conflicts php-common Finished Dependency Resolution
Error: php56w-common conflicts with php54w-common-5.4.34-1.w6.x86_64
You could try using –skip-broken to work around the problem
You could try running: rpm -Va –nofiles –nodigest
[root@SECURE21 html]#
[root@SECURE21 html]#
[root@SECURE21 html]# yum install yum-plugin-replace
Loaded plugins: fastestmirror, replace
Setting up Install Process
Loading mirror speeds from cached hostfile
* base: anorien.csc.warwick.ac.uk
* extras: mirror.econdc.com
* updates: mirror.for.me.uk
* webtatic: uk.repo.webtatic.com
Package yum-plugin-replace-0.2.7-1.ius.el6.noarch already installed and latest version
Nothing to do
[root@SECURE21 html]# yum replace –enablerepo=webtatic-testing php-common –replace-with=php56w-common
Loaded plugins: fastestmirror, replace
Replacing packages takes time, please be patient…
Error: Package ‘php-common’ is not installed.
[root@SECURE21 html]#

1 个答案:

答案 0 :(得分:1)

我修复了yum install php54w-mbstring。现在facebook代码运行正常。经过几个小时看得太深,它太明显了!