dongling5411 2019-04-28 00:37
浏览 192
已采纳

将emojis从php web app传递到Oracle db和mysql

We have an php (codeigniter) web app that sending sms's. the db we connected to is oracle. when some customer trying to send emoji throgh our webapp the emoji is not displayed well on the message in the mobile phone. we can see the emoji in sql plus but it not displeyed well on pl sql. we assuming it related to some encoding issue but can't point to the exact problem.

the flow is like that

  1. PHPinsert into oracle.
  2. Java that take lines from oracle to mysql.
  3. Insert into mysql.
  4. Send as message to mobile phone.

for example :

This is how it looks in php text area :

img1

this is how it looks with PL/SQL after insert to oracle:

img1

this is how it looks with SQL PLUS after insert to oracle :

img1

and this is how it looks in mysql:

img1

and also in the mobile phone message:

img1

The charset in mysql and oracle is utf8mb4

we tryed to change the query in php to be like insert into sms(messaage) values(?) we tried to change the type of the column from varchar2 to clob

edit

the connection from the PHP to oracle is set well i think ,as you can see here:

img1

  • 写回答

1条回答 默认 最新

  • dp815292 2019-04-30 01:51
    关注

    i have found the solution . needed to change the connection charset from php to oracle to be 'AL32UTF8' insted of 'utf8'. now it works great. thank you

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
编辑
预览

报告相同问题?

悬赏问题

  • ¥15 TMUXHS4412如何防止静电,
  • ¥30 Metashape软件中如何将建模后的图像中的植被与庄稼点云删除
  • ¥20 机械振动学课后习题求解答
  • ¥15 IEC61850 客户端和服务端的通讯机制
  • ¥15 MAX98357a(关键词-播放音频)
  • ¥15 Linux误删文件,请求帮助
  • ¥15 IBMP550小型机使用串口登录操作系统
  • ¥15 关于#python#的问题:现已知七自由度机器人的DH参数,利用DH参数求解机器人的逆运动学解目前使用的PSO算法
  • ¥15 发那科机器人与设备通讯配置
  • ¥15 Linux环境下openssl报错
手机看
程序员都在用的中文IT技术交流社区

程序员都在用的中文IT技术交流社区

专业的中文 IT 技术社区,与千万技术人共成长

专业的中文 IT 技术社区,与千万技术人共成长

关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

关注【CSDN】视频号,行业资讯、技术分享精彩不断,直播好礼送不停!

客服 返回
顶部