Home php教程 php手册 php函数积累总结

php函数积累总结

Jun 21, 2016 am 08:49 AM
convert html


Math函数:
10个较常用标红。
abs — 绝对值
acos — 反余弦
acosh — 反双曲余弦
asin — 反正弦
asinh — 反双曲正弦
atan2 — 两个参数的反正切
atan — 反正切
atanh — 反双曲正切
base_convert — 在任意进制之间转换数字
bindec — 二进制转换为十进制
ceil — 进一法取整
cos — 余弦
cosh — 双曲余弦
decbin — 十进制转换为二进制
dechex — 十进制转换为十六进制
decoct — 十进制转换为八进制
deg2rad — 将角度转换为弧度
exp — 计算 e 的指数
expm1 — 返回 exp(number) - 1,甚至当 number 的值接近零也能计算出准确结果
floor — 舍去法取整
fmod — 返回除法的浮点数余数
getrandmax — 显示随机数最大的可能值
hexdec — 十六进制转换为十进制
hypot — 计算一直角三角形的斜边长度
is_finite — 判断是否为有限值
is_infinite — 判断是否为无限值
is_nan — 判断是否为合法数值
lcg_value — 组合线性同余发生器
log10 — 以 10 为底的对数
log1p — 返回 log(1 + number),甚至当 number 的值接近零也能计算出准确结果
log — 自然对数
max — 找出最大值
min — 找出最小值
mt_getrandmax — 显示随机数的最大可能值
mt_rand — 生成更好的随机数
mt_srand — 播下一个更好的随机数发生器种子
octdec — 八进制转换为十进制
pi — 得到圆周率值
pow — 指数表达式
rad2deg — 将弧度数转换为相应的角度数
rand — 产生一个随机整数
round — 对浮点数进行四舍五入
sin — 正弦
sinh — 双曲正弦
sqrt — 平方根
srand — 播下随机数发生器种子
tan — 正切
tanh — 双曲正切
字符串函数:
多多益善,至少掌握20个吧。较常用标红。
addcslashes — 以 C 语言风格使用反斜线转义字符串中的字符
addslashes — 使用反斜线引用字符串
bin2hex — 将二进制数据转换成十六进制表示
chop — rtrim 的别名
chr — 返回指定的字符
chunk_split — 将字符串分割成小块
convert_cyr_string — 将字符由一种 Cyrillic 字符转换成另一种
convert_uudecode — 解码一个 uuencode 编码的字符串
convert_uuencode — 使用 uuencode 编码一个字符串
count_chars — 返回字符串所用字符的信息
crc32 — 计算一个字符串的 crc32 多项式
crypt — 单向字符串散列
echo — 输出一个或多个字符串
explode — 使用一个字符串分割另一个字符串
fprintf — 将格式化后的字符串写入到流
get_html_translation_table — 返回使用 htmlspecialchars 和 htmlentities 后的转换表
hebrev — 将逻辑顺序希伯来文(logical-Hebrew)转换为视觉顺序希伯来文(visual-Hebrew)
hebrevc — 将逻辑顺序希伯来文(logical-Hebrew)转换为视觉顺序希伯来文(visual-Hebrew),并且转换换行符
html_entity_decode — Convert all HTML entities to their applicable characters
htmlentities — Convert all applicable characters to HTML entities
htmlspecialchars_decode — Convert special HTML entities back to characters
htmlspecialchars — Convert special characters to HTML entities
implode — Join array elements with a string
join — 别名 implode 本文链接http://www.cxybl.com/html/wlbc/Php/20130729/39381.html



Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
1 months ago By 尊渡假赌尊渡假赌尊渡假赌
Two Point Museum: All Exhibits And Where To Find Them
1 months ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Table Border in HTML Table Border in HTML Sep 04, 2024 pm 04:49 PM

Guide to Table Border in HTML. Here we discuss multiple ways for defining table-border with examples of the Table Border in HTML.

Nested Table in HTML Nested Table in HTML Sep 04, 2024 pm 04:49 PM

This is a guide to Nested Table in HTML. Here we discuss how to create a table within the table along with the respective examples.

HTML margin-left HTML margin-left Sep 04, 2024 pm 04:48 PM

Guide to HTML margin-left. Here we discuss a brief overview on HTML margin-left and its Examples along with its Code Implementation.

HTML Table Layout HTML Table Layout Sep 04, 2024 pm 04:54 PM

Guide to HTML Table Layout. Here we discuss the Values of HTML Table Layout along with the examples and outputs n detail.

HTML Ordered List HTML Ordered List Sep 04, 2024 pm 04:43 PM

Guide to the HTML Ordered List. Here we also discuss introduction of HTML Ordered list and types along with their example respectively

How do you parse and process HTML/XML in PHP? How do you parse and process HTML/XML in PHP? Feb 07, 2025 am 11:57 AM

This tutorial demonstrates how to efficiently process XML documents using PHP. XML (eXtensible Markup Language) is a versatile text-based markup language designed for both human readability and machine parsing. It's commonly used for data storage an

Moving Text in HTML Moving Text in HTML Sep 04, 2024 pm 04:45 PM

Guide to Moving Text in HTML. Here we discuss an introduction, how marquee tag work with syntax and examples to implement.

HTML Input Placeholder HTML Input Placeholder Sep 04, 2024 pm 04:54 PM

Guide to HTML Input Placeholder. Here we discuss the Examples of HTML Input Placeholder along with the codes and outputs.

See all articles