Z-Blog Wiki Z-Blog Wiki

Z-Blog官方文库

用户工具

站点工具


zblogphp:development:functions:common

差别

这里会显示出您选择的修订版和当前版本之间的差别。

到此差别页面的链接

两侧同时换到之前的修订记录 前一修订版
zblogphp:development:functions:common [2020/05/18 22:55]
zx.asd
zblogphp:development:functions:common [2020/05/18 23:10] (当前版本)
zx.asd
行 25: 行 25:
 function GetScheme($array) function GetScheme($array)
 </​code>​ </​code>​
 + 
 + 
 ==== GetWebServer() ==== ==== GetWebServer() ====
  
行 43: 行 45:
 function GetWebServer() function GetWebServer()
 </​code>​ </​code>​
 + 
 + 
 ==== GetSystem() ==== ==== GetSystem() ====
  
行 61: 行 65:
 function GetSystem() function GetSystem()
 </​code>​ </​code>​
 + 
 + 
 ==== GetPHPEngine() ==== ==== GetPHPEngine() ====
  
行 79: 行 85:
 function GetPHPEngine() function GetPHPEngine()
 </​code>​ </​code>​
 + 
 + 
 ==== GetPHPVersion() ==== ==== GetPHPVersion() ====
  
行 97: 行 105:
 function GetPHPVersion() function GetPHPVersion()
 </​code>​ </​code>​
 + 
 + 
 ==== AutoloadClass() ==== ==== AutoloadClass() ====
  
行 118: 行 128:
 function AutoloadClass($className) function AutoloadClass($className)
 </​code>​ </​code>​
 + 
 + 
 ==== Logs() ==== ==== Logs() ====
  
行 142: 行 154:
 function Logs($logString,​$isError) function Logs($logString,​$isError)
 </​code>​ </​code>​
 + 
 + 
 ==== RunTime() ==== ==== RunTime() ====
  
行 163: 行 177:
 function RunTime($isOutput) function RunTime($isOutput)
 </​code>​ </​code>​
 + 
 + 
 ==== GetEnvironment() ==== ==== GetEnvironment() ====
  
行 181: 行 197:
 function GetEnvironment() function GetEnvironment()
 </​code>​ </​code>​
 + 
 + 
 ==== plugin_dir_url() ==== ==== plugin_dir_url() ====
  
行 202: 行 220:
 function plugin_dir_url($file) function plugin_dir_url($file)
 </​code>​ </​code>​
 + 
 + 
 ==== plugin_dir_path() ==== ==== plugin_dir_path() ====
  
行 223: 行 243:
 function plugin_dir_path($file) function plugin_dir_path($file)
 </​code>​ </​code>​
 + 
 + 
 ==== GetValueInArray() ==== ==== GetValueInArray() ====
  
行 247: 行 269:
 function GetValueInArray($array,​$name) function GetValueInArray($array,​$name)
 </​code>​ </​code>​
 + 
 + 
 ==== GetValueInArrayByCurrent() ==== ==== GetValueInArrayByCurrent() ====
  
行 271: 行 295:
 function GetValueInArrayByCurrent($array,​$name) function GetValueInArrayByCurrent($array,​$name)
 </​code>​ </​code>​
 + 
 + 
 ==== SplitAndGet() ==== ==== SplitAndGet() ====
  
行 298: 行 324:
 function SplitAndGet($string,​$delimiter,​$n) function SplitAndGet($string,​$delimiter,​$n)
 </​code>​ </​code>​
 + 
 + 
 ==== RemoveMoreSpaces() ==== ==== RemoveMoreSpaces() ====
  
行 319: 行 347:
 function RemoveMoreSpaces($s) function RemoveMoreSpaces($s)
 </​code>​ </​code>​
 + 
 + 
 ==== GetGuid() ==== ==== GetGuid() ====
  
行 337: 行 367:
 function GetGuid() function GetGuid()
 </​code>​ </​code>​
 + 
 + 
 ==== GetVars() ==== ==== GetVars() ====
  
行 361: 行 393:
 function GetVars($name,​$type) function GetVars($name,​$type)
 </​code>​ </​code>​
 + 
 + 
 ==== GetVarsByDefault() ==== ==== GetVarsByDefault() ====
  
行 388: 行 422:
 function GetVarsByDefault($name,​$type,​$default) function GetVarsByDefault($name,​$type,​$default)
 </​code>​ </​code>​
 + 
 + 
 ==== GetDbName() ==== ==== GetDbName() ====
  
行 406: 行 442:
 function GetDbName() function GetDbName()
 </​code>​ </​code>​
 + 
 + 
 ==== GetCurrentHost() ==== ==== GetCurrentHost() ====
  
