ImageVerifierCode 换一换
格式:DOCX , 页数:11 ,大小:19.86KB ,
资源ID:28384882      下载积分:3 金币
快捷下载
登录下载
邮箱/手机:
温馨提示:
快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。 如填写123,账号就是123,密码也是123。
特别说明:
请自助下载,系统不会自动发送文件的哦; 如果您已付费,想二次下载,请登录后访问:我的下载记录
支付方式: 支付宝    微信支付   
验证码:   换一换

加入VIP,免费下载
 

温馨提示:由于个人手机设置不同,如果发现不能下载,请复制以下地址【https://www.bdocx.com/down/28384882.html】到电脑端继续下载(重复下载不扣费)。

已注册用户请登录:
账号:
密码:
验证码:   换一换
  忘记密码?
三方登录: 微信登录   QQ登录  

下载须知

1: 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。
2: 试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。
3: 文件的所有权益归上传用户所有。
4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
5. 本站仅提供交流平台,并不能对任何下载内容负责。
6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

版权提示 | 免责声明

本文(PHP函数库分类三十四.docx)为本站会员(b****5)主动上传,冰豆网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知冰豆网(发送邮件至service@bdocx.com或直接QQ联系客服),我们立即给予删除!

PHP函数库分类三十四.docx

1、PHP函数库分类三十四PHP函数库分类三十四10.PHP选项/信息函数列表6 phpcredits- Prints out the credits for PHPphpcredits(PHP 4, PHP 5)phpcreditsPrints out the credits for PHP说明boolphpcredits(int$flag= CREDITS_ALL )This function prints out the credits listing the PHP developers, modules, etc. It generates the appropriate HTML co

2、des to insert the information in a page.参数flagTo generate a custom credits page, you may want to use theflagparameter.Pre-definedphpcredits()flagsnamedescriptionCREDITS_ALLAll the credits, equivalent to using:CREDITS_DOCS+CREDITS_GENERAL+CREDITS_GROUP+CREDITS_MODULES+CREDITS_FULLPAGE. It generates a

3、 complete stand-alone HTML page with the appropriate tags.CREDITS_DOCSThe credits for the documentation teamCREDITS_FULLPAGEUsually used in combination with the other flags. Indicates that a complete stand-alone HTML page needs to be printed including the information indicated by the other flags.CRE

4、DITS_GENERALGeneral credits: Language design and concept, PHP authors and SAPI module.CREDITS_GROUPA list of the core developersCREDITS_MODULESA list of the extension modules for PHP, and their authorsCREDITS_SAPIA list of the server API modules for PHP, and their authors返回值成功时返回TRUE, 或者在失败时返回FALSE.

5、范例Example #1 Prints the general creditsExample #2 Prints the core developers and the documentation groupExample #3 Printing all the creditsMycreditspage phpversion- Gets the current PHP versionphpversion(PHP 4, PHP 5)phpversionGets the current PHP version说明stringphpversion(string$extension )Returns

6、a string containing the version of the currently running PHP parser or extension.参数extensionAn optional extension name.返回值If the optionalextensionparameter is specified,phpversion()returns the version of that extension, orFALSEif there is no version information associated or the extension isnt enabl

7、ed.范例Example #1phpversion()exampleExample #2PHP_VERSION_IDexample and usage?php/PHP_VERSION_IDisavailableasofPHP5.2.7,ifour/versionislowerthanthat,thenemulateitif(!defined(PHP_VERSION_ID)$version=explode(.,PHP_VERSION);define(PHP_VERSION_ID,($version0*10000+$version1*100+$version2);/PHP_VERSION_IDis

8、definedasanumber,wherethehigherthenumber/is,theneweraPHPversionisused.Itsdefinedasusedintheabove/expression:/$version_id=$major_version*10000+$minor_version*100+$release_version;/NowwithPHP_VERSION_IDwecancheckforfeaturesthisPHPversion/mayhave,thisdoesntrequiretouseversion_compare()everytime/youchec

9、kifthecurrentPHPversionmaynotsupportafeature./Forexample,wemayheredefinethePHP_VERSION_*constantsthats/notavailableinversionspriorto5.2.7if(PHP_VERSION_ID注释Note:This information is also available in the predefined constantPHP_VERSION. More versioning information is available using thePHP_VERSION_*co

10、nstants. php_ini_loaded_file- Retrieve a path to the loaded php.ini filephp_ini_loaded_file(PHP 5 = 5.2.4)php_ini_loaded_fileRetrieve a path to the loaded php.ini file说明stringphp_ini_loaded_file(void)Check if aphp.inifile is loaded, and retrieve its path.参数此函数没有参数。返回值The loadedphp.inipath, orFALSEif

11、 one is not loaded.范例Example #1php_ini_loaded_file()example以上例程的输出类似于:Loaded php.ini: /usr/local/php/php.ini php_ini_scanned_files- Return a list of .ini files parsed from the additional ini dirphp_ini_scanned_files(PHP 4 = 4.3.0, PHP 5)php_ini_scanned_filesReturn a list of .ini files parsed from th

12、e additional ini dir说明stringphp_ini_scanned_files(void)php_ini_scanned_files()returns a comma-separated list of configuration files parsed afterphp.ini. These files are found in a directory defined by the-with-config-file-scan-diroption which is set during compilation.The returned configuration file

13、s also include the path as declared in the-with-config-file-scan-diroption.返回值Returns a comma-separated string of .ini files on success. Each comma is followed by a newline. If the directive-with-config-file-scan-dirwasnt set,FALSEis returned. If it was set and the directory was empty, an empty stri

14、ng is returned. If a file is unrecognizable, the file will still make it into the returned string but a PHP error will also result. This PHP error will be seen both at compile time and while usingphp_ini_scanned_files().范例Example #1 A simple example to list the returned ini files0)$files=explode(,$f

15、ilelist);foreach($filesas$file)echo.trim($file). ;? php_logo_guid- Gets the logo guidphp_logo_guid(PHP 4, PHP 5)php_logo_guidGets the logo guid说明stringphp_logo_guid(void)This function returns the ID which can be used to display the PHP logo using the built-in image. Logo is displayed only if expose_

16、php is On.返回值ReturnsPHPE9568F34-D428-11d2-A769-00AA001ACF42.范例Example #1php_logo_guid()example?phpecho;? php_sapi_name- Returns the type of interface between web server and PHPphp_sapi_name(PHP 4 = 4.0.1, PHP 5)php_sapi_nameReturns the type of interface between web server and PHP说明stringphp_sapi_nam

17、e(void)Returns a lowercase string that describes the type of interface (the Server API, SAPI) that PHP is using. For example, in CLI PHP this string will be cli whereas with Apache it may have several different values depending on the exact SAPI used. Possible values are listed below.返回值Returns the

18、interface type, as a lowercase string.Although not exhaustive, the possible return values includeaolserver,apache,apache2filter,apache2handler,caudium,cgi(until PHP 5.3),cgi-fcgi,cli,continuity,embed,isapi,litespeed,milter,nsapi,phttpd,pi3web,roxen,thttpd,tux, andwebjames.范例Example #1php_sapi_name()

19、exampleThis example checks for the substringcgibecause it may also becgi-fcgi.注释Note:An alternative approachThe PHP constantPHP_SAPIhas the same value asphp_sapi_name().TipA potential gotchaThe definedSAPImay not be obvious, because for example instead ofapacheit may be defined asapache2handlerorapa

20、che2filter. php_uname- Returns information about the operating system PHP is running onphp_uname(PHP 4 = 4.0.2, PHP 5)php_unameReturns information about the operating system PHP is running on说明stringphp_uname(string$mode= a )php_uname()returns a description of the operating system PHP is running on.

21、 This is the same string you see at the very top of thephpinfo()output. For the name of just the operating system, consider using thePHP_OSconstant, but keep in mind this constant will contain the operating system PHP wasbuilton.On some older UNIX platforms, it may not be able to determine the curre

22、nt OS information in which case it will revert to displaying the OS PHP was built on. This will only happen if your uname() library call either doesnt exist or doesnt work.参数modemodeis a single character that defines what information is returned: a: This is the default. Contains all modes in the seq

23、uences n r v m. s: Operating system name. eg.FreeBSD. n: Host name. eg. r: Release name. eg.5.1.2-RELEASE. v: Version information. Varies a lot between operating systems. m: Machine type. eg.i386.返回值Returns the description, as a string.范例Example #1 Somephp_uname()examplesThere are also some relatedP

24、redefined PHP constantsthat may come in handy, for example:Example #2 A few OS related constant examples putenv- Sets the value of an environment variableputenv(PHP 4, PHP 5)putenvSets the value of an environment variable说明boolputenv(string$setting)Addssettingto the server environment. The environment variable will only exist for the duration of the current request. At the end of the request the environment is rest

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1