将从Windows下开发好的代码转移至CentOS下,发现验证码不能显示。
访问验证码页面显示以下错误:
Warning: imagettftext() [
function.imagettftext]: Could not find/open font in
/usr/local/apache2/htdocs/slms/include/yzm.php on line
24
经过搜索发现,linux不支持相对路径,汗。
经过搜索发现,linux不支持相对路径,汗。
所以只能将路径写全了。
/usr/local/apache2/htdocs/slms/include/arial.ttf
本文转自yuhaijunll 51CTO博客,原文链接:http://blog.51cto.com/yuhaijunll/191449,如需转载请自行联系原作者