PHP gd 庫添加 freetype


gd 庫未安裝 freetype 可能導致驗證碼圖片加載不出來等問題。

  1. 先到 PHP 的擴展目錄里面找到 gd 擴展文件夾
  2. 最好先 make clean 清除之前編譯的可執行文件及配置文件,運行/usr/local/php/bin/phpize。最后編譯安裝
 ./configure --with-php-config=/usr/local/php/bin/php-config --with-jpeg-dir --with-png-dir --with-freetype-dir --with-zlib-dir --with-gd
 make && make install
  1. 重啟服務器


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM