PHP get_html_translation_table()函数用法讲解


Posted in PHP onFebruary 16, 2019

PHP get_html_translation_table() 函数

实例

输出 htmlspecialchars 函数使用的翻译表:

<?php 
print_r (get_html_translation_table()); // HTML_SPECIALCHARS is default. 
?>

定义和用法

get_html_translation_table()函数返回htmlentities()htmlspecialchars()函数使用的翻译表。

提示:一些字符可以按照若干种方式进行编码。get_html_translation_table() 函数返回最普通的编码。

语法

get_html_translation_table( _function,flags,character-set_ )

PHP get_html_translation_table()函数用法讲解

PHP get_html_translation_table()函数用法讲解

实例

HTML_SPECIALCHARS 的翻译表:

<?php 
print_r (get_html_translation_table(HTML_SPECIALCHARS)); 
?>
Displaying character and entity name:
Array 
( 
["] => " 
[&] => & 
[<] => < 
[>] => > 
)

实例 2

HTML_ENTITIES 的翻译表:

<?php 
print_r (get_html_translation_table(HTML_ENTITIES)); 
?>

显示字符及其对应的实体名称:

Array 

["] => " 
[&] => & 
[<] => < 
[>] => > 
[ ] =>   
[¡] => ¡ 
[¢] => ¢ 
[£] => £ 
[¤] => ¤ 
[¥] => ¥ 
[¦] => ¦ 
[§] => § 
[¨] => ¨ 
[©] => © 
[ª] => ª 
[«] => « 
[¬] => ¬ 
[­] => ­ 
[®] => ® 
[¯] => ¯ 
[°] => ° 
[±] => ± 
[²] => ² 
[³] => ³ 
[´] => ´ 
[µ] => µ 
[¶] => ¶ 
[·] => · 
[¸] => ¸ 
[¹] => ¹ 
[º] => º 
[»] => » 
[¼] => ¼ 
[½] => ½ 
[¾] => ¾ 
[¿] => ¿ 
[À] => À 
[Á] => Á 
[Â] =>  
[Ã] => à
[Ä] => Ä 
[Å] => Å 
[Æ] => Æ 
[Ç] => Ç 
[È] => È 
[É] => É 
[Ê] => Ê 
[Ë] => Ë 
[Ì] => Ì 
[Í] => Í 
[Î] => Π
[Ï] => Ï 
[Ð] => Р
[Ñ] => Ñ 
[Ò] => Ò 
[Ó] => Ó 
[Ô] => Ô 
[Õ] => Õ 
[Ö] => Ö 
[×] => × 
[Ø] => Ø 
[Ù] => Ù 
[Ú] => Ú 
[Û] => Û 
[Ü] => Ü 
[Ý] => Ý 
[Þ] => Þ 
[ß] => ß 
[à] => à 
[á] => á 
[â] => â 
[ã] => ã 
[ä] => ä 
[å] => å 
[æ] => æ 
[ç] => ç 
[è] => è 
[é] => é 
[ê] => ê 
[ë] => ë 
[ì] => ì 
[í] => í 
[î] => î 
[ï] => ï 
[ð] => ð 
[ñ] => ñ 
[ò] => ò 
[ó] => ó 
[ô] => ô 
[õ] => õ 
[ö] => ö 
[÷] => ÷ 
[ø] => ø 
[ù] => ù 
[ú] => ú 
[û] => û 
[ü] => ü 
[ý] => ý 
[þ] => þ 
[ÿ] => ÿ 
[Œ] => Œ 
[œ] => œ 
[Š] => Š 
[š] => š 
[Ÿ] => Ÿ 
[ƒ] => ƒ 
[ˆ] => ˆ 
[˜] => ˜ 
[Α] => Α 
[Β] => Β 
[Γ] => Γ 
[Δ] => Δ 
[Ε] => Ε 
[Ζ] => Ζ 
[Η] => Η 
[Θ] => Θ 
[Ι] => Ι 
[Κ] => Κ 
[Λ] => Λ 
[Μ] => Μ 
[Ν] => Ν 
[Ξ] => Ξ 
[Ο] => Ο 
[Π] => Π 
[Ρ] => Ρ 
[Σ] => Σ 
[Τ] => Τ 
[Υ] => Υ 
[Φ] => Φ 
[Χ] => Χ 
[Ψ] => Ψ 
[Ω] => Ω 
[α] => α 
[β] => β 
[γ] => γ 
[δ] => δ 
[ε] => ε 
[ζ] => ζ 
[η] => η 
[θ] => θ 
[ι] => ι 
[κ] => κ 
[λ] => λ 
[μ] => μ 
[ν] => ν 
[ξ] => ξ 
[ο] => ο 
[π] => π 
[ρ] => ρ 
[ς] => ς 
[σ] => σ 
[τ] => τ 
[υ] => υ 
[φ] => φ 
[χ] => χ 
[ψ] => ψ 
[ω] => ω 
[ϑ] => ϑ 
[ϒ] => ϒ 
[ϖ] => ϖ 
[ ] =>   
[ ] =>   
[ ] =>   
[‌] => ‌ 
[‍] => ‍ 
[‎] => ‎ 
[‏] => ‏ 
[?] => – 
[—] => — 
['] => ‘ 
['] => ’ 
[‚] => ‚ 
["] => “ 
["] => ” 
[„] => „ 
[†] => † 
[‡] => ‡ 
[•] => • 
[…] => … 
[‰] => ‰ 
[′] => ′ 
[″] => ″ 
[‹] => ‹ 
[›] => › 
[‾] => ‾ 
[⁄] => ⁄ 
[?] => € 
[ℑ] => ℑ 
[℘] => ℘ 
[ℜ] => ℜ 
[™] => ™ 
[ℵ] => ℵ 
[←] => ← 
[↑] => ↑ 
[→] => → 
[↓] => ↓ 
[↔] => ↔ 
[↵] => ↵ 
[⇐] => ⇐ 
[⇑] => ⇑ 
[⇒] => ⇒ 
[⇓] => ⇓ 
[⇔] => ⇔ 
[∀] => ∀ 
[∂] => ∂ 
[∃] => ∃ 
[∅] => ∅ 
[∇] => ∇ 
[∈] => ∈ 
[∉] => ∉ 
[∋] => ∋ 
[∏] => ∏ 
[∑] => ∑ 
[−] => − 
[∗] => ∗ 
[√] => √ 
[∝] => ∝ 
[∞] => ∞ 
[∠] => ∠ 
[∧] => ∧ 
[∨] => ∨ 
[∩] => ∩ 
[∪] => ∪ 
[∫] => ∫ 
[∴] => ∴ 
[∼] => ∼ 
[≅] => ≅ 
[≈] => ≈ 
[≠] => ≠ 
[≡] => ≡ 
[≤] => ≤ 
[≥] => ≥ 
[⊂] => ⊂ 
[⊃] => ⊃ 
[⊄] => ⊄ 
[⊆] => ⊆ 
[⊇] => ⊇ 
[?] => ⊕ 
[⊗] => ⊗ 
[⊥] => ⊥ 
[⋅] => ⋅ 
[⌈] => ⌈ 
[⌉] => ⌉ 
[⌊] => ⌊ 
[⌋] => ⌋ 
[〈] => ⟨ 
[〉] => ⟩ 
[◊] => ◊ 
[♠] => ♠ 
[♣] => ♣ 
[♥] => ♥ 
[♦] => ♦ 
)

总结

以上就是这篇文章的全部内容了,希望本文的内容对大家的学习或者工作具有一定的参考学习价值,谢谢大家对三水点靠木的支持。如果你想了解更多相关内容请查看下面相关链接

PHP 相关文章推荐
PHP3 safe_mode 失效漏洞
Oct 09 PHP
[原创]PHP中通过ADODB库实现调用Access数据库之修正版本
Dec 31 PHP
PHP的autoload机制的实现解析
Sep 15 PHP
php中url函数介绍及使用示例
Feb 13 PHP
PHP中is_file不能替代file_exists的理由
Mar 04 PHP
php断点续传之如何分割合并文件
Mar 22 PHP
ThinkPHP路由详解
Jul 27 PHP
php微信公众平台配置接口开发程序
Sep 22 PHP
PHP中empty,isset,is_null用法和区别
Feb 19 PHP
PHP定义字符串的四种方式详解
Feb 06 PHP
使用laravel和ECharts实现折线图效果的例子
Oct 09 PHP
使用PHP+Redis实现延迟任务,实现自动取消订单功能
Nov 21 PHP
PHP5.5基于mysqli连接MySQL数据库和读取数据操作实例详解
Feb 16 #PHP
PHP封装的mysqli数据库操作类示例
Feb 16 #PHP
PHP fprintf()函数用法讲解
Feb 16 #PHP
PHP explode()函数用法讲解
Feb 15 #PHP
php二维数组按某个键值排序的实例讲解
Feb 15 #PHP
php curl简单采集图片生成base64编码(并附curl函数参数说明)
Feb 15 #PHP
实例讲解PHP表单验证功能
Feb 15 #PHP
You might like
无数据库的详细域名查询程序PHP版(2)
2006/10/09 PHP
PHP 网页过期时间的控制代码
2009/06/29 PHP
PHP通过header实现文本文件下载的代码
2010/08/08 PHP
PHP上传文件时文件过大$_FILES为空的解决方法
2013/11/26 PHP
php获取文件大小的方法
2014/02/26 PHP
php获得网站访问统计信息类Compete API用法实例
2015/04/02 PHP
Jquery插件 easyUI属性汇总
2011/01/19 Javascript
javascript中String对象的slice()方法分析
2014/12/20 Javascript
jquery事件的ready()方法使用详解
2015/11/11 Javascript
原生JavaScript实现滚动条效果
2020/03/24 Javascript
jQuery插件支持同一页面被多次调用
2016/02/14 Javascript
JS实现支持Ajax验证的表单插件
2016/03/24 Javascript
jQuery Easyui datagrid/treegrid 清空数据
2016/07/09 Javascript
详解datagrid使用方法(重要)
2020/11/06 Javascript
[00:35]TI7不朽珍藏III——寒冰飞龙不朽展示
2017/07/15 DOTA
Python中断言Assertion的一些改进方案
2016/10/27 Python
Python入门_浅谈逻辑判断与运算符
2017/05/16 Python
Python中扩展包的安装方法详解
2017/06/14 Python
PyCharm 配置远程python解释器和在本地修改服务器代码
2019/07/23 Python
Python importlib模块重载使用方法详解
2020/10/13 Python
基于Python爬取京东双十一商品价格曲线
2020/10/23 Python
泰坦健身器材:Titan Fitness
2018/02/13 全球购物
说一下mysql, oracle等常见数据库的分页实现方案
2012/09/29 面试题
测绘工程本科生求职信
2013/10/10 职场文书
医药专业推荐信
2013/11/15 职场文书
会计电算化专业自荐信
2014/03/15 职场文书
节能减排倡议书
2014/04/15 职场文书
法制宣传口号
2014/06/16 职场文书
乡镇群众路线专项整治方案
2014/11/03 职场文书
2014年初中班主任工作总结
2014/11/08 职场文书
2015年转正工作总结范文
2015/04/02 职场文书
导游词之长城八达岭
2019/09/24 职场文书
Python 数据科学 Matplotlib图库详解
2021/07/07 Python
java泛型通配符详解
2021/07/25 Java/Android
vue3引入highlight.js进行代码高亮的方法实例
2022/04/08 Vue.js
MySQL去除密码登录告警的方法
2022/04/20 MySQL