摘要: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml" xml:lang="zh-cn" lang="zh-cn"><head><meta http-equiv="Content-Type" 阅读全文
posted @ 2012-02-07 16:55 taek 阅读(22581) 评论(6) 推荐(2) 编辑
摘要: Regex 十分强大。甚至有时候过于强大。例如,考虑当 regex".*"被应用到字符串 “The author of 'Wicked' also wrote 'Mirror, Mirror.'” 上时发生的情况。虽然预期preg_match()可能返回两个匹配,但是您可能会惊讶地发现只有一个结果:'Wicked' also wrote 'Mirror, Mirror.'原因是什么?除非进行指定,否则诸如*(无或多个)和+(一个或多个)之类的操作符都很贪婪。如果模式可以继续匹配,那么它可能将生成最多的结果。要使 阅读全文
posted @ 2012-02-07 16:39 taek 阅读(2943) 评论(0) 推荐(0) 编辑
摘要: strrchr() 函数查找字符串在另一个字符串中最后一次出现的位置,并返回从该位置到字符串结尾的所有字符。如果成失败,否则返回 false。例子 1<?phpecho strrchr("Hello world!","world");?>输出:world!例子 2<?phpecho strrchr("Hello world!",111);?>输出:orld! 阅读全文
posted @ 2012-02-07 16:13 taek 阅读(216) 评论(0) 推荐(0) 编辑
摘要: ECshop 数据库表结构-- 表的结构 `ecs_account_log`CREATE TABLE IF NOT EXISTS `ecs_account_log` (`log_id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT COMMENT '自增ID号',`user_id` mediumint(8) unsigned NOT NULL COMMENT '用户登录后保存在session中的id号,跟users表中的user_id对应',`user_money` decimal(10,2) NOT NULL CO 阅读全文
posted @ 2012-02-07 15:28 taek 阅读(446) 评论(0) 推荐(0) 编辑
摘要: define('ROOT_PATH', str_replace('includes/init.php', '', str_replace('\\', '/', __FILE__))); 阅读全文
posted @ 2012-02-07 13:46 taek 阅读(327) 评论(0) 推荐(0) 编辑