Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

php×Ö·û´®º¯Êý

 
1²éÕÒ×Ö·ûλÖú¯Êý£º
strpos($str,search,[int]):²éÕÒsearchÔÚ$strÖеĵÚÒ»´ÎλÖôÓint¿ªÊ¼£»
stripos($str,search,[int]):º¯Êý·µ»Ø×Ö·û´®ÔÚÁíÒ»¸ö×Ö·û´®ÖеÚÒ»´Î³öÏÖµÄλÖ᣸ú¯Êý¶Ô´óСд²»Ãô¸Ð
strrpos($str,search,[int]):²éÕÒsearchÔÚ$strÖеÄ×îºóÒ»´Î³öÏÖµÄλÖôÓint
2¡¢ÌáÈ¡×Ó×Ö·ûº¯Êý£¨Ë«×Ö½Ú£©
submit($str,int start[,int length]):´Ó$strÖÐstratλÖÿªÊ¼ÌáÈ¡[length³¤¶ÈµÄ×Ö·û´®]¡£
strstr($str1,$str2):´Ó$str1(µÚÒ»¸öµÄλÖÃ)ËÑË÷$str2²¢´ÓËü¿ªÊ¼½ØÈ¡µ½½áÊø×Ö·û´®;ÈôûÓÐÔò·µ»ØFALSE¡£
stristr() ¹¦ÄÜͬstrstr£¬Ö»ÊDz»Çø·Ö´óСд¡£
strrchr() ´Ó×îºóÒ»´ÎËÑË÷µ½µÄ×Ö·û´¦·µ»Ø£»Óô¦£ºÈ¡Â·¾¶ÖÐÎļþÃû
3¡¢Ìæ»»×Ö·û´®
str_replace(search,replace,$str):´Ó$strÖвéÕÒsearchÓÃreplaceÀ´Ìæ»»
str_irreplace(search,replace,$str):
strtr($str,search,replace):Õâ¸öº¯ÊýÖÐreplace²»ÄÜΪ"";
substr_replace($Str,$rep,$start[,length])$strԭʼ×Ö·û´®,$repÌæ»»ºóµÄÐÂ
×Ö·û´®,$startÆðʼλÖÃ,$lengthÌæ»»µÄ³¤¶È£¬¸ÃÏî¿ÉÑ¡
4¡¢×Ö·û³¤¶È
int strlen($str)
5¡¢±È½Ï×Ö·ûº¯Êý
int strcmp($str1,$str2):$str1&gt;=<$str2·Ö±ðΪÕý1,0,-1£¨×Ö·û´®±È½Ï£©
strcasecmp() ͬÉÏ£¨²»·Ö´óСд£©
strnatcmp("4","14") °´×ÔÈ»ÅÅÐò±È½Ï×Ö·û´®
strnatcasecmp() ͬÉÏ£¬£¨Çø·Ö´óСд£©
6¡¢·Ö¸î³ÉÊý×麯Êý
str_split($str,len):°Ñ$str°´len³¤¶È½øÐзָ»ØÊý×é
split(search,$str[,int]):°Ñ$str°´search×Ö·û½øÐзָ»ØÊý×éintÊǷָ´Î£¬ºóÃæµÄ½«²»·Ö¸î
expload(search,$str[,int])
7¡¢È¥³ý¿Õ¸ñ£ºltrim¡¢rtrim¡¢trim
8¡¢¼Ó¿Õ¸ñº¯Êý
chunk_split($str,2);Ïò$str×Ö·ûÀïÃæ°´2¸ö×Ö·û¾Í¼ÓÈëÒ»¸ö¿Õ¸ñ£»
9¡¢chr¡¢ord--·µ»ØÖ¸¶¨µÄ×Ö·û»òascii
10¡¢HTML´úÂëÓйغ¯Êý
nl2br()£ºÊ¹\nת»»Îª&lt;br>¡£
strip_tags($str[,'<p>'])£ºÈ¥³ýHTMLºÍPHP±ê¼Ç
ÔÚ$strÖÐËùÓÐHTMLºÍPHP´úÂ뽫±»È¥³ý£¬¿ÉÑ¡²ÎÊýΪhtmlºÍPHP´úÂë×÷ÓÃÊǽ«±£Áô
¿ÉÑ¡²ÎÊýËùдµÄ´úÂë¡£
È磺echo strip_tags($text, '<br><p>');
htmlspecialchars($str[,²ÎÊý]):Ò³ÃæÕý³£Êä³öHTML´úÂë²ÎÊýÊÇת»»·½Ê½
11¡¢×Ö·û´óСдת»»º¯Êý
strtolower($str) ×Ö·û´®×ª»»ÎªÐ¡Ð´
strtoupper($str) ×Ö·û´®×ª»»Îª´óд
ucfirst($str) ½«º¯ÊýµÄµÚÒ»¸ö×Ö·ûת»»Îª´óд
ucwords($str) ½«Ã¿¸öµ¥´ÊµÄÊ××Öĸת»»Îª´óд
12¡¢Êý¾Ý¿âÏà¹Øº¯Êý
addslashes($str)£ºÊ


