ClipBucket 修正影片標題中文內容被截取成亂碼

主要是因為truncate對於中文的辨識不太正確
以至於會把中文拆解錯誤,因此需要修改 modifier.truncate.php

參考了網路上的文章:讓 Smarty 的 truncate 支援 UTF-8 的方法
就開始來動手吧

vim /var/www/html/includes/templatelib/plugins/modifier.truncate.php

這裡主要是要把function smarty_modifier_truncate這個function的內容整個置換掉

然後就可以了~
記得要順便修改video.html
不然會發現他怎麼把所有的中文字都叫出來了

vim /var/www/html/styles/cbv2new/layout/blocks/video.html

This entry was posted in ClipBucket. Bookmark the permalink.