dongmi4035 2010-12-31 16:39
浏览 36

在从MYSQL中提取的数据上显示PHP的重音

I'm pretty sure I'm missing something basic, but I can't figure out what it is. Everything should be default characterset (I haven't specified or changed anything) which I assume is Latin1. This should be fine as all the characters I need are in Latin1 (most questions seem directed at changing charset to utf-8).

I used copy and paste from an HTML page with charset=iso-8859-1 to insert some letters with acutes and umlauts into a MYSQL database, which shows up fine when selected from the commandline. However well I select these in a PHP script and display with iso-8859-1 as the browser encoding, they show up as commas or apostrophes only.

ä = „ ö = ” é = ‚ á = (a blank)

If I just copy and paste these vowels below the actual php tags, they display correctly.

  • 写回答

2条回答 默认 最新

  • duanji1899 2010-12-31 16:43
    关注

    Try using htmlentities()

    I think that worked for me in the past.

    评论

报告相同问题?

悬赏问题

  • ¥15 神经网络预测均方误差很小 但是图像上看着差别太大
  • ¥15 Oracle中如何从clob类型截取特定字符串后面的字符
  • ¥15 想通过pywinauto自动电机应用程序按钮,但是找不到应用程序按钮信息
  • ¥15 如何在炒股软件中,爬到我想看的日k线
  • ¥15 seatunnel 怎么配置Elasticsearch
  • ¥15 PSCAD安装问题 ERROR: Visual Studio 2013, 2015, 2017 or 2019 is not found in the system.
  • ¥15 (标签-MATLAB|关键词-多址)
  • ¥15 关于#MATLAB#的问题,如何解决?(相关搜索:信噪比,系统容量)
  • ¥500 52810做蓝牙接受端
  • ¥15 基于PLC的三轴机械手程序