行 430: 行 468:
 function GetCurrentHost($blogpath,​$cookiesPath) function GetCurrentHost($blogpath,​$cookiesPath)
 </​code>​ </​code>​
 + 
 + 
 ==== GetHttpContent() ==== ==== GetHttpContent() ====
  
行 451: 行 491:
 function GetHttpContent($url) function GetHttpContent($url)
 </​code>​ </​code>​
 + 
 + 
 ==== GetDirsInDir() ==== ==== GetDirsInDir() ====
  
行 472: 行 514:
 function GetDirsInDir($dir) function GetDirsInDir($dir)
 </​code>​ </​code>​
 + 
 + 
 ==== GetFilesInDir() ==== ==== GetFilesInDir() ====
  
行 496: 行 540:
 function GetFilesInDir($dir,​$type) function GetFilesInDir($dir,​$type)
 </​code>​ </​code>​
 + 
 + 
 ==== RedirectByScript() ==== ==== RedirectByScript() ====
  
行 515: 行 561:
 function RedirectByScript($url) function RedirectByScript($url)
 </​code>​ </​code>​
 + 
 + 
 ==== Redirect() ==== ==== Redirect() ====
  
行 534: 行 582:
 function Redirect($url) function Redirect($url)
 </​code>​ </​code>​
 + 
 + 
 ==== Redirect301() ==== ==== Redirect301() ====
  
行 553: 行 603:
 function Redirect301($url) function Redirect301($url)
 </​code>​ </​code>​
 + 
 + 
 ==== Http404() ==== ==== Http404() ====
  
行 569: 行 621:
 function Http404() function Http404()
 </​code>​ </​code>​
 + 
 + 
 ==== Http500() ==== ==== Http500() ====
  
行 585: 行 639:
 function Http500() function Http500()
 </​code>​ </​code>​
 + 
 + 
 ==== Http503() ==== ==== Http503() ====
  
行 601: 行 657:
 function Http503() function Http503()
 </​code>​ </​code>​
 + 
 + 
 ==== Http304() ==== ==== Http304() ====
  
行 623: 行 681:
 function Http304($filename,​$time) function Http304($filename,​$time)
 </​code>​ </​code>​
 + 
 + 
 ==== GetGuestIP() ==== ==== GetGuestIP() ====
  
行 641: 行 701:
 function GetGuestIP() function GetGuestIP()
 </​code>​ </​code>​
 + 
 + 
 ==== GetGuestAgent() ==== ==== GetGuestAgent() ====
  
行 659: 行 721:
 function GetGuestAgent() function GetGuestAgent()
 </​code>​ </​code>​
 + 
 + 
 ==== GetRequestUri() ==== ==== GetRequestUri() ====
  
行 677: 行 741:
 function GetRequestUri() function GetRequestUri()
 </​code>​ </​code>​
 + 
 + 
 ==== GetFileExt() ==== ==== GetFileExt() ====
  
行 698: 行 764:
 function GetFileExt($f) function GetFileExt($f)
 </​code>​ </​code>​
 + 
 + 
 ==== GetFilePermsOct() ==== ==== GetFilePermsOct() ====
  
行 719: 行 787:
 function GetFilePermsOct($f) function GetFilePermsOct($f)
 </​code>​ </​code>​
 + 
 + 
 ==== GetFilePerms() ==== ==== GetFilePerms() ====
  
行 740: 行 810:
 function GetFilePerms($f) function GetFilePerms($f)
 </​code>​ </​code>​
 + 
 + 
 ==== AddNameInString() ==== ==== AddNameInString() ====
  
行 764: 行 836:
 function AddNameInString($s,​$name) function AddNameInString($s,​$name)
 </​code>​ </​code>​
 + 
 + 
 ==== DelNameInString() ==== ==== DelNameInString() ====
  
行 788: 行 862:
 function DelNameInString($s,​$name) function DelNameInString($s,​$name)
 </​code>​ </​code>​
 + 
 + 
 ==== HasNameInString() ==== ==== HasNameInString() ====
  
行 812: 行 888:
 function HasNameInString($s,​$name) function HasNameInString($s,​$name)
 </​code>​ </​code>​
 + 
 + 
 ==== JsonError4ShowErrorHook() ==== ==== JsonError4ShowErrorHook() ====
  
行 840: 行 918:
 function JsonError4ShowErrorHook($errorCode,​$errorString,​$file,​$line) function JsonError4ShowErrorHook($errorCode,​$errorString,​$file,​$line)
 </​code>​ </​code>​
 + 
 + 
 ==== JsonError() ==== ==== JsonError() ====
  
