Special Characters in FPDF with PHP

前端 未结 8 1957
陌清茗
陌清茗 2020-12-05 00:16

I have a web form that users can fill out and that content fills up a PDF with FPDF and PHP. When a user enters a word with an apostrophe, a slash appears before it on the P

8条回答
  •  谎友^
    谎友^ (楼主)
    2020-12-05 00:33

    I have used this as $str = preg_replace('/[^A-Za-z0-9_-]/','', $str); for me has been enough, I eliminate the not alphanumerical characters

提交回复
热议问题