PHP函数摘编文档格式.docx
- 文档编号:22133241
- 上传时间:2023-02-02
- 格式:DOCX
- 页数:36
- 大小:22.66KB
PHP函数摘编文档格式.docx
《PHP函数摘编文档格式.docx》由会员分享,可在线阅读,更多相关《PHP函数摘编文档格式.docx(36页珍藏版)》请在冰豆网上搜索。
intada_rollback(intconnection_id);
2.Apache服务器专用函数
apache_lookup_uri
取得所有URI相关信息
classapache_lookup_uri(stringfilename);
apache_note
取得及设定Apache服务器的请求记录
stringapache_note(stringnote_name,string[note_value]);
3.数组处理函数
array
建立一个新的数组
arrayarray(...);
array_walk
让使用者自定函数,能处理数组中的每个元素
intarray_walk(arrayarr,stringfunc);
arsort
将数组的值由大到小排序
voidarsort(arrayarray);
asort
将数组的值由小到大排序
voidasort(arrayarray);
count
计算变量或数组中的元素个数
intcount(mixedvar);
current
返回数组中目前的元素
mixedcurrent(arrayarray);
each
返回数组中下一个元素的索引及值
arrayeach(arrayarray);
end
将数组的内部指针指向最后一个元素
end(arrayarray);
key
取得数组中的索引数据
mixedkey(arrayarray);
ksort
将数组的元素以索引排序
voidksort(arrayarray);
list
列出数组中元素的值
voidlist(...);
next
将数组的内部指针指向下一个元素
mixednext(arrayarray);
pos
返回数组目前的元素
mixedpos(arrayarray);
prev
将数组的内部指针指向前一个元素
mixedprev(arrayarray);
range
建立一个整数范围的数组
arrayrange(intlow,inthigh);
reset
将数组的内部指针指向第一个元素
mixedreset(arrayarray);
rsort
voidrsort(arrayarray);
shuffle
将数组的顺序打乱
voidshuffle(arrayarray);
sizeof
取得数组的大小
intsizeof(arrayarray);
sort
将数组排序
voidsort(arrayarray);
uasort
将数组依使用者自定的函数排序
voiduasort(arrayarray,functioncmp_function);
uksort
将数组的索引依使用者自定的函数排序
voiduksort(arrayarray,functioncmp_function);
usort
将数组的值依使用者自定的函数排序
voidusort(arrayarray,functioncmp_function);
4.拼写检查函数
aspell_new
加载一个新的字典
intaspell_new(stringmaster,stringpersonal);
aspell_check
检查一个单字
booleanaspell_check(intdictionary_link,stringword);
aspell_check-raw
检查一个单字,但不改正
booleanaspell_check_raw(intdictionary_link,stringword);
aspell_suggest
检查一个单字并提供拼写建议
arrayaspell_suggest(intdictionary_link,stringword);
5.日期、时间函数
checkdate
检查日期的正确性
intcheckdate(intmonth,intday,intyear);
date
格式化服务器的时间
stringdate(stringformat,int[timestamp]);
easter_date
计算复活节日期
inteaster_date(int[year]);
easter_days
计算到复活节的时间
inteaster_days(int[year]);
getdate
取得时间及日期
arraygetdate(inttimestamp);
gettimeofday
取得目前时间
arraygettimeofday(void);
gmdate
取得目前与GMT差后的时间
stringgmdate(stringformat,inttimestamp);
gmmktime
取得UNIX时间戳记的格林威治时间
intgmmktime(inthour,intminute,intsecond,intmonth,intday,intyear);
time
取得目前时间的UNIX时间戳记
inttime(void);
microtime
取得目前时间的UNIX时间戳记的百万分之一秒值
stringmicrotime(void);
strftime
将服务器的时间本地格式化
stringstrftime(stringformat,int[timestamp]);
6.DBA函数
dba_close
关闭数据库
voiddba_close(inthandle);
dba_delete
删除指定数据
intdba_delete(stringkey,inthandle);
dba_exists
检查键是否存在
booleandba_exists(stringkey,inthandle);
dba_fetch
取得指定数据
stringdba_fetch(stringkey,inthandle);
dba_firstkey
取得首键值
stringdba_firstkey(inthandle);
dba_insert
插入数据
booleandba_insert(stringkey,stringvalue,inthandle);
dba_nextkey
取得下一键值
stringdba_nextkey(inthandle);
dba_open
开启数据库连接
intdba_open(stringpath,stringmode,stringhandler);
dba_optimize
最佳化数据库
booleandba_optimize(inthandle);
dba_popen
开启并保持数据库连接
intdba_popen(stringpath,stringmode,stringhandler);
dba_replace
更换或加入数据
booleandba_replace(stringkey,stringvalue,inthandle);
dba_sync
数据库同步化
booleandba_sync(inthandle);
7.DBase格式数据函数
dbase_add_record
加入数据到dBase数据表
booleandbase_add_record(intdbase_identifier,arrayrecord);
dbase_close
关闭dBase数据表
booleandbase_close(intdbase_identifier);
dbase_create
建立dBase数据表
intdbase_create(stringfilename,arrayfields);
dbase_delete_record
删除dBase数据表中的数据
booleandbase_delete_record(intdbase_identifier,intrecord);
dbase_get_record
取得dBase数据表中的数据
arraydbase_get_record(intdbase_identifier,intrecord);
dbase_numfields
取得dBase数据表中的字段数目
intdbase_numfields(intdbase_identifier);
dbase_numrecords
取得dBase数据表中的列数目
intdbase_numrecords(intdbase_identifier);
dbase_open
开启dBase数据表
intdbase_open(stringfilename,intflags);
dbase_pack
清理dBase数据表
booleandbase_pack(intdbase_identifier);
8.目录管理函数
chdir
改变目录
intchdir(stringdirectory);
closedir
关闭目录handle
voidclosedir(intdir_handle);
dir
目录类型对象
newdir(stringdirectory);
opendir
开启目录handle
intopendir(stringpath);
readdir
读取目录handle
stringreaddir(intdir_handle);
rewinddir
重设目录handle
voidrewinddir(intdir_handle);
9.动态连接库函数
dl
加载PHP扩充模块
intdl(stringlibrary);
10.程序执行功能函数
escapeshellcmd
删除字符串中的特殊字符
stringescapeshellcmd(stringcommand);
exec
执行外部程序
stringexec(stringcommand,string[array],int[return_var]);
passthru
执行外部程序并不加处理输出数据
stringpassthru(stringcommand,int[return_var]);
system
执行外部程序并显示输出数据
stringsystem(stringcommand,int[return_var]);
11.PHP选项及相关信息函数
error_log
送出一个错误信息
interror_log(stringmessage,intmessage_type,string[destination],string[extra_headers]);
error_reporting
设定错误信息回报的等级
interror_reporting(int[level]);
getenv
取得系统的环境变量
stringgetenv(stringvarname);
getlastmod
返回该网页的最后修改时间
intgetlastmod(void);
getmyinode
返回该网页的inode值
intgetmyinode(void);
getmypid
返回PHP标识
intgetmypid(void);
getmyuid
返回PHP的使用者标识
intgetmyuid(void);
getrusage
返回系统资源使用率
arraygetrusage(int[who]);
get_cfg_var
取得PHP的设定选项值
stringget_cfg_var(stringvarname);
get_current_user
取得PHP程序的所有者名称
stringget_current_user(void);
get_magic_quotes_gpc
取得PHP环境变量magic_quotes_gpc的值
longget_magic_quotes_gpc(void);
get_magic_quotes_runtime
取得PHP环境变量magic_quotes_runtime的值
longget_magic_quotes_runtime(void);
phpinfo
返回PHP所有相关信息
intphpinfo(void);
phpversion
返回PHP版本信息
stringphpversion(void);
putenv
设定系统环境变量
voidputenv(stringsetting);
set_magic_quotes_runtime
设定magic_quotes_runtime的值
longset_magic_quotes_runtime(intnew_setting);
set_time_limit
设定该页最长执行时间
voidset_time_limit(intseconds);
12.Informix数据库函数
ifxus_close_slob
删除slob对象
booleanifxus_close_slob(intbid);
ifxus_create_slob
建立slob对象
intifxus_create_slob(intmode);
ifxus_open_slob
开启slob对象
intifxus_open_slob(longbid,intmode);
ifxus_read_slob
读取指定数目的slob对象
stringifxus_read_slob(longbid,longnbytes);
ifxus_seek_slob
设定目前文件或寻找位置
intifxus_seek_blob(longbid,intmode,longoffset);
ifxus_tell_slob
返回目前文件或寻找位置
intifxus_tell_slob(longbid);
ifxus_write_slob
将字符串写入slob对象
intifxus_write_slob(longbid,stringcontent);
ifx_affected_rows
取得Informix最后操作影响的行数目
intifx_affected_rows(intresult_id);
ifx_blobinfile_mode
设定长位对象模式
booleanifx_blobinfile_mode(intmode);
ifx_byteasvarchar
设定字节模式内存值
booleanifx_byteasvarchar(intmode);
ifx_close
关闭Informix服务器连接
booleanifx_close(int[link_identifier]);
ifx_connect
开启Informix服务器连接
intifx_connect(string[database],string[userid],string[password]);
ifx_copy_blob
复制长位对象
intifx_copy_blob(intbid);
ifx_create_blob
建立长位对象
intifx_create_blob(inttype,intmode,stringparam);
ifx_create_char
建立字符对象
intifx_create_char(stringparam);
ifx_do
执行已准备的query字符串
booleanifx_do(intresult_id);
ifx_error
取得Informix最后的错误
stringifx_error(void);
ifx_errormsg
取得Informix最后错误信息
stringifx_errormsg(int[errorcode]);
ifx_fetch_row
返回一行的各字段
arrayifx_fetch_row(intresult_id,mixed[position]);
ifx_fieldproperties
列出Informix的SQL字段属性
arrayifx_fieldproperties(intresult_id);
ifx_fieldtypes
列出Informix的SQL字段
arrayifx_fieldtypes(intresult_id);
ifx_free_blob
删除长位对象
booleanifx_free_blob(intbid);
ifx_free_char
删除字符对象
booleanifx_free_char(intbid);
ifx_free_result
释放返回占有的内存
booleanifx_free_result(intresult_id);
ifx_free_slob
删除slob对象
booleanifxus_free_slob(intbid);
ifx_getsqlca
取得query后的sqlca信息
arrayifx_getsqlca(intresult_id);
ifx_get_blob
取得长位对象
stringifx_get_blob(intbid);
ifx_get_char
取得字符对象
stringifx_get_char(intbid);
ifx_htmltbl_result
将query返回数据转换成HTML表格
intifx_htmltbl_result(intresult_id,string[html_table_options]);
ifx_nullformat
设定空字符模式内存值
booleanifx_nullformat(intmode);
ifx_num_fields
取得返回的字段数目
intifx_num_fields(intresult_id);
ifx_num_rows
取得返回的行数目
intifx_num_rows(intresult_id);
ifx_pconnect
开启Informix服务器永久连接
intifx_pconnect(string[database],string[userid],string[password]);
ifx_prepare
准备query字符串
intifx_prepare(stringquery,intlink_identifier,int[cursor_type],mixedblobidarray);
ifx_query
送出一个query字符串
intifx_query(stringquery,int[link_identifier],int[cursor_type],mixed[blobidarray]);
ifx_textasvarchar
设定文字模式内存值
booleanifx_textasvarchar(intmode);
ifx_update_blob
更改长位对象
booleanifx_update_blob(intbid,stringcontent);
ifx_update_char
更改字符对象
booleanifx_update_char(intbid,stringcontent);
13.数学运算函数
Abs
取得绝对值
mixedabs(mixednumber);
Acos
取得反余弦值
floatacos(floatarg);
Asin
取得反正弦值
floatasin(floatarg);
Atan
取得反正切值
floatatan(floatarg);
Atan2
计算两数的反正切值
floatatan2(floaty,floatx);
base_convert
转换数字的进位方式
stringbase_convert(stringnumber,intfrombase,inttobase);
BinDec
二进制转换成十进制
intbindec(stringbinary_string);
Ceil
计算大于指定数的最小整数
intceil(floatnumber);
C
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- PHP 函数 摘编