行 865: 行 945:
 function JsonError($errorCode,​$errorString,​$data) function JsonError($errorCode,​$errorString,​$data)
 </​code>​ </​code>​
 + 
 + 
 ==== JsonReturn() ==== ==== JsonReturn() ====
  
行 884: 行 966:
 function JsonReturn($data) function JsonReturn($data)
 </​code>​ </​code>​
 + 
 + 
 ==== RespondError() ==== ==== RespondError() ====
  
行 914: 行 998:
 function RespondError($errorCode,​$errorString,​$file,​$line) function RespondError($errorCode,​$errorString,​$file,​$line)
 </​code>​ </​code>​
 + 
 + 
 ==== ScriptError() ==== ==== ScriptError() ====
  
行 944: 行 1030:
 function ScriptError($errorCode,​$errorText,​$file,​$line) function ScriptError($errorCode,​$errorText,​$file,​$line)
 </​code>​ </​code>​
 + 
 + 
 ==== CheckRegExp() ==== ==== CheckRegExp() ====
  
行 968: 行 1056:
 function CheckRegExp($source,​$para) function CheckRegExp($source,​$para)
 </​code>​ </​code>​
 + 
 + 
 ==== FormatString() ==== ==== FormatString() ====
  
行 992: 行 1082:
 function FormatString($source,​$para) function FormatString($source,​$para)
 </​code>​ </​code>​
 + 
 + 
 ==== TransferHTML() ==== ==== TransferHTML() ====
  
行 1014: 行 1106:
 function TransferHTML($source,​$param) function TransferHTML($source,​$param)
 </​code>​ </​code>​
 + 
 + 
 ==== CloseTags() ==== ==== CloseTags() ====
  
行 1035: 行 1129:
 function CloseTags($html) function CloseTags($html)
 </​code>​ </​code>​
 + 
 + 
 ==== SubStrUTF8_Start() ==== ==== SubStrUTF8_Start() ====
  
行 1059: 行 1155:
 function SubStrUTF8_Start($sourcestr,​$start) function SubStrUTF8_Start($sourcestr,​$start)
 </​code>​ </​code>​
 + 
 + 
 ==== SubStrUTF8() ==== ==== SubStrUTF8() ====
  
行 1083: 行 1181:
 function SubStrUTF8($sourcestr,​$cutlength) function SubStrUTF8($sourcestr,​$cutlength)
 </​code>​ </​code>​
 + 
 + 
 ==== Zbp_SubStr() ==== ==== Zbp_SubStr() ====
  
行 1107: 行 1207:
 function Zbp_SubStr($sourcestr,​$start) function Zbp_SubStr($sourcestr,​$start)
 </​code>​ </​code>​
 + 
 + 
 ==== Zbp_StrLen() ==== ==== Zbp_StrLen() ====
  
行 1128: 行 1230:
 function Zbp_StrLen($string) function Zbp_StrLen($string)
 </​code>​ </​code>​
 + 
 + 
 ==== Zbp_Strpos() ==== ==== Zbp_Strpos() ====
  
行 1155: 行 1259:
 function Zbp_Strpos($haystack,​$needle,​$offset) function Zbp_Strpos($haystack,​$needle,​$offset)
 </​code>​ </​code>​
 + 
 + 
 ==== Zbp_Stripos() ==== ==== Zbp_Stripos() ====
  
行 1182: 行 1288:
 function Zbp_Stripos($haystack,​$needle,​$offset) function Zbp_Stripos($haystack,​$needle,​$offset)
 </​code>​ </​code>​
 + 
 + 
 ==== SubStrUTF8_Html() ==== ==== SubStrUTF8_Html() ====
  
行 1206: 行 1314:
 function SubStrUTF8_Html($source,​$length) function SubStrUTF8_Html($source,​$length)
 </​code>​ </​code>​
 + 
 + 
 ==== RemoveBOM() ==== ==== RemoveBOM() ====
  
行 1227: 行 1337:
 function RemoveBOM($s) function RemoveBOM($s)
 </​code>​ </​code>​
 + 
 + 
 ==== GetTimeZoneByGMT() ==== ==== GetTimeZoneByGMT() ====
  
行 1248: 行 1360:
 function GetTimeZoneByGMT($z) function GetTimeZoneByGMT($z)
 </​code>​ </​code>​
 + 
 + 
 ==== htmlspecialchars_array() ==== ==== htmlspecialchars_array() ====
  
行 1269: 行 1383:
 function htmlspecialchars_array($array) function htmlspecialchars_array($array)
 </​code>​ </​code>​
 + 
 + 
 ==== FilterCorrectName() ==== ==== FilterCorrectName() ====
  
