]]>Regex quick referencehttp://www.tkk7.com/miaoyachun/archive/2012/06/13/380694.htmlMilo鐨勬搗鍩?/dc:creator>Milo鐨勬搗鍩?/author>Wed, 13 Jun 2012 08:06:00 GMThttp://www.tkk7.com/miaoyachun/archive/2012/06/13/380694.htmlhttp://www.tkk7.com/miaoyachun/comments/380694.htmlhttp://www.tkk7.com/miaoyachun/archive/2012/06/13/380694.html#Feedback0http://www.tkk7.com/miaoyachun/comments/commentRss/380694.htmlhttp://www.tkk7.com/miaoyachun/services/trackbacks/380694.html
[abc] A single character: a, b or c [^abc] Any single character but a, b, or c [a-z] Any single character in the range a-z [a-zA-Z] Any single character in the range a-z or A-Z ^ Start of line $ End of line \A Start of string \z End of string . Any single character \s Any whitespace character \S Any non-whitespace character \d Any digit \D Any non-digit \w Any word character (letter, number, underscore) \W Any non-word character \b Any word boundary character () Capture everything enclosed (a|b) a or b a? Zero or one of a a* Zero or more of a a+ One or more of a a{3} Exactly 3 of a a{3,} 3 or more of a a{3,6} Between 3 and 6 of a
]]>Use PHP var_export API to dump data to filehttp://www.tkk7.com/miaoyachun/archive/2012/04/10/373687.htmlMilo鐨勬搗鍩?/dc:creator>Milo鐨勬搗鍩?/author>Tue, 10 Apr 2012 02:54:00 GMThttp://www.tkk7.com/miaoyachun/archive/2012/04/10/373687.htmlhttp://www.tkk7.com/miaoyachun/comments/373687.htmlhttp://www.tkk7.com/miaoyachun/archive/2012/04/10/373687.html#Feedback0http://www.tkk7.com/miaoyachun/comments/commentRss/373687.htmlhttp://www.tkk7.com/miaoyachun/services/trackbacks/373687.html
<?php
$a=array('abc'=>"123");
# var dump var_dump($a);
# var_export echovar_export($a);
# export to file $b=var_export($a,true); error_log($b."\n",3,"/tmp/ymiao.log");
]]>Profilling PHP by xdebughttp://www.tkk7.com/miaoyachun/archive/2012/02/17/370178.htmlMilo鐨勬搗鍩?/dc:creator>Milo鐨勬搗鍩?/author>Fri, 17 Feb 2012 04:58:00 GMThttp://www.tkk7.com/miaoyachun/archive/2012/02/17/370178.htmlhttp://www.tkk7.com/miaoyachun/comments/370178.htmlhttp://www.tkk7.com/miaoyachun/archive/2012/02/17/370178.html#Feedback0http://www.tkk7.com/miaoyachun/comments/commentRss/370178.htmlhttp://www.tkk7.com/miaoyachun/services/trackbacks/370178.htmlinstall xdebug
; load as zend ext zend_extension=/usr/lib64/php/modules/xdebug.so ; make sure profiler_enable disable xdebug.profiler_enable=off ; enable trigger xdebug.profiler_enable_trigger=on ; make sure web server has write privilege on output dir xdebug.profiler_output_dir=/tmp