Ïà¹ØÎĵµ£º

phpÁ¬½ÓaccessµÄÀà

<?php
/*
 * Created on 2008-10-25
 *
 * developer by Alex.do QQ:20779512
 * PHP 5.0
 */
 class mdbClass {
    var $dbPath = 'database/#123123#.mdb';    //Êý¾Ý¿â·¾¶
    var $tabName;     & ......

PHP Ϊʲôfunction


PHP Ϊʲôfunction ÔÚÉùÃ÷ʱûÓÐÉùÃ÷²ÎÊý,¶øµ÷ÓÃʱ¼ÓN¸ö²ÎÊýÈ´ÊÇÔÊÐíµÄ
2008-11-13 20:14:38    ÆäËû |  ÆÀÂÛ(7) |  ä¯ÀÀ(721)
ÈçÌâ
//ÉùÃ÷
function test(){};
$a = '';
$b = '';
$c = '';
//µ÷ÓÃ
test($a,$b,$c,1,2,3);
ÏàÐŲ»ÉÙÐֵܽãÃÃÒ²Ôø¾­Óöµ½Í¬ÑùµÄÎÊÌâ¡£
why?
¸Õ¿ªÊ¼ÎÒÒ²Í¦Ó ......

PHPÖÐCURL·½·¨curl_setopt()º¯ÊýµÄһЩ²ÎÊý

 
ÒÔϹØÓڴ˺¯Êý¸÷ÏîʹÓòÎÊý:
bool curl_setopt (int ch, string option, mixed value)
curl_setopt()º¯Êý½«ÎªÒ»¸öCURL»á»°ÉèÖÃÑ¡Ïî¡£option²ÎÊýÊÇÄãÏëÒªµÄÉèÖã¬valueÊÇÕâ¸öÑ¡Ïî¸ø¶¨µÄÖµ¡£
ÏÂÁÐÑ¡ÏîµÄÖµ½«±»×÷Ϊ³¤ÕûÐÎʹÓÃ(ÔÚoption²ÎÊýÖÐÖ¸¶¨)£º
CURLOPT_INFILESIZE
: µ±ÄãÉÏ´«Ò»¸öÎļþµ½Ô¶³ÌÕ¾µã£¬Õâ¸öÑ¡Ï ......

PHPÓëħÊÞ

ͨ¹ýħÊÞ¿´PHPÉè¼Æģʽ
Ç°¶Îʱ¼ä¿´µ½ÓÐÈËÓÃħÊÞÀ´½âÊÍÉè¼Æģʽ£¬¸Ð¾õºÜÓÐÒâ˼£¬ÓÚÊÇÎÒ°ÑËü¸ÄÁ˸ģ¬ÓÖÌí¼ÓÁËЩÉè¼ÆģʽÄÚÈÝ£¬½ñÌì·¢³öÀ´¡£ÓÐЩµØ·½½è¼øÁËÇ°È˵ÄÄÚÈÝ£¬Ã»ÓÐ×¢Ã÷£¬ÇëÇ°È˲»Òª¼û¹Ö°¡¡£
ÕâÀïÓôó¼Ò¸ÐÐËȤµÄħÊÞ3À´ÌÖÂÛPHPµÄ¼¸ÖÖ³£¼ûµÄÉè¼Æģʽ£ºµ¥¼þģʽ¡¢²ßÂÔģʽ¡¢¹¤³§Ä£Ê½¡¢¹Û²ìÕßģʽ¡£½ñÌì¾Í½²ÕâËĸö°É£¬Ò ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