行 1290: 行 1406:
 function FilterCorrectName($s) function FilterCorrectName($s)
 </​code>​ </​code>​
 + 
 + 
 ==== CheckCanBeString() ==== ==== CheckCanBeString() ====
  
行 1311: 行 1429:
 function CheckCanBeString($obj) function CheckCanBeString($obj)
 </​code>​ </​code>​
 + 
 + 
 ==== BuildSafeURL() ==== ==== BuildSafeURL() ====
  
行 1335: 行 1455:
 function BuildSafeURL($url,​$appId) function BuildSafeURL($url,​$appId)
 </​code>​ </​code>​
 + 
 + 
 ==== BuildSafeCmdURL() ==== ==== BuildSafeCmdURL() ====
  
行 1356: 行 1478:
 function BuildSafeCmdURL($paramters) function BuildSafeCmdURL($paramters)
 </​code>​ </​code>​
 + 
 + 
 ==== utf84mb_filter() ==== ==== utf84mb_filter() ====
  
行 1377: 行 1501:
 function utf84mb_filter($sql) function utf84mb_filter($sql)
 </​code>​ </​code>​
 + 
 + 
 ==== utf84mb_fixHtmlSpecialChars() ==== ==== utf84mb_fixHtmlSpecialChars() ====
  
行 1395: 行 1521:
 function utf84mb_fixHtmlSpecialChars() function utf84mb_fixHtmlSpecialChars()
 </​code>​ </​code>​
 + 
 + 
 ==== utf84mb_convertToUCS4() ==== ==== utf84mb_convertToUCS4() ====
  
行 1416: 行 1544:
 function utf84mb_convertToUCS4($matches) function utf84mb_convertToUCS4($matches)
 </​code>​ </​code>​
 + 
 + 
 ==== utf84mb_convertToUTF8() ==== ==== utf84mb_convertToUTF8() ====
  
行 1437: 行 1567:
 function utf84mb_convertToUTF8($matches) function utf84mb_convertToUTF8($matches)
 </​code>​ </​code>​
 + 
 + 
 ==== VerifyWebToken() ==== ==== VerifyWebToken() ====
  
行 1464: 行 1596:
 function VerifyWebToken($webTokenString,​$webTokenId,​$key) function VerifyWebToken($webTokenString,​$webTokenId,​$key)
 </​code>​ </​code>​
 + 
 + 
 ==== CreateWebToken() ==== ==== CreateWebToken() ====
  
行 1491: 行 1625:
 function CreateWebToken($webTokenId,​$time,​$key) function CreateWebToken($webTokenId,​$time,​$key)
 </​code>​ </​code>​
 + 
 + 
 ==== CheckIsRefererValid() ==== ==== CheckIsRefererValid() ====
  
行 1507: 行 1643:
 function CheckIsRefererValid() function CheckIsRefererValid()
 </​code>​ </​code>​
 + 
 + 
 ==== CheckCSRFTokenValid() ==== ==== CheckCSRFTokenValid() ====
  
行 1531: 行 1669:
 function CheckCSRFTokenValid($fieldName,​$methods) function CheckCSRFTokenValid($fieldName,​$methods)
 </​code>​ </​code>​
 + 
 + 
 ==== CheckHTTPRefererValid() ==== ==== CheckHTTPRefererValid() ====
  
行 1549: 行 1689:
 function CheckHTTPRefererValid() function CheckHTTPRefererValid()
 </​code>​ </​code>​
 + 
 + 
 ==== RemovePHPCode() ==== ==== RemovePHPCode() ====
  
行 1570: 行 1712:
 function RemovePHPCode($code) function RemovePHPCode($code)
 </​code>​ </​code>​
 + 
 + 
 ==== GetIDArrayByList() ==== ==== GetIDArrayByList() ====
  
行 1594: 行 1738:
 function GetIDArrayByList($array,​$keyname) function GetIDArrayByList($array,​$keyname)
 </​code>​ </​code>​
 + 
 + 
 ==== GetBackendCSPHeader() ==== ==== GetBackendCSPHeader() ====
  
行 1612: 行 1758:
 function GetBackendCSPHeader() function GetBackendCSPHeader()
 </​code>​ </​code>​
 + 
 + 
 ==== CheckIncludedFiles() ==== ==== CheckIncludedFiles() ====
  
行 1633: 行 1781:
 function CheckIncludedFiles($file) function CheckIncludedFiles($file)
 </​code>​ </​code>​
 + 
 + 
 ==== Logs_Dump() ==== ==== Logs_Dump() ====
  
行 1649: 行 1799:
 function Logs_Dump() function Logs_Dump()
 </​code>​ </​code>​
 + 
 + 
zblogphp/development/functions/common.1589813702.txt · 最后更改: 2020/05/18 22:55 由 zx.asd