dongzheng4556 2014-03-23 21:50
浏览 17
已采纳

关于MySQL变量的回声的PHP ucwords

I have the following php echo from a MySQL query that works fine except that the city is all uppercase in database.

Referencing the PHP manual here, it appears ucwords should fit the bill?

Works:

echo ($row['City']);

I tried this but it still shows the city as all uppercase?

echo ucwords($row['City']);
  • 写回答

4条回答 默认 最新

  • douyi2664 2014-03-23 21:52
    关注

    How about

    echo ucwords(strtolower($row['City']));
    
    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(3条)

报告相同问题?