laravel 如何修复对未定义函数的调用 Symfony\Polyfill\Mbstring\iconv_strpos() 问题
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/42361270/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to Fix Call to undefined function Symfony\Polyfill\Mbstring\iconv_strpos() Issue
提问by Karthik
I uploaded my Laravel project to server. It displays following error. How to fix it?
我将我的 Laravel 项目上传到服务器。它显示以下错误。如何解决?
Fatal error: Call to undefined function Symfony\Polyfill\Mbstring\iconv_strpos() in /home/invoice/vendor/symfony/polyfill-mbstring/Mbstring.php on line 358
致命错误:在第 358 行调用 /home/invoice/vendor/symfony/polyfill-mbstring/Mbstring.php 中未定义的函数 Symfony\Polyfill\Mbstring\iconv_strpos()
回答by Manish
回答by Rohan Jalil
You need to install iconv extension.
您需要安装 iconv 扩展。
You need to make sure that php-iconvand php-mbstringare installed on the server. By default, mbstring is not installed on cPanel/WHM servers
您需要确保在服务器上安装了php-iconv和php-mbstring。默认情况下,mbstring 未安装在 cPanel/WHM 服务器上
Easiest way is composer require symfony/polyfill-iconv
最简单的方法是 composer require symfony/polyfill-iconv