<?xml version="1.0" encoding="gbk"?>
<rss version="2.0">
<channel>
 <title><![CDATA[战地日记]]></title>
 <link><![CDATA[http://bbs.lampbrother.net]]></link>
 <description><![CDATA[最新帖子]]></description>
 <copyright><![CDATA[Copyright(C) LAMP兄弟连]]></copyright>
 <generator><![CDATA[http://www.phpwind.com]]></generator>
 <lastBuildDate><![CDATA[Fri, 18 May 2012 02:56:53 +0000]]></lastBuildDate>
 <ttl><![CDATA[60]]></ttl>
 <pubDate><![CDATA[Thu, 17 May 2012 13:30:14 +0000]]></pubDate>
<item>
 <title><![CDATA[42期，张诚 第一个项目感受，与兄弟们分享]]></title>
 <description><![CDATA[<font size="2"><font face="宋体 ">首个项目已经结束了</font></font><font size="2"><font face="宋体 ">两</font></font><font size="2"><font face="宋体 ">周多了</font></font><font size="2"><font face="宋体 ">，</font></font><font size="2"><font face="宋体 ">把前几天自己的项目感受翻出来看了看，发现好多的语句不通还有好多错字，今天又整理了一下发出来跟兄弟们分享和共勉。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">在项目的开发过程中学</font></font><font size="2"><font face="宋体 ">习</font></font><font size="2"><font face="宋体 ">巩固了很多知识，也学到了很多解决问题的有效方法。为了能把剩下的课程学好，让下一个项目更好更快的完成，</font></font><font size="2"><font face="宋体 ">同时让自己把学过的知识记得更牢固</font></font><font size="2"><font face="宋体 ">我把这一次收获的经验总结一下</font></font><font size="2"><font face="宋体 ">，跟各位兄弟分享下</font></font><font size="2"><font face="宋体 ">。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">1<font face="宋体 ">，做好项目需求策划。</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">任何一个项目不会是无需求的，只有把需求确定好</font></font><font size="2"><font face="宋体 ">、</font></font><font size="2"><font face="宋体 ">理解透</font></font><font size="2"><font face="宋体 ">，</font></font><font size="2"><font face="宋体 ">才能确定需要哪些功能模块，莫名的冲动，会让你奔向邪恶或者陷入麻烦。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">2<font face="宋体 ">，一定要去要规划流程，画出流程图，确定功能模块。</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">如果没有流程规划，你做着做着就会发现某个做完的模块跟另一个模块好像重复或者无法衔接，或者逻辑上有些矛盾，如此</font></font><font size="2"><font face="宋体 ">会让</font></font><font size="2"><font face="宋体 ">你陷入反复修改</font></font><font size="2"><font face="宋体 ">中，</font></font><font size="2"><font face="宋体 ">时间是那么的有限，不规划流程就是在浪费生命。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">3<font face="宋体 ">，命名规则及数据库规划</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">要确定一套有效的避免重复和易理解的命名规则，特别是变量，函数，字段的命名上；</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">如果随意命名的话，会造成变量赋值后丢失值，某些字段值读取后莫名的改变，名字臃肿繁琐不易识别</font></font><font size="2"><font face="宋体 ">。建议</font></font><font size="2"><font face="宋体 ">按照模块和</font></font><font size="2"><font face="宋体 ">用途</font></font><font size="2"><font face="宋体 ">分类去规划，比如关于<font face="Times New Roman ">USER</font><font face="宋体 ">模块的函数名统一以</font><font face="Times New Roman ">user</font><font face="宋体 ">开头，如：</font><font face="Times New Roman ">usesrReg,userLogin,userInfo</font><font face="宋体 ">，</font><font face="Times New Roman ">userResult</font><font face="宋体 ">等既易识别，又很容确定是属于哪个功能模块的。数据表规划是根据流程规划完后，确定了功能及具体实现方式置后才能确定。字段命名一定要注意，避免</font></font></font><font size="2"><font face="宋体 ">使用保留</font></font><font size="2"><font face="宋体 ">关键字，否则会遇到<font face="Times New Roman ">SQL</font><font face="宋体 ">语句语法很正确就是没结果</font></font></font><font size="2"><font face="宋体 ">的恶梦</font></font><font size="2"><font face="宋体 ">。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">4<font face="宋体 ">，项目开发中常遇到的哪些让人郁闷的错误。</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">&nbsp;&nbsp; 1,<font face="宋体 ">单双引号是初学者数据库开发过程中必然会遇到的错误</font><font face="Times New Roman ">,</font><font face="宋体 ">如：</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">Select * from bbs_user where username=jack&nbsp;&nbsp;<font face="宋体 ">应该是</font><font face="Times New Roman ">username=&#39;jack&#39;</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&quot;Select * from bbs_user where username=$jack&quot; <font face="宋体 ">应该是</font><font face="Times New Roman ">username=&#39;$jack&#39;</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">注：引号应用双引号中可以插入单引号，单引号中的变量可以被解析，并返回单引号。还有一种情况是：</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&quot;select * from bbs_user where username=&#39;md5(addselashes(trim($_POST[&#39;password&#39;])))&#39;&quot;;</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">看着是想省事连写，觉得似乎很正确呀，但还是报错</font></font><font size="2"><font face="宋体 ">了</font></font><font size="2"><font face="宋体 ">。建议这样去写就<font face="Times New Roman ">OK</font><font face="宋体 ">了。</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">$username=md5(addselashes(trim($_POST[&#39;password&#39;])));</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&quot;select * from bbs_user where username=&#39;$username&#39;&quot;;</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&nbsp;&nbsp; 在函数应用中也会出现类似的单双引号错误，解决办法一样。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">2<font face="宋体 ">，在读取插入数据时常见的几个错误</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;在显示位置要调用某字段却发现明明数据库中有改字段却没有结果</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&quot;Select uid,username from user&quot;;&nbsp;&nbsp;&nbsp;&nbsp; Echo $result[&#39;useremail&#39;];</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">//<font face="宋体 ">是因为你没有读取此字段</font><font face="Times New Roman ">&quot;useremail&quot;,</font><font face="宋体 ">通常会发生在你开始没想读取此字段，后来</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">你突然又想让某位置显示此字段，却忘记在<font face="Times New Roman ">SQL</font><font face="宋体 ">语句中添加读取此字段。</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&quot;select u.username,u.userage,u.id,m.id,m.title,m.username from user as u,message as me where m.id=u.id&quot;;</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">当你得到结果，<font face="Times New Roman ">echo $result[&#39;id&#39;]</font><font face="宋体 ">可能不是你想要的值</font><font face="Times New Roman ">,</font><font face="宋体 ">看看</font><font face="Times New Roman ">SQL</font><font face="宋体 ">语句中是不是两个</font><font face="Times New Roman ">id,</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">最好把其中一个<font face="Times New Roman ">id</font><font face="宋体 ">改</font></font></font><font size="2"><font face="宋体 ">个</font></font><font size="2"><font face="宋体 ">别名，如：<font face="Times New Roman ">m.id as mid&nbsp;&nbsp; $result[&#39;id&#39;],$result[&#39;mid&#39;]</font><font face="宋体 ">就都可以得到</font></font></font><font size="2"><font face="宋体 ">正确</font></font><font size="2"><font face="宋体 ">的值。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">再需要</font></font><font size="2"><font face="宋体 ">注意的是</font></font><font size="2"><font face="宋体 ">：</font></font><font size="2"><font face="宋体 ">逻辑错误，检查难度很</font></font><font size="2"><font face="宋体 ">不容易超找，检查难度大</font></font><font size="2"><font face="宋体 ">。还有</font></font><font size="2"><font face="宋体 ">：在</font></font><font size="2"><font face="宋体 ">引用变量函数，可变变量的</font></font><font size="2"><font face="宋体 ">是要特别注意</font></font><font size="2"><font face="宋体 ">，特别是在和<font face="Times New Roman ">session</font><font face="宋体 ">赋值操作上，很容易造成</font><font face="Times New Roman ">session</font><font face="宋体 ">混乱，而且</font></font></font><font size="2"><font face="宋体 ">特别</font></font><font size="2"><font face="宋体 ">不容易检查</font></font><font size="2"><font face="宋体 ">出来</font></font><font size="2"><font face="宋体 ">。</font></font><font size="2"><font face="宋体 ">其实</font></font><font size="2"><font face="宋体 ">有些时候不是你想用可变变量，而是你手误多敲了一个<font face="Times New Roman ">$</font><font face="宋体 ">或者</font><font face="Times New Roman ">&amp;</font><font face="宋体 ">符号。</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">3<font face="宋体 ">，既然还没有学面向对象，那么</font></font></b></font><font size="2"><b><font face="宋体 ">建议</font></b></font><font size="2"><b><font face="宋体 ">多次使用的代码，写成函数吧，节约时间和精力。</font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">多次使用的功能，写成函数，既让前台</font></font><font size="2"><font face="宋体 ">代码</font></font><font size="2"><font face="宋体 ">更</font></font><font size="2"><font face="宋体 ">有条理</font></font><font size="2"><font face="宋体 ">，同时也</font></font><font size="2"><font face="宋体 ">大大</font></font><font size="2"><font face="宋体 ">减少了工作量，节约了时间。如我的数据操作公用函数</font></font><font size="2"><font face="宋体 ">文件</font></font><font size="2"><font face="宋体 ">db.function.php</font></font><font size="2"><font face="宋体 ">，我把具体的数据库连接、增、删、改、查，计数等方法一函数方式写在同一个文件中，并标注好注释。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="Times New Roman ">&lt;?php</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * <font face="宋体 ">数据库链接函数</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @<font face="宋体 ">函数总涉及的全局变量在</font><font face="Times New Roman ">config.php</font><font face="宋体 ">中直接定义</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; */</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function connect(){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * <font face="宋体 ">原态</font><font face="Times New Roman ">sql</font><font face="宋体 ">语句执行函数</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> * @param sql</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; * @example $sql=&quot;select * from table where field=&#39;value&#39;&quot;;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> * @example $result=quer($sql)</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> */</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">function query($sql){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* <font face="宋体 ">插入数据</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param $table string&nbsp;&nbsp;<font face="宋体 ">表名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param $fvalues array(&#39;<font face="宋体 ">字段名</font><font face="Times New Roman ">&#39;=&gt;&#39;</font><font face="宋体 ">值</font><font face="Times New Roman ">&#39;)</font><font face="宋体 ">；</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*/</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function insert($table,$fvalues){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * SELECT <font face="宋体 ">查询函数</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @param string $table<font face="宋体 ">表名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @param string $fields=&#39;field1,field2,field3&#39;;<font face="宋体 ">字段名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @orderby string $orderby=&#39;id DESC/ASC&#39;;<font face="宋体 ">排序方式</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * @groupby string $groupby=&#39;type&#39;;<font face="宋体 ">分组方式</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * @limit int $limit=5; <font face="宋体 ">查询记录数量</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * @page int $page=2;<font face="宋体 ">当前页码</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * @pagesize int $pagesize=5;<font face="宋体 ">单页面显示的记录条数</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; * @example select(&#39;user&#39;,&#39;username,password&#39;,&#39;id desc&#39;,&#39;sex&#39;,&#39;&#39;,4,10);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * @attation <font face="宋体 ">如果用分页功能，请将</font><font face="Times New Roman ">$limit</font><font face="宋体 ">参数设为空</font><font face="Times New Roman ">&#39;&#39;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; */</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function select($table,$fields=&#39;*&#39;,$where=&#39;&#39;,$order=&#39;&#39;,$groupby=&#39;&#39;,$limit=&#39;&#39;,$page=0,$pagesize=10){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * <font face="宋体 ">数据表数据更新</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @param string <font face="宋体 ">表名 例：</font><font face="Times New Roman ">$table=&#39;bbs_user&#39;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @param string where<font face="宋体 ">语句：</font><font face="Times New Roman ">$where=&quot;username=&#39;zhangcheng&#39; and uid=28&quot;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @param string <font face="宋体 ">更新的自对和对应的值为</font><font face="Times New Roman ">*$fvalues=&quot;username=&#39;name&#39;,userpsw=&#39;password&#39;&quot;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> * @param $fvalues=array(key=&gt;value)</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; * @example update(&#39;user&#39;,$_POST,&#39;id=2&#39;);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*/</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function update($table,$fvalues,$where){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">*<font face="宋体 ">删除数据方法</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @pramar string $table <font face="宋体 ">数据表名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @pramar string $where <font face="宋体 ">条件语句</font><font face="Times New Roman ">$where=&quot;userid=12 and username=&#39;jack&#39;&quot;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;* @example delet(&#39;user&#39;,&quot;username=&#39;xiaohuihui&#39;&quot;);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*/</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function delete($table,$where){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* </font></font><font size="1"><font face="宋体 ">根据</font></font><font size="1"><font face="宋体 ">sql<font face="宋体 ">语句</font></font></font><font size="1"><font face="宋体 ">统计数据条数</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param string SQL<font face="宋体 ">语句 </font><font face="Times New Roman ">$sql=&#39;select * from user&#39;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*/</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function countrows($sql){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">*</font></font><font size="1"><font face="宋体 ">根据</font></font><font size="1"><font face="宋体 "> table,where</font></font><font size="1"><font face="宋体 ">条件</font></font><font size="1"><font face="宋体 ">统计数据条数</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param string table<font face="宋体 ">表名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">*@param string where<font face="宋体 ">条件</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*/</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function sumrows($table,$where){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* table,where<font face="宋体 ">统计数据条数</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param string table<font face="宋体 ">表名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">*@param string where<font face="宋体 ">条件</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">*/</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function sumfields($table,$fields,$where){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp; * <font face="宋体 ">释放</font><font face="Times New Roman ">(</font><font face="宋体 ">关闭数据库</font><font face="Times New Roman ">)</font><font face="宋体 ">数据库链接</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> * @param source <font face="宋体 ">数据库资源类型 </font><font face="Times New Roman ">$connect=mysql_connect(&#39;localhost&#39;,&#39;root&#39;,&#39;123456&#39;)</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> * */</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">function free_db($connect){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">...</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">?&gt;</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "> </font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">5,<font face="宋体 ">别忘了完善的注释，让团队的成员都看的明白</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="Times New Roman ">C</font></font><font size="2"><font face="宋体 ">ss<font face="宋体 ">，前台页面代码块，函数方法说明，这些位置最好</font></font></font><font size="2"><font face="宋体 ">也</font></font><font size="2"><font face="宋体 ">都加上注释，检查错误的时候</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">&nbsp;&nbsp;能够迅速定位，条理更清楚。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">例<font face="Times New Roman ">:</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">样式</font></font><font size="2"><font face="宋体 ">文件内</font></font><font size="2"><font face="宋体 ">：</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">/*<font face="宋体 ">主体样式</font><font face="Times New Roman ">*/</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">#main{</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">width:960px;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">border:1px solide #dcdcdc;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 ">/*<font face="宋体 ">导航样式</font><font face="Times New Roman ">*/</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">.guidenav{</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">width:960px;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">height:40px;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">float:left;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">background:url(../images/guidenavbgcenter2.jpg) repeat-x top;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">前台页面</font></font><font size="1"><font face="宋体 ">代码块：</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&lt;!--<font face="宋体 ">导航开始</font><font face="Times New Roman ">--&gt;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="Times New Roman ">&lt;div class=&quot;mainmenu&quot;&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;ul&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;?php </font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">//<font face="宋体 ">导航数据查询</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$remenu=select(&#39;menu&#39;);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">if($remenu){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">while(list($key,$menu)=each($remenu)){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">?&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;li&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;a href=&quot;&lt;?php echo $menu[&#39;url&#39;]?&gt;&quot; target=&quot;&lt;?php echo $menu[&#39;target&#39;] ?&gt;&quot;&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;b&gt;&lt;?php echo $menu[&#39;title&#39;]?&gt;&lt;/b&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;/a&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;/li&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;?php</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">?&gt;</font></font><font size="1"><font face="Times New Roman "> </font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&lt;/ul&gt;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">&lt;/div&gt;</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&lt;!--<font face="宋体 ">导航结束</font><font face="Times New Roman ">--&gt;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">公用函数</font></font><font size="1"><font face="宋体 ">部分注释</font></font><font size="1"><font face="宋体 ">：</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">/**</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;*</font></font><font size="1"><b><font face="宋体 "> SELECT <font face="宋体 ">数据库查询</font><font face="Times New Roman ">SELECT</font><font face="宋体 ">方法函数</font></font></b></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param string $table<font face="宋体 ">表名</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @param string $fields<font face="宋体 ">字段名</font><font face="Times New Roman ">&#39;field1,field2,field3&#39;; </font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 ">* @orderby string $orderby<font face="宋体 ">排序方式</font><font face="Times New Roman ">&#39;id DESC/ASC&#39;; </font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;* @groupby string$groupby<font face="宋体 ">分组方式</font><font face="Times New Roman ">; </font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;* @limit int $limit<font face="宋体 ">查询记录数量</font><font face="Times New Roman ">; </font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;* @page int $page<font face="宋体 ">当前页码</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;* @pagesize int $pagesize<font face="宋体 ">单页面显示的记录条数</font><font face="Times New Roman ">;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;* @example select(&#39;user&#39;,&#39;username,password&#39;,&#39;id desc&#39;,&#39;sex&#39;,&#39;&#39;,4,10);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;* @attation <font face="宋体 ">如果用分页功能，请将</font><font face="Times New Roman ">$limit</font><font face="宋体 ">参数设为空</font><font face="Times New Roman ">&#39;&#39;;</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="宋体 "> *@return array <font face="宋体 ">结果集数组</font><font face="Times New Roman ">$rows</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; */</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">Function</font></font><font size="1"><font face="宋体 "> </font></font><font size="1"><font face="Times New Roman ">select($table,$fields=&#39;*&#39;,$where=&#39;&#39;,$order=&#39;&#39;,$groupby=&#39;&#39;,$limit=&#39;&#39;,$page=0,$pagesize=10){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">if(!is_resource($connect)) {</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$connect=connect();</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$sql=&#39;&#39;;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$table=$table==&#39;&#39;?&#39;&#39;:DB_PREFIX.$table;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">if(is_array($fields)){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$fields=$fields==&#39;&#39;?&#39;*&#39;:implode(&#39;,&#39;,$fields);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}else{</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$fields=$fields==&#39;&#39;?&#39;*&#39;:$fields;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$where=$where==&#39;&#39;?&#39;&#39;:&#39; WHERE &#39;.$where;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$order = $order == &#39;&#39; ? &#39;&#39; : &#39; ORDER BY &#39;.$order;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$group = $group == &#39;&#39; ? &#39;&#39; : &#39; GROUP BY &#39;.$group;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$pagesize=$pagesize==&#39;&#39;? &#39;&#39; :$pagesize;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">if($page!=&#39;&#39;){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;$page=(int)$page;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$pagesize=(int)$pagesize;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$start=(int)(($page)-1)*$pagesize;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$limit=&#39; LIMIT &#39;.$start.&#39;,&#39;.$pagesize;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}else{</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$limit = $limit == &#39;&#39; ? &#39;&#39; : &#39; LIMIT &#39;.$limit;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$sql=&#39;SELECT &#39; .$fields.&#39; FROM &#39; .$table.$where.$group.$order.$limit;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$re=query($sql);</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">$rows=array();</font></font><font size="1"><font face="Times New Roman "> </font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">if($re&amp;&amp;mysql_affected_rows()){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> while($row=mysql_fetch_array($re,MYSQL_ASSOC)){</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> $rows[]=$row;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "> }</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">return $rows;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}else{</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">return 0;</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman "></font></font><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="Times New Roman "></font></font><br /><font size="1"><font face="Times New Roman ">}</font></font><font size="1"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">同样的道理：</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">用户的操作</font></font><font size="2"><font face="宋体 ">也都</font></font><font size="2"><font face="宋体 ">写成函数：</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">注册</font></font><font size="1"><font face="宋体 ">user</font></font><font size="1"><font face="宋体 ">reg(); </font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">检查用户名是否已被注册<font face="Times New Roman ">checkreg();</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">检查是否登录<font face="Times New Roman ">checklogin();</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">注销<font face="Times New Roman ">logout();</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">加分<font face="Times New Roman ">addmoney();</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="1"><font face="宋体 ">设置头像<font face="Times New Roman ">setheadpic();</font></font></font><font size="1"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">帖子的相关操作也可以这样做，这里只抛砖引玉，开动脑筋，多思考逻辑上的东西，</font></font><font size="2"><font face="宋体 ">好像</font></font><font size="2"><font face="宋体 ">变得越来越简单</font></font><font size="2"><font face="宋体 ">了，对吧？</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">6<font face="宋体 ">，代码一样可以很美</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">页面</font></font><font size="2"><font face="宋体 ">代码写的时候一定要注意层次关系，合理缩进和空行；以提高代码清晰性和可读性。否则你自己检查的时候看着毫无规则的代码阵，心里好烦。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">（</font></font><font size="2"><font face="宋体 ">引用</font></font><font size="2"><font face="宋体 ">细说<font face="Times New Roman ">php</font></font></font><font size="2"><font face="宋体 ">：</font></font><font size="2"><font face="宋体 ">145</font></font><font size="2"><font face="宋体 ">页</font></font><font size="2"><font face="宋体 ">）一个源文件的两个代码段之间使</font></font><font size="2"><b><font face="宋体 ">用两个空行作为间隔</font></b></font><font size="2"><font face="宋体 ">；两个函数声明之间</font></font><font size="2"><font face="宋体 ">；</font></font><font size="2"><font face="宋体 ">局部变量和函数 声明之间</font></font><font size="2"><font face="宋体 ">；</font></font><font size="2"><font face="宋体 ">块注释或单行注释之前</font></font><font size="2"><font face="宋体 ">；</font></font><font size="2"><font face="宋体 ">一个函数体内的两个逻辑代码段之间使用</font></font><font size="2"><b><font face="宋体 ">一个空行间隔</font></b></font><font size="2"><font face="宋体 ">。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">7<font face="宋体 ">，用户是上帝，所以要注重用户体验哦</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">&nbsp;&nbsp; 页面设计效果就不用说了，说说用操作方面。用户的每一步怎需考虑用户操作便捷，给予引导，规划，提示，同时给他（她）以附加值</font></font><font size="2"><font face="宋体 ">和惊喜</font></font><font size="2"><font face="宋体 ">等。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">比如：注册时输入字符不符合要求，让输入框改变颜色，以表示提醒。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">&nbsp;&nbsp; 尽可能简化注册步骤，并在页面显示提示相关步骤和信息。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">注册完成后不是返回重新登录而是，注册完成即为登录状态。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">发帖后醒目提示给予奖励分值并鼓励多发贴。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">类似的用户体验的东西，你可以</font></font><font size="2"><font face="宋体 ">花一点时间和</font></font><font size="2"><font face="宋体 ">精力去</font></font><font size="2"><font face="宋体 ">分析，可以</font></font><font size="2"><font face="宋体 ">让你的网站更</font></font><font size="2"><font face="宋体 ">受</font></font><font size="2"><font face="宋体 ">用户喜爱（网站用户体验提示需要从运营和整个项目战略层次综合考虑在此仅从本次项目页面功能上考虑，点到为止。文凯老师上课的时候讲的很多</font></font><font size="2"><font face="宋体 ">客户体验</font></font><font size="2"><font face="宋体 ">方面的</font></font><font size="2"><font face="宋体 ">知识</font></font><font size="2"><font face="宋体 ">，可以总结一下综合运用）。</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 "> 顺便提一下，发布帖子可以做成可方便<font face="Times New Roman ">SEO</font><font face="宋体 ">的，如后台管理帖子可以设置关键词，标题，页面描述等信息，写到数据库字段里（</font><font face="Times New Roman ">title,keywords,description</font><font face="宋体 ">）</font><font face="Times New Roman ">,</font><font face="宋体 ">在前台页面</font><font face="Times New Roman ">head</font><font face="宋体 ">内读取。连接，图片也要加上相关的标题或说明。有利于网页被收录哟，不要堆积太多关键词哦，会被搜索引擎关禁闭的。</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">8<font face="宋体 ">，</font></font></b></font><font size="2"><b><font face="宋体 ">做好时间管理</font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">把项目周期时间规划做好，</font></font><font size="2"><font face="宋体 ">可以使用每日工作计划，时间管理里书面写下。</font></font><font size="2"><font face="宋体 ">每天的工作量要量化严格执行，才能保证你的项目顺利完成；并且有足够的时间去测试调整。先完成要求的部分在去做扩展的，切莫因为<font face="Times New Roman ">20</font><font face="宋体 ">分丢掉</font><font face="Times New Roman ">100</font><font face="宋体 ">分。</font></font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><b><font face="宋体 ">9<font face="宋体 ">，收获的是自己的</font></font></b></font><font size="2"><b><font face="宋体 "></font></b></font><br /><font size="2"><font face="宋体 ">要坚持独立完成，哪怕会比别人慢一点；因为你不是要给老师交作业，而是给自己</font></font><font size="2"><font face="宋体 "></font></font><br /><font size="2"><font face="宋体 ">一个</font></font><font size="2"><font face="宋体 ">检验</font></font><font size="2"><font face="宋体 ">结果。</font></font><br /><font size="2"><font face="宋体 ">都是说是夏天了，女生的裙子，应该越<font face="Times New Roman ">*</font><font face="宋体 ">越好</font><font face="Times New Roman ">.</font></font></font><br /><font size="2"><font face="宋体 "><font face="Times New Roman ">我觉得项目总结也应该是这样，那我就写到这吧，不多写了。</font></font></font><br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">在这里希望更多的兄弟分享你们的收获。请大家多多指教！</font></font><br /><font size="2"><font face="宋体 "></font></font> <br /><font size="2"><font face="宋体 "></font></font> <br /><font size="2"><font face="宋体 "></font></font><font size="2"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ---42期小白 JACK</font></font>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118790.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (张诚_42)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Thu, 17 May 2012 13:30:14 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[战地小记]]></title>
 <description><![CDATA[<br /><font size="2"><font face="宋体 ">来到兄弟连已经</font></font><font size="2">2</font><font size="2"><font face="宋体 ">个多月了，从一个</font></font><font size="2">PHP</font><font size="2"><font face="宋体 ">菜鸟中的菜鸟变成了小菜鸟，希望自己从这走出去，可以变成一个菜鸟。为什么要这么说呢，因为涛哥告诉过我们，就算你从兄弟连毕业了，你也不要把自己当成大神，因为比你厉害的人多了去了，一定要保持一颗菜鸟的心，不断的在</font></font><font size="2">PHP</font><font size="2"><font face="宋体 ">的海洋中遨游，为到达彼岸而奋斗。</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">在兄弟连的苦就不多说了，兄弟连的弟兄们都知道，没来兄弟连的兄弟可能也略有耳闻。说实话，没来之前看到论坛上有的同学说什么经常通宵学习，我就是一眼扫过，根本不细看，因为是真的狠难相信啊。来了之后才真正感受到了兄弟连的学习气氛，狠</font></font><font size="2">NB</font><font size="2"><font face="宋体 ">的学习气氛啊，原来那些狠人</font></font><font size="2">&amp;&amp;</font><font size="2"><font face="宋体 ">大神们就在我的身边。</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">为什么兄弟连的兄弟们这么能拼，个个都像拼命三郎似的？为什么连女生（‘男生’？你懂的！！！）都那么能熬夜？经过一段时间才慢慢发现，来这的大部分兄弟吧，可能都有自己的故事，有的是单纯的喜欢着</font></font><font size="2">PHP</font><font size="2"><font face="宋体 ">（‘当成梦中情人了’？），有的是为了能改变自己的现状（‘白花花的银子’？），还有的是为了“那些年，我们一起追的女孩”等等等等等吧。很多很多，如果没有那么一股信念的话，相信很多人都是挺不住的，在这里跟所有的兄弟连的兄弟们说一句话：“你们都是好样的，我</font></font><font size="2">*</font><font size="2"><font face="宋体 ">你们（</font></font><font size="2">*</font><font size="2"><font face="宋体 ">代表</font></font><font size="2">…</font><font size="2"><font face="宋体 ">可以发挥自己的想象力）“。</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">哎！！！上网的时间快完了，怎么这个样子啊，还有很多话没说完呢！说到这里了，那就介绍下兄弟连的上网时间吧。每周</font></font><font size="2">3</font><font size="2"><font face="宋体 ">天，每次一小时，寝室不能上网，大家可以想象一下吧。这里真是一个好地方啊，好到无法用言语来表达我的感受了，不过呢，也教会了我们一定要珍惜时间，特别是要珍惜上网时间，不要在上网时做些没用的事情，因为时间过的很快滴，等你想做一些有意义的事情的时候，会发现已经断网了，很悲催吧！！！</font></font><font size="2"></font><div align="center"><font size="2"><font face="宋体 ">嘿嘿！！！完了，期待下次相见！！！！！！</font></font><font size="2"></font></div>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118789.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (李海峰_43)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Thu, 17 May 2012 12:47:44 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[第一个项目感受]]></title>
 <description><![CDATA[<br /><font size="2"><font face="宋体 ">第一个项目终于完成了，同时也再也不想去动那个网站了，终于明白了之前老师们说的，等你完成了这个项目就再也不想看到它了，我想现在大部分人应该都有这种心情……只可意会，不可言传。</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">第一个星期讲</font></font><font size="2">HTML</font><font size="2"><font face="宋体 ">和</font></font><font size="2">DIV+CSS</font><font size="2"><font face="宋体 ">，主要说怎样布局网站界面，现在想想，都不记得那一星期讲的什么了，莫非这就是达到了练太极的最高境界，学过就忘，才证明你是真的记住了？希望如此！</font></font><br /><br /><font size="2"><font face="宋体 ">然后就是一个多月的</font></font><font size="2">PHP</font><font size="2"><font face="宋体 ">基础课程，说实话，我真的很不喜欢那些函数，尤其当张涛老师说大家自己去试着写写的时候，我真想的想知道，为什么写</font></font><font size="2">PHP</font><font size="2"><font face="宋体 ">这门语言的大人物，没有把可能遇到的每一个都写出来呢，为什么他就不把好人做到底呢？？不过事实就是，当你自己真正有需要的时候还得自己去写，有些东西是要靠自己去发挥，自己学会去创造自己所需要的东西，当真的做出来的时候（虽然这种情况很少出现），感觉真的很神奇！</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">项目是从后台开始写的，开始的时候是老师带着做，所以还算轻松，但速度也仅是跟着老师走的。直到老师不带着了，开始连接前后台的时候，我是真的是迷茫了，就一直纳闷，前台和后台是怎样连起来的，直到看到班里某位同学做的演示，然后，恍然大悟，原来数据库的作用在这里。明白了这个，剩下的就简单了，一直做增、删、改、查，再增、删、改查、渐渐地就变成</font></font><font size="2">Ctrl+C</font><font size="2"><font face="宋体 ">、</font></font><font size="2">Ctrl+V</font><font size="2"><font face="宋体 ">……，然后，网站的雏形大概就出来了，自己想买什么就从网上弄个图片卖点什么，然后想买多少就买多少，关键是还不用付钱，想想这生活真好，结局大家也都知道——拿不到货！</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">来这之前，只是懂点网络表面化的方面，不明白原理，为什么我写个“兄弟连”，然后“百度一下”，就会出来好多个“</font></font><font size="2">*</font><font size="2"><font face="宋体 ">兄弟连</font></font><font size="2">*</font><font size="2"><font face="宋体 ">”，做完这个项目，算是明白了，原来是如此之简单（光说搜索功能，不谈其他高深的），所以更下定决心了，接下来一定更要好好学习，争取天天向上！</font></font><font size="2"></font><br /><font size="2"><font face="宋体 ">大家共同努力，加油吧！</font></font><font size="2"></font><br /><br /><font size="2"><font face="宋体 "></font></font><font size="2"></font>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118788.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (刘芳芳_43)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Thu, 17 May 2012 11:56:39 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[第一个项目的简单感受]]></title>
 <description><![CDATA[ <br /><font size="3"><font face="宋体 ">从开学到现在，有</font></font><font size="3"><font face="宋体 ">多天了，在学习</font><font face="Times New Roman ">php</font><font face="宋体 ">的初级阶段，感觉学的东西都很空，而且觉得东西有些不好理解，随着历时</font><font face="Times New Roman ">2</font><font face="宋体 ">周的项目的磨练，我得到了很多磨练。原来不理解的东西，也有所收获。</font></font><font size="3"><font face="宋体 "></font></font><br /><font size="3"><font face="宋体 ">现在说一些项目的具体感受</font></font><font size="3"><font face="宋体 "></font></font><br /><font size="3"><font face="宋体 ">首先，做第一个项目，我了解到了一个网址的制作流程，在这之前以为很牛</font><font face="Times New Roman ">X</font><font face="宋体 ">的网站，自己通过简单的学习，也能仿造一些简单的网页，也了解到有很多很多要学习的东西。同学中的牛人真是不少啊！</font></font><font size="3"><font face="宋体 "></font></font><br /><font size="3"><font face="宋体 ">其次，第一个项目，其实质就是锻炼了：我们的对数据库的调配能力。简单明了的就是对数据库的中数据的增删改查。其中多表查询有些难度，当中有些环节自己把握不准。还需要多加复习，多加锻炼。还有严谨的逻辑判断，也是一个程序员应该做的，以防给自己的以后的网站留下什么明显的</font><font face="Times New Roman ">bug</font><font face="宋体 ">。</font></font><font size="3"><font face="宋体 "></font></font><br /><font size="3"><font face="宋体 ">最后，发现自己的知识掌握的不好，需要多加的复习！还有自己写的代码出错的时候尽量自己排，这也是一个能帮自己提升能力的办法！不要总是依赖别人帮忙！</font></font><font size="3"><font face="宋体 "></font></font><br /><font size="3"><font face="宋体 ">在完成第一个简陋的项目之后，我发现自己也略有成长，为自己以后的学习，增加了一些信心。</font></font><font size="1"><font face="宋体 "></font></font><br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118786.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (李昌东_43)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Thu, 17 May 2012 11:01:12 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[老李玩微博经验分享之如何发微博]]></title>
 <description><![CDATA[ <br /><font size="5"><font face="微软雅黑 ">1、不要写满140字，因字数已满，会让别人不便于转发评论，所谓中国人常讲的留白天地宽在微博同样适用，有强迫症不写满不罢休的童鞋请淡定点……</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">2、微博推广的力量源自真实、互动，所以个人品牌微博会强于企业微博，企业微博形式比较正式和拘泥，企业推广应该是个人带动企业，另外，不要忽略了企业微博的互动，只是单向的发布就失去了意义，要把企业微博作为和粉丝沟通的一个阵地。比如亚马逊中国的企业微博就很二，只是单向发布……当然大多企业微博都是如此，就算你留言骂死它，它也真的像死了一样一点无回应。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">3、中国微博展现方式更加丰富，和外国的Twritter不同，文字要幽默吸引人，最好附录图片和视频，这样在整页的信息显示中会更加突出，图片可以搜索获得，一定要注意，幽默是微博上很重要的元素，有图有真相，有视频有互动。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">4、如果想打造个人品牌的话，原创内容至少要保持80%以上，内容真诚不做作，硬性广告不推荐，可以柔性加入内容或者幽默方式体现，保持自己的style 。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">5、不要都是宣传，可以发你的思考、你的想法、你或你发现的新鲜事趣事、热门话题事件的讨论、传播思想和理念，总之什么都可以……原则就是发大家有兴趣看的内容，而不是你喜欢发的内容。微薄需要随时留意随时积累，想起来好点子就记录下来，有机会可以写再完善。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">6、关注什么人代表了你的品位，比如别关注苍井空，虽然你可能很喜欢。转发代表了你对内容认可，转发什么微薄也表明了你的立场态度，转发最好有简短评论，所以别乱转发。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">7、一个微博的内容，也要稍微斟酌，开头一定要吸引人，最好语不惊人死不休，中间要有条理，把事讲清楚，结尾要突出，要有回味，要让人余味无穷。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">8、最佳发微博时间，上午9:30-12:00 下午3:30-5:30&nbsp;&nbsp;晚上8:30-11:30 ，别太早发，谁刚睡醒都不上微博，也别太晚发，晚睡的不是在加班就是在打游戏，周末可以少发或不发，好容易休息大多不咋看微博效果不好。不佳时间可以有idea先记录下来。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">9、利用节假日发相关话题微博，往往比较吸引大家。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">10、发微博宁缺毋滥，最好一天发三五条，与粉丝保持互动，群发可以用微博通，但是主要维护的微博，比如腾讯和新浪要多关注。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="5"><font face="微软雅黑 ">11、多留意网络事件和网络流行语，融入你的微博。</font></font><br /><font size="5"><font face="微软雅黑 "> </font></font><br /><font size="1"><font face="宋体 "></font></font><font size="1"><font face="Times New Roman "></font></font> <br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118735.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (李明)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Wed, 16 May 2012 05:51:31 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[写给为梦想而徘徊的人]]></title>
 <description><![CDATA[<br /><font size="3"><font face="微软雅黑 ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;说到梦想大家都会有种种感想。下面写给关于为梦想还在徘徊的人们！<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;自从来到兄弟连，转眼之间已经一个月了，期间总是想说些什么，但因为时间的缘故还是累积到了今天，不要认为我是没时间</font></font><br /><font size="3"><font face="微软雅黑 ">来写，我呢，是真没时间来写（这貌似像一句废话，汗。。。<img src="http://bbs.lampbrother.net/images/post/smile/3/sweat.gif" />），从早上起床，到上午听老师讲课，到下午温习消化，和到晚上做试题预</font></font><br /><font size="3"><font face="微软雅黑 ">习明天的内容。这一天中的每分钟都被排满了，连吃饭时间都算在内，很紧迫，可能这就是一种氛围吧，因为大家都是这样在做。每天深</font></font><br /><font size="3"><font face="微软雅黑 ">夜回到宿舍躺在床上的时候，也总会感慨这一天是多么的充实。<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 下面我来说说我自己吧，我呢，用我们年轻帅气的jayjun老师的话来讲，我是一个有故事的人。<br /> 我是个高中毕业生，经历了高三紧迫的学习，有些反感学习了。所以09年毕业之后没有继续上大学，而是开始进入社会参加工</font></font><br /><font size="3"><font face="微软雅黑 ">作，我的第一份工作是开车，去做了一个司机助手，其实主要是学习开车。一年半后，就是到2010年年底，我拿到了驾驶证，但是后来我</font></font><br /><font size="3"><font face="微软雅黑 ">就辞去了这份工作，原因就是这一年半来发现自己所做的并不是自己所喜欢的。然后回到了家，2010年在家过年，其中有一天我去了我一</font></font><br /><font size="3"><font face="微软雅黑 ">个朋友家，他是我同一届的同学，高中毕业之后 ，他去某个技能培训学校学网络工程类的专业但是还没毕业，交谈之中他跟我讲了一些关</font></font><br /><font size="3"><font face="微软雅黑 ">于计算机类的东西，他是学PHP的，也说了一些关于php现在的优势。虽然不是很懂，但是大概的了解些东西。<br /> 从那之后我发现我爱上了计算机，也不知道因为什么，就是想去了解它，感觉它特别神奇。然后跟家里商量关于想培训计算机</font></font><br /><font size="3"><font face="微软雅黑 ">知识的想法。结果父母没有同意，原因一是因为我已经离开学校一年多了可能已经没有学习的能力了，二是，要去的学校总共下来得五万</font></font><br /><font size="3"><font face="微软雅黑 ">块学费，对于那时我的家庭来说，确实是一笔巨额。在无论怎样说服父母都没有结果的情况下，我决定了一个念头，就是自己打工挣钱，</font></font><br /><font size="3"><font face="微软雅黑 ">然后去上学。于是第二年的三月份只身一人去往了苏州，有朋友跟我说苏州有好多电子厂在招人，不要学历，工资一月加班多的情况下就</font></font><br /><font size="3"><font face="微软雅黑 ">有三千多块呢。到了苏州在那呆了两天后找到了份工作。底薪一月1140,辛辛苦苦做到九月份的时候发现手里只有三千块，连五万块的毛</font></font><br /><font size="3"><font face="微软雅黑 ">都不够。心情沮丧之后回到了家里，希望父母再考虑下自己的想法。结果还是同样的结果。在那段时间里心情特别低落，自己终于有了目</font></font><br /><font size="3"><font face="微软雅黑 ">标，知道了前进的方向，却因为某些因素挡住了去路。到了十月份，自己又跑到了廊坊富士康。想努力再试试运气。结果进去了才发现，</font></font><br /><font size="3"><font face="微软雅黑 ">每月下来的钱还是所剩无几。工作到2012年3月份手里持有的钱还是差的太远。而且所从事的工作极其枯燥无味，在那里也看到了好多年</font></font><br /><font size="3"><font face="微软雅黑 ">轻的面孔在一天天、一月月、一年年的，在不停的重复一个动作，自己也似乎明白了，青春每个人就那么几天，是有限的，不能再浪费它</font></font><br /><font size="3"><font face="微软雅黑 ">了。仔细想了想，从开始决定学习计算机到现在，一年过去了，自己却什么都没有。想过辞职，但之后能去怎样，将要何去何从，又没有</font></font><br /><font size="3"><font face="微软雅黑 ">钱。思想在挣扎着，后来一次跟朋友电话中，他跟我说到，他有一个同事，是在兄弟连出来的学的是php，工资还不错。想学的话可以去</font></font><br /><font size="3"><font face="微软雅黑 ">那。这是我第二次听到php这个名字了。虽然不太清楚，但是大概知道了它也是一门编程语言等等。又问了一下学费，这也是我关心的。</font></font><br /><font size="3"><font face="微软雅黑 ">我朋友的一句回答点燃了我心中的希望。他说，兄弟连现在是零学费学习，就是在学习期间不用缴纳任何学费，毕业之后再分期十月还款</font></font><br /><font size="3"><font face="微软雅黑 ">。听完这句话后我似乎又看到了目标，想想自己何不先学，学到知识后再利用学到的知识还款呢。况且不用再去浪费时间了。之后我就去</font></font><br /><font size="3"><font face="微软雅黑 ">了网吧搜索关于兄弟连的信息。最后联系上了老师，跟老师讲了我的情况，在老师确定我符合贷款标准后。我当天就来到了北京，来到了</font></font><br /><font size="3"><font face="微软雅黑 ">兄弟连了解了情况。第二天回到廊坊，也没有去办理辞职手续，就直接收拾行囊离开了那个令人发狂的地方。<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 然后来到了兄弟连，住进了宿舍，开始汲取梦寐以求的知识。一天一天的跟同期学员们早起晚归奋力的学习。经过了一个月后</font></font><br /><font size="3"><font face="微软雅黑 ">，发现自己已经确实充实了好多好多。我也意识到自己并没有来错地方，在兄弟连看来就像是一个大家庭，适宜的学习环境，老师的关爱</font></font><br /><font size="3"><font face="微软雅黑 ">和学员的相互帮助，一切看起来都是那么的好，我都有种想哭的感觉了。</font></font><font size="3"><font face="微软雅黑 ">从开始到现在我有一种感想，当一个人曾经在梦想的边缘挣扎了</font></font><br /><font size="3"><font face="微软雅黑 ">好久好久，不能靠近它。却终于在有一天有了一个了向他挺近</font></font><font size="3"><font face="微软雅黑 ">的机会。你会怎么去想？我想大家都会抱着同样的想法，就是“感谢”。</font></font><br /><font size="3"><font face="微软雅黑 ">感谢它对你那种恩泽。使你有大展宏图的机会，使你不至于至死</font></font><font size="3"><font face="微软雅黑 ">都没能靠近你梦想。我不想说太多无用的了，最后，我就是要感谢兄弟连</font></font><br /><font size="3"><font face="微软雅黑 ">，是它，给了我一个拼搏的机会，也是它，给我了一个奋斗的舞</font></font><font size="3"><font face="微软雅黑 ">台。不管我的未来会怎么样，成功与否，我曾经在做过，曾经在努力过。</font></font><br /><font size="3"><font face="微软雅黑 ">我要感谢兄弟连！！&nbsp;&nbsp; because I&nbsp;&nbsp;do it.</font></font>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118702.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (王志方_45)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Tue, 15 May 2012 13:50:36 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[小小感悟]]></title>
 <description><![CDATA[<font face="宋体 "><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;第一个项目完工了，总算是有了一小点成就感，起码比以前写的单纯增删改查的项目多了好多东西，哈哈，我这人很容易就知足的。</font><font face="宋体 "><br /></font><font face="宋体 ">感受！也不知道是经过一个星期的</font><font face="Calibri ">linux</font><font face="宋体 ">的学习忘记了，还是感受根本就不大，当热也许和以前用其他语言复制过一个类似的项目也有关系吧。</font><font face="宋体 "><br /></font><font face="宋体 ">现在网上已经很难见到面向过程的程序了，大家都把它当成了网站程序入门来学习，既然是基础的产物，那么我们做这个项目的目的必须是去用它巩固我们的基础，回过头来可以想下哪个模块我们还能自己再写出来，哪写函数我们用它简化了我们的代码。</font><font face="宋体 "><br /></font><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;看累了吧，说点我曾经不开心的事让大家</font><font face="Calibri ">happy</font><font face="宋体 ">下。</font><font face="宋体 "><br /></font><font face="宋体 ">毕业后的第一份工作干了不到两个月就被开了，</font><font face="Calibri ">b2b</font><font face="宋体 ">系统可能有用过的，我就是去改造</font><font face="Calibri ">b2b</font><font face="宋体 ">系统二次开发去的，我爸已经问过我不下</font><font face="Calibri ">5</font><font face="宋体 ">次“现在给一份像第一份的工作能不能干的了”，哈哈，很明显还是干不了嘛，将搜索框改造成</font><font face="Calibri ">ajax</font><font face="宋体 ">动态获取热门关键词，将产品页面的功能，简介，评价，做成选项卡点击后获取获取内容等等吧，貌似学完高级课程才能会的。很明显公司不会养活一个不会干他们活得人。之后我接触过米拓，织梦，帝国等系统，这些无论哪个都不会在前台页面里嵌入</font><font face="Calibri ">php</font><font face="宋体 ">代码，这才是我们最后要的，所以嘛明确我们的目标，整理整理我们的思绪，重新打起十二分的精神，学我们可以不被公司白养活的东西。</font></font><br /><font face="宋体 ">项目中我比较喜欢商品分类和订单模块，我不知道以后学的面向对象是不是会将增删改查变的简单，但它绝对不会把涛哥给的无限分类思想和订单流程简化了，哈哈，基础重要，好的思路也的储蓄起来呀，整个商城做完我们是不是可以说我们可以手写</font><font face="Calibri ">html</font><font face="宋体 ">，</font><font face="Calibri ">css</font><font face="宋体 ">，</font><font face="Calibri ">php</font><font face="宋体 ">代码了，哈哈，手写代码，起码可以欺负欺负那些成天用</font><font face="Calibri ">dreamweaver</font><font face="宋体 ">的人了，比如说以前的我，哈哈。整个项目我们发现想的时间明显多与写代码的时间，整理好思路，代码不是啥问题，因为代码不会有涛哥有严哥，思路不会，哈哈，最好是自己想想好，说不定能想处个新产品来（未完待续</font><font face="Calibri ">…..</font><font face="宋体 ">）</font><font face="宋体 "></font>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118701.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (杨耿_43)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Tue, 15 May 2012 11:56:59 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[小小的感受]]></title>
 <description><![CDATA[<span style="color:#e36c09 "><font size="3">项目结束好久了，一直都没写点东西，今天上传一点。</font></span><br /><br /><font size="3"><span style="color:#000000 "> </span></font><br /><font size="3"><span style="color:#000000 "> <span style="color:#fac08f "><font face="宋体 ">之前无限憧憬，又无限纠结的项目阶段终于在昨天结束了，接下来的就是项目审核期了。</font></span></span></font><span style="color:#fac08f "><font size="3"><font face="宋体 ">这次项目期比传说中的要长那么些，为了能做好，我们奉献了自己的五一长假（其实也就</font>3<font face="宋体 ">天）。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">五一过去了，也终于解脱了。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">半个多月的项目阶段，真的是涉及到了前期所学的基础和扩展。从</font>html<font face="宋体 ">到</font>div+css<font face="宋体 ">，从函数到数组，从</font>php<font face="宋体 ">到</font>mysql<font face="宋体 ">，在这次项目中，无一没有用到。一个项目下来，手写代码能力提高了不止一个档次。经常奋斗到太阳初升再回去睡觉，经常是睡梦中都在敲代码，研究功能，拼装字串，顺带背函数。</font>--<font face="宋体 ">这就是兄弟连艰苦，但又充满乐趣的生活。</font></font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">这个项目中，改变了我对函数的看法，就如凯哥说的，函数就是你家一条狗，你叫它干嘛它就干嘛，有了函数，很多逻辑性的东西可以用这种工具去解决。数组函数，字串函数，用于项目各个角落。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">先开始做的是后台，直接操作数据库，用到大量的</font>sql<font face="宋体 ">语句，发送语句，判断语句，以前预习，包括上课没弄懂的，在项目中不断遇到，慢慢的变得熟悉，到现在的熟练。涛哥强调的几个函数每天都被我敲几十遍，虽然有时犯迷糊，敲错了不少。到后面阶段，已经能够自行处理错误了。作为一个好的程序员，首先要拥有排错的能力，错并不可怕，就怕你不知道错在哪。现在发现，</font>mysql<font face="宋体 ">真是个好东西，比起之前的文本式存储方便了很多，包括我之前学的</font>asp<font face="宋体 ">用的</font>access<font face="宋体 ">。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">在学</font>sql<font face="宋体 ">之前先接触的文本式存储虽然没有在项目中直接用到，但是它的方法确很使用。那就是遍历数组</font>/<font face="宋体 ">资源。逐条读出，有条不紊。还有数组的操作。遍历数组，对信息分割，合并，都是之前的基础知识。一点点的积累，一点的扩展，才造就一个又一个功能模块。这些都离不开</font>html<font face="宋体 ">，</font>div+css<font face="宋体 ">，函数，字串，数组，</font>mysql<font face="宋体 ">。当然也少不了我。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">要想做出一个合格的项目，离不开基础知识。现在做的项目都是这些东西支撑着，它的扩展，我们想得到的，想不到的，都能用基础知识拼出来。</font></font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">网站前台，实现首页信息数据库提取，后台操作数据提取类别，包括是否显示等，是集美观和数据库操作的，二者都得兼顾。项目中的错误，能让我更加准确的认识到我哪方面薄弱，然后得以加强。刚开始的时候，对数据库的操作不是很熟，甚至是陌生。老师的演练，同学的讲解，慢慢带我走出了不懂的圈子。还有数组的拼装，字串的分割等等。</font></font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">成功的态度决定一切，这句话早在初中老师就跟我们说过，这条标语贴在我们黑板上方，鲜红醒目。来到兄弟连，这句话又一次引领我，虽然这次没贴出来，但却贴在我的心里，谢谢张晓光老师，把这一句话提及。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">第一阶段结束了，迎接而来的是下一个阶段，这个阶段会比第一阶段要幸苦许多，但是，我不怕，既然来到了兄弟连，就得学好，那样才对得起自己。我来这不是虚度光阴，而是来成长。以前的不懂事，也该过去了。长大了，也该承担些，不该让父母再操心。</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"><font face="宋体 ">收拾好身心，迎接接下来的日子。兄弟连，让学习成为一种习惯！</font></font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"> </font></span><br /><span style="color:#fac08f "><font size="3"> </font><font size="3"><br /></font></span><br /><br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118700.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (徐浩_43)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Tue, 15 May 2012 11:54:29 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[我们帅气的教官]]></title>
 <description><![CDATA[<span id="att_21103" class="f12"><span id="td_att21103" onmouseover="postAttImgHover('menu_att21103','td_att21103');" style="display:inline-block;" class="J_attImg"><img src="http://bbs.lampbrother.net/attachment/thumb/Mon_1205/252_84894_262fd2ddcdcd01f.jpg?32" border="0" onclick=" window.open('http://bbs.lampbrother.net/attachment/Mon_1205/252_84894_262fd2ddcdcd01f.jpg?32');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ></span><div id="menu_att21103" class="fl" style="display:none;"><div class="pw_menu" style="position:absolute;z-index:1;"><div style="border:1px solid ;background:;padding:5px 10px;"><p><span class="mr10">图片:20070803152053b9093.jpg</span></p></div></div></div></span><br />两位教官在我们心中的形象高大和威武，无以言表，拙图一幅。<br />欢迎帅哥美女和帅哥对二位教官点评！<br /> <br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118670.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (张诚_42)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Mon, 14 May 2012 11:27:59 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[LAMP兄弟连第一届篮球比赛-总决赛现场直击！（海量图片）]]></title>
 <description><![CDATA[2012.05.10，LAMP兄弟连第一届篮球比赛总决赛现场，天气比较凉爽，有点忽大忽小的风，但是不影响比赛的正常进行，下午六点比赛开始，观众也将球场包围起来，都是自己班或者是其他班的学员，场上气氛有点紧张，一方面打到决赛了，气氛反而比较轻松了。<br />对阵双方是39期和43期，两边实力相当，本场比赛打的非常精彩，双方上演对攻战，上半场结束双方只差一分，下半场39期稳住了比赛节奏，打的不骄不躁，从而拉开了比分，最后赢得了LAMP兄弟连第一届篮球比赛的冠军，恭喜他们。<br /><br />对阵班级 39期&nbsp;&nbsp;VS&nbsp;&nbsp;43期<br />裁判员 王效良<br />领队 谢长林（39期）&nbsp;&nbsp;严海军（43期）<br />赛场维护 朱林杰&nbsp;&nbsp;荣俊峰 田越 徐浩<br />记录员 宋灯健 敖晓松<br />39期出场名单&nbsp;&nbsp;&nbsp;&nbsp;崔勇斌&nbsp;&nbsp;庄沛鑫&nbsp;&nbsp;侯佳林&nbsp;&nbsp;黄波&nbsp;&nbsp;夏文斌&nbsp;&nbsp;沈浩&nbsp;&nbsp;朱苪达&nbsp;&nbsp;许鸿毅&nbsp;&nbsp;王燕威&nbsp;&nbsp;段拓&nbsp;&nbsp;蔺明&nbsp;&nbsp;杜秀全<br />43期出场名单&nbsp;&nbsp;&nbsp;&nbsp;吴豪威&nbsp;&nbsp;梁海阳&nbsp;&nbsp;张卫&nbsp;&nbsp;李丁&nbsp;&nbsp;吴启生&nbsp;&nbsp;刘子健&nbsp;&nbsp;李学&nbsp;&nbsp;张学海&nbsp;&nbsp;李冰&nbsp;&nbsp;张海瑞&nbsp;&nbsp;阚智<br /> <br />上图：<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_024.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_024.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />39期胖子起跳抢球<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_023.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_023.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />43期李冰组织篮下进攻<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_022.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_022.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />挡拆<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_021.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_021.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />39期学员积极防守，阵形很好<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_020.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_020.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />上篮<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_019.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_019.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />豪哥带球突破<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_018.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_018.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />暂停时间搞怪<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_017.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_017.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />胖子<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_016.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_016.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />43期学员罚球<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_015.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_015.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />反击<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_014.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_014.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />上篮<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_013.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_013.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />兄弟连扣篮第一人崔勇斌镇守篮下<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_012.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_012.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />罚球<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_011.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_011.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />下半场交换场地，崔勇斌上篮<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_010.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_010.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />带球突破<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_009.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_009.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />出手<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_008.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_008.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />上篮<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_007.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_007.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />39期暂停布置战术<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_006.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_006.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br />豪哥打起控卫，启生挡拆<br /> <br />比赛结束了，下面是39期庆祝的照片<br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_004.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_004.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_003.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_003.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_002.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_002.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_001.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_001.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br />下面是第二名，43期的上场队员们，你们也是好样的。<br /><img src="http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_000.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120514/06/56284936201205140624001048680369642_000.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br />第一届篮球赛还有一场就要全部结束了，下一场比赛由兄弟连教师联队 VS 冠军队伍，届时会有全程视频录播，敬请期待。]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118640.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (张沫)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sun, 13 May 2012 22:42:55 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[老李玩微博经验分享之基本信息设置]]></title>
 <description><![CDATA[<span style="background-color:yellow "><font face="宋体 "><span style="background-color:#ffffff ">&nbsp;&nbsp;&nbsp;&nbsp;<font size="5">微博现在有多火，不用哥说大家也知道鸟，这篇小文就是和大家分享下玩微博第一点：设置好基本信息。</font></span></font></span><br /><font size="1"><span style="background-color:yellow "><font face="Times New Roman "></font></span></font> <br /><font size="1"><span style="background-color:yellow "><font face="Times New Roman "><span style="background-color:#ffffff ">&nbsp;&nbsp;&nbsp;&nbsp; <font size="5">&nbsp;&nbsp;</font></span><font size="5">1、&nbsp;&nbsp;</font></font></span></font><span style="background-color:yellow "><font size="5"><font face="宋体 ">头像</font></font></span><span style="background-color:yellow "><font face="Times New Roman "></font></span><br /><font face="宋体 "><font size="5">&nbsp;&nbsp;最好使用自己真实的照片，主要截取头部附近，头一定要大，保证缩成小图也能看清，可以从自己觉得还算有人样的照片中截取，形状要正方形，现在主流微博都是正方形头像显示，别分辨率太低，太低大图会虚，如果人不是特别磕碜，还是要清楚点。</font><a href="http://t.qq.com/LAMPBrother_liming" target="_blank" ><font size="5">http://t.qq.com/LAMPBrother_liming</font></a><font size="5"> 这个微博的头像就设置的很好，可以参考。</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="Times New Roman "> </font></font><br /><font size="5"><span style="background-color:yellow "><font face="Times New Roman "><span style="background-color:#ffffff ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>2、&nbsp;&nbsp;</font></span><span style="background-color:yellow "><font face="宋体 ">昵称</font></span><span style="background-color:yellow "><font face="Times New Roman "></font></span></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 用真名，便于个人品牌营销，如果用网名，一定要是之前有人气积累，也可以，若真名已经被占用，可以加前缀，如我在腾讯用实名李明，在新浪用</font><font face="Times New Roman ">LAMP</font><font face="宋体 ">兄弟连李明。</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="Times New Roman "> </font></font><br /><font size="5"><span style="background-color:yellow "><font face="Times New Roman "><span style="background-color:#ffffff ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </span>3、&nbsp;&nbsp;</font></span><span style="background-color:yellow "><font face="宋体 ">自我介绍</font></span><span style="background-color:yellow "><font face="Times New Roman "></font></span></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;简洁、明确，突出主要信息，清楚告诉来访者，你是谁，有啥特征，最好幽默一点诗意一点。</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;我的新浪微博</font><font face="Times New Roman ">70</font><font face="宋体 ">字版本：</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; “北漂老男孩，做过程序员，干过运维，跑过市场，当过讲师，</font><font face="Times New Roman ">LAMP</font><font face="宋体 ">兄弟连总监，</font><font face="Times New Roman ">Linux</font><font face="宋体 ">狂热分子，</font><font face="Times New Roman ">PHP</font><font face="宋体 ">技术推动者。找我点过来：</font><font face="Times New Roman "><a href="http://bbs.lampbrother.net/" target="_blank" >http://bbs.lampbrother.net</a></font><font face="宋体 ">”</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </font><font face="宋体 ">腾讯微博</font><font face="Times New Roman ">140</font><font face="宋体 ">字版本：</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; “</font><font face="Times New Roman ">70</font><font face="宋体 ">后北漂</font><font face="Times New Roman ">IT</font><font face="宋体 ">老男孩，做过程序员，干过运维，跑过市场，当过讲师，</font><font face="Times New Roman ">LAMP</font><font face="宋体 ">兄弟连总监，</font><font face="Times New Roman ">Linux</font><font face="宋体 ">狂热分子，</font><font face="Times New Roman ">PHP</font><font face="宋体 ">技术推动者，开源软件拥趸。致力于打造中国最大的</font><font face="Times New Roman ">PHP</font><font face="宋体 ">黄埔军校，找我请点过来：</font><font face="Times New Roman "><a href="http://bbs.lampbrother.net/" target="_blank" >http://bbs.lampbrother.net</a> </font><font face="宋体 ">，无兄弟，不编程；不抛弃，不放弃。”</font></font><br /><span style="background-color:yellow "><font face="Times New Roman "></font></span><font size="5"> </font><br /><font size="5"><span style="background-color:yellow "><font face="Times New Roman "><span style="background-color:#ffffff "><font face="Arial ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </font></span>4、&nbsp;&nbsp;</font></span><span style="background-color:yellow "><font face="宋体 ">个人标签</font></span><span style="background-color:yellow "><font face="Times New Roman "></font></span></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp;&nbsp;&nbsp;用于别人搜索到你，所以要体现微博内容最合适的关键词，最好和你的工作或关注及推广的内容相关。新浪和腾讯都是只可以设置</font><font face="Times New Roman ">10</font><font face="宋体 ">个标签，记住，全部用光否则是那啥青年！</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</font><font face="宋体 ">我的标签：</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;LAMP</font><font face="宋体 ">兄弟连</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;PHP</font></font><br /><font size="5"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Linux</font></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 培训</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 教育</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 创业</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 就业</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 互联网</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 程序员</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 大学生</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="Times New Roman "> </font></font><br /><font size="5"><font face="Times New Roman ">&nbsp;&nbsp;&nbsp;&nbsp; <span style="background-color:#ffff00 ">5、</span></font><span style="background-color:yellow "><font face="宋体 ">其他</font></span><font face="Times New Roman "></font></font><br /><font face="宋体 "><font size="5">&nbsp;&nbsp; 个性域名，最好别乱写，有点寓意或者好记的是首选，比如 <font face="Times New Roman "><a href="http://weibo.com/limingmessage" target="_blank" >http://weibo.com/limingmessage</a> 这个就不错</font></font></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 职业信息最好写公司名称，如：</font><font face="Times New Roman ">LAMP</font><font face="宋体 ">兄弟连，便于找到同僚。</font><font face="Times New Roman "></font></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 通过实名认证最好，可大大提高可信度，而且看起来比较吊。</font></font><font face="Times New Roman "></font><br /><font size="5"><font face="宋体 ">&nbsp;&nbsp; 腾讯微博可以更换皮肤，我之前用的兄弟连</font><font face="Times New Roman ">CS</font><font face="宋体 ">图片口味有点重，最近也变成小清新了，用清爽点便于阅读，参见 <font face="Times New Roman "><a href="http://t.qq.com/LAMPBrother_liming" target="_blank" >http://t.qq.com/LAMPBrother_liming</a> </font></font></font><br /><font size="5"><font face="Times New Roman "> </font></font><br /><font face="Times New Roman "></font><font size="5"><span style="background-color:#ffc000 "> </span></font><br /><font size="5"><span style="background-color:#ffc000 "><font face="宋体 ">&nbsp;&nbsp; 关注以下两个微博，再发育！涨人品！有艳遇！得永生！袋袋泡面有料包！个个妹子非人妖！！</font></span></font><br /><font face="Times New Roman "><font size="5"><span style="background-color:#ffc000 ">&nbsp;&nbsp;&nbsp;&nbsp; </span></font><a href="http://weibo.com/limingmessage" target="_blank" ><font size="5"><span style="background-color:#ffc000 ">http://weibo.com/limingmessage</span></font></a></font><br /><font face="Times New Roman "><font size="5"><span style="background-color:#ffc000 ">&nbsp;&nbsp;&nbsp;&nbsp; </span></font><a href="http://t.qq.com/LAMPBrother_liming" target="_blank" ><font size="5"><span style="background-color:#ffc000 ">http://t.qq.com/LAMPBrother_liming</span></font></a></font><br /><font size="1"><font face="Times New Roman "></font></font> <br /><font size="1"><font face="Times New Roman "></font></font> <br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118638.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (李明)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sun, 13 May 2012 15:25:09 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[【捷哥浅谈PHP】第八弹 --- 使用PHP的date函数输出日历]]></title>
 <description><![CDATA[ <br /><font size="4">Hello，大家好，前两天给大家讲解了下RBAC【基于角色的访问控制】的基本思想，不知道大家是否已经明白其原理，使用起来是否得心应手，在开发项目的过程中可以尝试运用下，这样会理解的更加透彻，上文中给大家写的那个RBAC类，并不一定真正适合我们的项目开发，给大家写此类的目的只为帮助大家更透彻的理解RBAC的工作原理以及使用方法...</font><br /><font size="4">好了，大家可能已经觉得我啰嗦了，废话不多说了，今天来给大家讲解：</font><br /><font size="4">在已知开始日期，已知结束日期的基础上，使用PHP的date函数遍历输出日历：</font><br /><font size="4">日常生活中，日历与我们的生活工作息息相关，必不可少，所以今天给大家讲了日历以后，大家可以尝试着做一个电子日历，每天提醒自己当天要完成的任务，还是很有趣的。</font><br /><font size="4">好，首先我们先来了解一下date函数，同学们都知道，date函数可以获取当前的年月日，但date函数的功能不仅限于此，我们通过PHP官方手册来查询下它的参数看看：</font><br /> <br /><table class="read_form" style="width:100%;border-color:" cellspacing="0" cellpadding="0"><tr><td style="border-color:"><i><br />format</i> 字符</td><td style="border-color:">说明</td><td style="border-color:">返回值例子</td></tr><tr><td style="border-color:"><i><b>日</b></i></td><td style="border-color:"><span style="color:#00b050 "><b>---</b></span></td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">d</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>月份中的第几天，有前导零的 2 位数字</b></span></td><td style="border-color:"><b><span style="color:#0070c0 "><i>01</i> 到 <i>31</i></span></b></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">D</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>星期中的第几天，文本表示，3 个字母</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>Mon</i> 到 <i>Sun</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">j</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">月份中的第几天，没有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>1</i> 到 <i>31</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">l</span></i><span style="color:#ff0000 ">（“L”的小写字母）</span></td><td style="border-color:"><b><span style="color:#00b050 ">星期几，完整的文本格式</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>Sunday</i> 到 <i>Saturday</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">N</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">ISO-8601 格式数字表示的星期中的第几天（PHP 5.1.0 新加）</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>1</i>（表示星期一）到 <i>7</i>（表示星期天）</b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">S</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">每月天数后面的英文后缀，2 个字符</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>st</i>，<i>nd</i>，<i>rd</i> 或者 <i>th</i>。可以和 <i>j</i>一起用</b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">w</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>星期中的第几天，数字表示</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>0</i>（表示星期天）到 <i>6</i>（表示星期六）</b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">z</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>年份中的第几天</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>0</i> 到 <i>366</i></b></span></td></tr><tr><td style="border-color:"><i><b>星期</b></i></td><td style="border-color:">---</td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">W</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>ISO-8601 格式年份中的第几周，每周从星期一开始（PHP 4.1.0 新加的）</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>42</i>（当年的第 42 周）</b></span></td></tr><tr><td style="border-color:"><i><b>月</b></i></td><td style="border-color:">---</td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">F</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>月份，完整的文本格式，例如 January 或者 March</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>January</i> 到 <i>December</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">m</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">数字表示的月份，有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>01</i> 到 <i>12</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">M</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>三个字母缩写表示的月份</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>Jan</i> 到 <i>Dec</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">n</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>数字表示的月份，没有前导零</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>1</i> 到 <i>12</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">t</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>给定月份所应有的天数</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>28</i> 到 <i>31</i></b></span></td></tr><tr><td style="border-color:"><i><b>年</b></i></td><td style="border-color:">---</td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">L</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>是否为闰年</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>如果是闰年为 <i>1</i>，否则为 <i>0</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">o</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>ISO-8601 格式年份数字。这和 <i>Y</i> 的值相同，只除了如果 ISO的星期数（<i>W</i>）属于前一年或下一年，则用那一年。（PHP 5.1.0 新加）</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>Examples: <i>1999</i> or <i>2003</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">Y</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>4 位数字完整表示的年份</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>1999</i> 或 <i>2003</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">y</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>2 位数字表示的年份</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>99</i> 或 <i>03</i></b></span></td></tr><tr><td style="border-color:"><i><b>时间</b></i></td><td style="border-color:">---</td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">a</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>小写的上午和下午值</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>am</i> 或 <i>pm</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">A</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>大写的上午和下午值</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b><i>AM</i> 或 <i>PM</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">B</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">Swatch Internet 标准时</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>000</i> 到 <i>999</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">g</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">小时，12 小时格式，没有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>1</i> 到 <i>12</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">G</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">小时，24 小时格式，没有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>0</i> 到 <i>23</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">h</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">小时，12 小时格式，有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>01</i> 到 <i>12</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">H</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">小时，24 小时格式，有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>00</i> 到 <i>23</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">i</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">有前导零的分钟数</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>00</i> 到 <i>59</i>&gt;</b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">s</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">秒数，有前导零</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>00</i> 到 <i>59</i>&gt;</b></span></td></tr><tr><td style="border-color:"><i><b>时区</b></i></td><td style="border-color:">---</td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">e</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>时区标识（PHP 5.1.0 新加）</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>UTC</i>，<i>GMT</i>，<i>Atlantic/Azores</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">I</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>是否为夏令时</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>如果是夏令时为 <i>1</i>，否则为 <i>0</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">O</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>与格林威治时间相差的小时数</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>+0200</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">P</span></i></td><td style="border-color:"><span style="color:#00b050 "><b>与格林威治时间（GMT）的差别，小时和分钟之间有冒号分隔（PHP 5.1.3 新加）</b></span></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>+02:00</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">T</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">本机所在的时区</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>EST</i>，<i>MDT</i>（【译者注】在 Windows 下为完整文本格式，例如“EasternStandard</b></span> <span style="color:#0070c0 "><b>Time”，中文版会显示“中国标准时间”）。</b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">Z</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">时差偏移量的秒数。UTC 西边的时区偏移量总是负的，UTC 东边的时区偏移量总是正的。</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b><i>-43200</i> 到 <i>43200</i></b></span></td></tr><tr><td style="border-color:"><i><b>完整的日期／时间</b></i></td><td style="border-color:">---</td><td style="border-color:">---</td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">c</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">ISO 8601 格式的日期（PHP 5 新加）</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b>2004-02-12T15:19:21+00:00</b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">r</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">RFC 822 格式的日期</span></b></td><td style="border-color:"><span style="color:#0070c0 "><b>例如：<i>Thu, 21 Dec 2000 16:01:07 +0200</i></b></span></td></tr><tr><td style="border-color:"><i><span style="color:#ff0000 ">U</span></i></td><td style="border-color:"><b><span style="color:#00b050 ">从 Unix 纪元（January 1 1970 00:00:00 GMT）开始至今的秒数</span></b></td><td style="border-color:"><br /></td></tr></table><br /> <br /><font size="4"> 大家可以看到，php的date函数无所不能，那我们就用date函数来写一个日历出来：</font><br /> <br /> <div class="f12"><a href="javascript:"  onclick="CopyCode(document.getElementById('code1'));">复制代码</a></div><div class="blockquote2" id="code1"><ol><li>&lt;?php</li><li></li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/*+---------------------------------------------------------------------------------------+</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;| 日历类</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;+-----------------------------------------------------------------------------------------+</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;| 版权所有 lamp兄弟连&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;+-----------------------------------------------------------------------------------------+</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;| 作者: 李捷 (lijie@li-jie.me)&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;| 最后修改时间: 2012-05-9 12:30&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;+-----------------------------------------------------------------------------------------+</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;*/</li><li>class LampDate{</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $start_year;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始年份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $start_month;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始月份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $start_day;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $end_year;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//结束年份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $end_month;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//结束月份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $end_day;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//结束日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $start_time;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始时间的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $end_time;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//结束时间的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义周表头数组</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $week = array(&quot;星期一&quot;,&quot;星期二&quot;,&quot;星期三&quot;,&quot;星期四&quot;,&quot;星期五&quot;,&quot;星期六&quot;,&quot;星期日&quot;);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始时间月初的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $start;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始时间月末的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $end;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//样式表CSS文件路径</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $css;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//JS事件文件的路径</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private $script;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 日历类构造方法</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param start_year 开始年份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param start_month 开始月份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param start_day 开始日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param end_year 结束年份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param end_month 结束月份</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param end_day 结束日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param css 输出日期的样式</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param script 输出日期的事件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;public function __construct($start_year=&#39;2012&#39;,$start_month=&#39;1&#39;,$start_day=&#39;1&#39;,$end_year=&#39;2012&#39;,$end_month=&#39;12&#39;,$end_day=&#39;31&#39;,$css=&#39;style.css&#39;,$script=&#39;js.js&#39;){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;start_year = $start_year;&nbsp;&nbsp;&nbsp;&nbsp;//给开始年份赋值</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;start_month = $start_month;&nbsp;&nbsp;&nbsp;&nbsp;//给开始月份赋值</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;start_day = $start_day;&nbsp;&nbsp;&nbsp;&nbsp;//给开始日期赋值</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;end_year = $end_year;&nbsp;&nbsp;&nbsp;&nbsp;//给结束年份赋值</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;end_month = $end_month;&nbsp;&nbsp;&nbsp;&nbsp;//给结束月份赋值</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;end_day = $end_day;&nbsp;&nbsp;&nbsp;&nbsp;//给结束日期赋值</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;css = $css;&nbsp;&nbsp;&nbsp;&nbsp;//指定日期的CSS</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;script = $script;&nbsp;&nbsp;&nbsp;&nbsp;//指定日期的JS事件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取开始日期的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;start_time = strtotime($this-&gt;start_year.&quot;-&quot;.$this-&gt;start_month.&quot;-&quot;.$this-&gt;start_day);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取结束日期的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;end_time = strtotime($this-&gt;end_year.&quot;-&quot;.$this-&gt;end_month.&quot;-&quot;.$this-&gt;end_day);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取开始时间月初的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;start = strtotime($this-&gt;start_year.&quot;-&quot;.$this-&gt;start_month.&quot;-01&quot;);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取开始时间月末的时间戳</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;end = strtotime($this-&gt;end_year.&quot;-&quot;.$this-&gt;end_month.&quot;-&quot;.date(&quot;t&quot;,$this-&gt;end_time));</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取开始日期到结束日期的天数</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$this-&gt;day_count = (($this-&gt;end)-($this-&gt;start))/(24*60*60);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 获取每月表格的表头</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param i 从开始时间月初后的第几天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回表头 --年--月</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_caption($i){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str =&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;table border=&#39;0&#39; cellspacing=&#39;0&#39; cellpadding=&#39;0&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td colspan=&#39;7&#39; align=&#39;center&#39; height=&#39;30px&#39; bgcolor=&#39;#5CACEE&#39; style=&#39;color:white;font-weight:bold&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取开始时间月初第i天后的年和月</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= date(&quot;Y&quot;,$this-&gt;start+($i*(24*60*60))).&quot;年&quot;.date(&quot;m&quot;,$this-&gt;start+($i*(24*60*60))).&quot;月&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回表头</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 输出每月的星期表头方法</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回星期表头</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_week(){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str=&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;tr bgcolor=&#39;#B0E0E6&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for($w=0;$w&lt;7;$w++){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//遍历输出星期一至星期日</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td height=&#39;30px&#39; width=&#39;80px&#39; align=&#39;center&#39; style=&#39;position:relative&#39;&gt;&quot;.$this-&gt;week[$w];</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if($w==5 || $w==6){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果为周六或周日，添加放假的小图标</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;img src=&#39;jia.jpg&#39; style=&#39;position:absolute;top:0;right:0;&#39;&gt;&lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回星期头</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 补全月份前端的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param i 从开始时间月初后的第i天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回补全的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_space_front($i){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str=&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为星期一，输出一个tr换行</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;N&quot;,$this-&gt;start+($i*(24*60*60)))==1){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为该月的第一天，遍历输出空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;d&quot;,$this-&gt;start+($i*(24*60*60)))==1){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//星期n就输出n-1个空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for($m=1;$m&lt;date(&quot;N&quot;,$this-&gt;start+($i*(24*60*60)));$m++){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td bgcolor=&#39;#EDEDED&#39;&gt; &lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回输出的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 补全月份后端的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param i 从开始时间月初后的第i天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回补全的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_space_back($i){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str=&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天的天数为该月的月末</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;ymd&quot;,$this-&gt;start+($i*(24*60*60)))==date(&quot;ymt&quot;,$this-&gt;start+($i*(24*60*60)))){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//星期n就输出7-n个空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for($w=date(&quot;N&quot;,$this-&gt;start+($i*(24*60*60)));$w&lt;7;$w++){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td bgcolor=&#39;#EDEDED&#39;&gt; &lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回补全的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 输出当前日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_date($i){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str=&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为开始日期，输出背景为#7CCD7C色的表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;Ymd&quot;,$this-&gt;start+($i*(24*60*60)))==$this-&gt;start_year.$this-&gt;start_month.$this-&gt;start_day){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td align=&#39;center&#39; height=&#39;30px&#39; bgcolor=&#39;#7CCD7C&#39; style=&#39;color:white&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为结束日期，输出背景为#EE6363色的表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}elseif(date(&quot;Ymd&quot;,$this-&gt;start+($i*(24*60*60)))==$this-&gt;end_year.$this-&gt;end_month.$this-&gt;end_day){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td align=&#39;center&#39; height=&#39;30px&#39; bgcolor=&#39;#EE6363&#39; style=&#39;color:white&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为当前日期，输出背景为#EE2C2C色的表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}elseif(date(&quot;ymd&quot;,$this-&gt;start+($i*(24*60*60)))==(date(&quot;ymd&quot;,time()))){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td align=&#39;center&#39; height=&#39;30px&#39; bgcolor=&#39;#EE2C2C&#39; style=&#39;color:white&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//否则输出无背景色的表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}else{</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td align=&#39;center&#39; height=&#39;30px&#39; class=&#39;date&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//输出从开始时间月初后的第i天的日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= date(&quot;j&quot;,$this-&gt;start+($i*(24*60*60)));</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回输出的日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 输出补全的空行</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param i 从开始时间月初后的第i天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param t 每月输出的行数</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回补全的空行</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_rows($i,&amp;$t){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str=&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为星期天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;N&quot;,$this-&gt;start+($i*(24*60*60)))==7){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//换行</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为本月的最后一天并且为周日</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;ymd&quot;,$this-&gt;start+($i*(24*60*60)))==date(&quot;ymt&quot;,$this-&gt;start+($i*(24*60*60))) &amp;&amp; date(&quot;N&quot;,$this-&gt;start+($i*(24*60*60)))==7){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//行数自减</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$t--;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//行数自加</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$t++;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始时间月初后的第i天为本月的最后一天并且此时的行数小于6</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;ymd&quot;,$this-&gt;start+($i*(24*60*60)))==date(&quot;ymt&quot;,$this-&gt;start+($i*(24*60*60))) &amp;&amp; $t&lt;6){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;while($t&lt;6){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//开始输出换行</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for($n=1;$n&lt;=7;$n++){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//输出七个空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;td height=&#39;30px&#39; bgcolor=&#39;#EDEDED&#39;&gt; &lt;/td&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/tr&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//行数自加一</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$t++;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//输出补全的空行</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 结束表格的输出</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param i 从开始时间月初后的第i天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param t 日期表格的行数</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 结束表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_endtab($i,&amp;$t){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义一个空字符串</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str=&#39;&#39;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果从开始日期后的第i天为本月最后一天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;d&quot;,$this-&gt;start+($i*(24*60*60)))==date(&quot;t&quot;,$this-&gt;start+($i*(24*60*60)))){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//输出结束表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.= &quot;&lt;/table&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//并将行数计数器改为1</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$t=1;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回结束表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 获取输出月份表格的样式和事件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回月份表格的样式和事件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;private function get_style(){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str = &quot;&lt;style type=&#39;text/css&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//以只读方式打开css文件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$handle = fopen($this-&gt;css,&#39;r&#39;);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//读出来文件内容赋给一个变量</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str .= fread($handle,filesize($this-&gt;css));</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fclose($handle);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str .= &quot;&lt;/style&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str .= &quot;&lt;script type=&#39;text/javascript&#39;&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//以只读方式打开js文件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$handle = fopen($this-&gt;script,&#39;r&#39;);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//读出来文件内容赋给一个变量</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str .= fread($handle,filesize($this-&gt;script));</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fclose($handle);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str .= &quot;&lt;/script&gt;&quot;;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回文件内容</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/**</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * 获取日期表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @param i 从开始时间月初后的第i天，默认为0</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; * @return 返回日期表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; */</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;public function get_datetab($i=0){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取样式和事件</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str = $this-&gt;get_style();</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//按开始日期到结束日期的天数开始遍历日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for($i=0,$t=1;$i&lt;=$this-&gt;day_count;$i++){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果为本月的第一天</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;if(date(&quot;d&quot;,$this-&gt;start+($i*(24*60*60)))==1){</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取表头</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_caption($i);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取星期表头</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_week($i);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//补全表格前面的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_space_front($i);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//获取日期</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_date($i);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//补全表格后面的空格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_space_back($i);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//定义日期表格的行数</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_rows($i,$t);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//结束表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$str.=$this-&gt;get_endtab($i,$t);</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//返回日期表格</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return $str;</li><li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}</li><li>}</li></ol></div><br /> <br /><font size="4"> 我里面加了较全的注释，大家有什么不明白的地方可以跟帖回复提问，抑或我会在下一帖中再给大家详细讲解下大家共同遇到的问题，敬请期待....</font><br /> <br /> 输出效果：<br /> <br /><span id="att_21094" class="f12"><span id="td_att21094" onmouseover="postAttImgHover('menu_att21094','td_att21094');" style="display:inline-block;" class="J_attImg"><img src="http://bbs.lampbrother.net/attachment/Mon_1205/252_63706_14be966e6aeb090.png?46" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://bbs.lampbrother.net/attachment/Mon_1205/252_63706_14be966e6aeb090.png?46');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ></span><div id="menu_att21094" class="fl" style="display:none;"><div class="pw_menu" style="position:absolute;z-index:1;"><div style="border:1px solid ;background:;padding:5px 10px;"><p><span class="mr10">图片:万年历.png</span></p></div></div></div></span><br /> <br /> <br /> 我把代码发上来，大家可以下载研究下：<br /> <br />[attachment=21095]<br /> <br /> <br /> <span style="background-color:#ffffff "><span style="color:#333333 ">更多给力文章，请挪步：</span></span><br /><b><font size="3"><a href="http://bbs.lampbrother.net/read-htm-tid-117880.html" target="_blank" >【捷哥浅谈PHP】第一弹---php位运算符”|”和逻辑运算符”||”遇到的问题</a> </font></b><br /><b><font size="3"><a href="http://bbs.lampbrother.net/read-htm-tid-117900.html" target="_blank" >【捷哥浅谈PHP】第二弹---经典算法的运用(冒泡排序和快速排序)</a> </font></b><br /><b><font size="3"><a href="http://bbs.lampbrother.net/read-htm-tid-117921.html" target="_blank" >【捷哥浅谈PHP】第三弹---使用二分查找法查找数组中的元素位置</a> </font></b><br /><b><font size="3"><a href="http://bbs.lampbrother.net/read-htm-tid-117975.html" target="_blank" >【捷哥浅谈PHP】第四弹---递归函数</a> </font></b><br /><b><font size="3"><a href="http://bbs.lampbrother.net/read-htm-tid-118074.html" target="_blank" >【捷哥浅谈PHP】第五弹 --- 分页之九阳神功</a> </font></b><br /><b><font size="3"><a href="http://bbs.lampbrother.net/read-htm-tid-118310.html" target="_blank" >【捷哥浅谈PHP】第六弹 ---- 使用for循环输出九九乘法表</a></font></b><br /><font size="3"><span style="background-color:#ffffff "><b><a href="http://bbs.lampbrother.net/read-htm-tid-118410.html" target="_blank" ><span style="color:#4f81bd ">【捷哥浅谈PHP】第七弹 ---- 基于角色的访问控制RBAC</span></a> </b></span></font><br /> <br /> <br /> <br /><div style="margin-top: 10px;"><span style="background: none repeat scroll 0 0 #F3F9FB;border: 1px solid #A6CBE7;padding: 3px 10px;">本帖包含的部分附件只能  <a style="color: #014C90;" href="http://bbs.lampbrother.net/read-htm-tid-118637.html" target="_blank">访问</a> 社区查看</span></div>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118637.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (李捷)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sun, 13 May 2012 14:35:08 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[程序员应该具备的工作态度]]></title>
 <description><![CDATA[<font size="3">早餐后来了兴致打开兄弟连论坛，看看各位兄弟们的学习，回顾回顾以前自己的历程。</font><br /><font size="3"> </font><br /><font size="3">是的，认识我的都知道我有一个小团队</font><br /><font size="3"> </font><br /><font size="3">我最近碰到一个比较严重的问题，我发现我的程序员经常会找我说：这个功能无法实现，我们是不是换个功能。其实这个问题之前一直存在过，可以肯定大部分程序员都会这样想过，只是我以前没有在意，我最近关注，然后我尝试着自己写这样的功能，我发现并不难，我能实现。</font><br /><font size="3"> </font><br /><font size="3">那么我就找了一个下午的10多分钟时间告诉大家一个道理：程序是抽象现实世界的一种表现，理论上现实世界存在的，程序都能实现，就看你如何去实现他。说到这里我引出我要告诉大家的程序员的工作态度。</font><br /><font size="3"> </font><br /><font size="3">一、正视自己的职业，我是经营一个工作室，但是我还是每天坚持写代码，虽然不多，但是我每天都写，都会参与项目的开发，还会抽时间去关注业界的动态和新技术的发展，所以兄弟连论坛我几乎每天必看</font><br /><font size="3"> </font><br /><font size="3">二、树立一种观念：没有不可以实现的功能；各位兄弟，当你想在你老板的面前提出：老板，这个功能根本无法实现嘛？这样一个疑问的时候，你应当之前先想我可以不可以通过另外一个手段实现这个功能。我调查我的工作室员工发现程序员的一个毛病：思路固有化。每个程序员的成长历程都不一样，大家都有自己的一套解决问题的方案，那么大部分的人都不会去跳出自己的框框，而是在查询在自己的方案里能否解决这个问题，解决不了他会认为这个问题就是这个世界上无法解决的，因此固步自封。就好比几年前刚兴起DIV+CSS布局的时候，有些人就认为用table布局是可耻的，使用就是犯罪，然后有些用DIV方法无法完美解决的问题，用table能很容易实现的时候，他们还在钻牛角尖，我认为这个是愚蠢的。</font><br /><font size="3"> </font><br /><font size="3">总结以下一句话：程序是工具，真正让你强大的是你的编程思想和解决问题的能力</font><font size="3"><br /></font>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118631.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (陈千勇_29)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sun, 13 May 2012 00:26:06 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[【大官人最疯狂帖】“跟大官人混，有钱，有女人”]]></title>
 <description><![CDATA[<b>好疯狂的想法啊。</b><div style="margin-top: 10px;"><span style="background: none repeat scroll 0 0 #F3F9FB;border: 1px solid #A6CBE7;padding: 3px 10px;">本帖包含的部分附件只能  <a style="color: #014C90;" href="http://bbs.lampbrother.net/read-htm-tid-118627.html" target="_blank">访问</a> 社区查看</span></div>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118627.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (唐启优_45)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sat, 12 May 2012 16:42:34 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[brophp和ckeditor整合手记]]></title>
 <description><![CDATA[来兄弟连快一个来月了，学习氛围杠杠的，教学环境也比想象中的要好，在完成每天课后作业之外，开始看brophp的源码，自己也用brophp框架动手做了一个小的应用，实现文章增加、删除、修改功能，在此过程中用到了一个富文本编辑的工具--ckeditor,经过一天时断时续的摸索，终于将该编辑器的PHP版本和brophp框架做了整合。<br /> brophp目录结构<br />---------------<br /> |<br /> |-----bases<br /> |&nbsp;&nbsp;|<br /> |&nbsp;&nbsp;|--structure.class.php <br /> |<br /> |------classes<br /> | |<br /> |&nbsp;&nbsp;|----ckeditor<br /> |&nbsp;&nbsp;|&nbsp;&nbsp;|<br /> |&nbsp;&nbsp;&nbsp;&nbsp;|---ckeditor.class.php<br /> |&nbsp;&nbsp;&nbsp;&nbsp;|<br /> |--commons<br /> |<br /> |--libs<br /> |<br /> |--brophp.php<br />步骤如下：<br /> <br />首先、将该编辑器的源文件夹整个拷贝到 brophp框架在的classes目录里边，修该其中ckeditor_php5.php文件名为ckeditor.class.php<br /> <br />其次、brophp.php添加如下<br />&nbsp;&nbsp;&nbsp;&nbsp;----&gt;$GLOBALS[&quot;ckeditor_path&quot;]=$GLOBALS[&quot;root&quot;].&quot;brophp/classes/ckeditor/&quot;; //ckeditor根路径<br /> |&nbsp;&nbsp; ----&gt;自动类加载函数： 添加ckeditor类自动加载功能<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;function __autoload($className){<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; if($className==&quot;memcache&quot;){&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//如果是系统的Memcache类则不包含<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;return;<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }else if($className==&quot;Smarty&quot;){&nbsp;&nbsp;&nbsp;&nbsp;//如果类名是Smarty类，则直接包含<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;include &quot;Smarty.class.php&quot;;<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }else if($className==&quot;Ckeditor&quot;){<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;include &quot;ckeditor/&quot;.strtolower($className).&quot;.class.php&quot;;//ckeditor类包含 <br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }else{&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; //如果是其他类，将类名转为小写<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;include strtolower($className).&quot;.class.php&quot;; <br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Debug::addmsg(&quot;&lt;b&gt; $className &lt;/b&gt;类&quot;, 1);&nbsp;&nbsp;//在debug中显示自动包含的类<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}<br /> |<br />接下来修改、<br />structure.class.php-------&gt;这里边写入配置文件config.inc.php的字符串中添加如下ckeditor的默认配置项<br /> |<br /> |&nbsp;&nbsp;&nbsp;&nbsp;/*************************<br /> |&nbsp;&nbsp;&nbsp;&nbsp;*ckeditor配置项<br /> |&nbsp;&nbsp;&nbsp;&nbsp;**************************<br /> |&nbsp;&nbsp;&nbsp;&nbsp;*/<br /> |&nbsp;&nbsp;&nbsp;&nbsp;\$config= array(<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;language&#39; =&gt; &#39;zh-cn&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;skin&#39; =&gt; &#39;kama&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;width&#39; =&gt; 650, <br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;height&#39; =&gt; 300, <br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;toolbar&#39; =&gt; array(<br /> |<br /> |&nbsp;&nbsp;&nbsp;&nbsp; array(&#39;Save&#39;, &#39;Source&#39;,&#39;-&#39;,&#39;NewPage&#39;,&#39;Preview&#39;,&#39;-&#39;,&#39;Templates&#39; ),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;Cut&#39;,&#39;Copy&#39;,&#39;Paste&#39;,&#39;PasteText&#39;,&#39;PasteFromWord&#39;,&#39;-&#39;, &#39;SpellChecker&#39;, &#39;Scayt&#39; ),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;Undo&#39;,&#39;Redo&#39;,&#39;-&#39;,&#39;Find&#39;,&#39;Replace&#39;,&#39;-&#39;,&#39;SelectAll&#39;,&#39;RemoveFormat&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array(&#39;Form&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;Checkbox&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;Radio&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;TextField&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;Textarea&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;Select&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;Button&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;ImageButton&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&#39;HiddenField&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;Bold&#39;,&#39;Italic&#39;,&#39;Underline&#39;,&#39;Strike&#39;,&#39;-&#39;,&#39;Subscript&#39;,&#39;Superscript&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;NumberedList&#39;,&#39;BulletedList&#39;,&#39;-&#39;,&#39;Outdent&#39;,&#39;Indent&#39;,&#39;Blockquote&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;JustifyLeft&#39;,&#39;JustifyCenter&#39;,&#39;JustifyRight&#39;,&#39;JustifyBlock&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;Image&#39;,&#39;Flash&#39;,&#39;Table&#39;,&#39;HorizontalRule&#39;,&#39;SpecialChar&#39;,&#39;MyPage&#39;,&#39;Maximize&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;TextColor&#39;,&#39;BGColor&#39;),<br /> |&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;array(&#39;Styles&#39;,&#39;Format&#39;,&#39;Font&#39;,&#39;FontSize&#39;)<br /> |&nbsp;&nbsp;&nbsp;&nbsp; ),<br /> |&nbsp;&nbsp;&nbsp;&nbsp; <br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;uiColor&#39; =&gt; &#39;#373737&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;font_names&#39; =&gt; &#39;宋体;楷体_GB2312;新宋体;黑体;隶书;幼圆;微软雅黑;Arial;&#39;.<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;Comic Sans MS;Courier New;Tahoma;Times New Roman;Verdana;&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;font_defaultLabel&#39; =&gt; &#39;宋体&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;fontSize_defaultLabel&#39; =&gt; &#39;19px&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; &#39;extraPlugins&#39; =&gt; &#39;mypage&#39;,<br /> |&nbsp;&nbsp;&nbsp;&nbsp; );<br /> <br />最后说说、在控制器中调用方式：<br />&nbsp;&nbsp;1、不用全局配置文件config.inc.php里边的默认配置<br />&nbsp;&nbsp; $editor = new Ckeditor($GLOBALS[&quot;root&quot;].&#39;/brophp/classes/ckeditor/&#39;);<br />&nbsp;&nbsp; $config = array();<br />&nbsp;&nbsp; $config[&#39;uiColor&#39;] = &#39;#373737&#39;;<br />&nbsp;&nbsp; $config[&#39;width&#39;] = 500;<br />&nbsp;&nbsp; $config[&#39;height&#39;] = 100;<br />&nbsp;&nbsp; $config[&#39;toolbar&#39;] = array(<br />&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;Bold&#39;, &#39;Indent&#39;,&#39;Italic&#39;, &#39;Underline&#39;, &#39;Strike&#39;,&#39;Smiley&#39; ),<br />&nbsp;&nbsp;&nbsp;&nbsp;array( &#39;TextColor&#39;,&#39;Font&#39;,&#39;FontSize&#39;,&#39;RemoveFormat&#39;)<br />&nbsp;&nbsp; );<br />&nbsp;&nbsp; <br />&nbsp;&nbsp; $editor-&gt;returnOutput = true;<br />&nbsp;&nbsp; $code = $editor-&gt;editor(&quot;messsage&quot;, &quot;留言内容&quot;,$config);<br />&nbsp;&nbsp; $this-&gt;assign(&#39;ckeditor&#39;,$code);<br />&nbsp;&nbsp; <br />&nbsp;&nbsp; <br />&nbsp;&nbsp;2、//声明使用全局配置文件config.inc.php里边的配置<br />&nbsp;&nbsp; $editor = new Ckeditor($GLOBALS[&quot;ckeditor_path&quot;]);<br />&nbsp;&nbsp; global $config;//声明使用全局配置文件config.inc.php里边的配置<br />&nbsp;&nbsp; $editor-&gt;returnOutput = true;&nbsp;&nbsp;<br />&nbsp;&nbsp; $code = $editor-&gt;editor(&quot;content&quot;,&#39;&#39;,$config);<br />&nbsp;&nbsp; $this-&gt;display(&#39;editor&#39;,$code)<br />&nbsp;&nbsp; <br />&nbsp;&nbsp;----$code = $editor-&gt;editor(&quot;messsage&quot;, &quot;留言内容&quot;,$config); <br />&nbsp;&nbsp;<br />&nbsp;&nbsp; editor方法的使用,其中有三个参数：<br />&nbsp;&nbsp; 第一个是,生成的textarea框的name值,可以通过此name值,使用$_GET[]和$_POST[]取到内容<br />&nbsp;&nbsp; 第二个参数是：默认内容，就是平时写到&lt;textarea&gt;留言内容&lt;/texarea&gt;之间的内容，可为空字符串<br />&nbsp;&nbsp; 第三个参数是：富文本编辑器的菜单配置数组<br />《！---------------------------------------》<br />本来想上两张图的，不给上传。。。。。。<br /> ]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118618.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (黄加林_45)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sat, 12 May 2012 13:55:10 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[电影游戏的第二选择----《职来职往》]]></title>
 <description><![CDATA[　　头条声明：该帖绝非<span style="color:#ff0000 ">广告</span>及<span style="color:#ff0000 ">灌水</span>，及其他<span style="color:#ff0000 ">不正常</span>的帖子！！<br />&nbsp;&nbsp;&nbsp;&nbsp; <div align="center"><span id="att_21089" class="f12"><span id="td_att21089" onmouseover="postAttImgHover('menu_att21089','td_att21089');" style="display:inline-block;" class="J_attImg"><img src="http://bbs.lampbrother.net/attachment/thumb/Mon_1205/252_86163_b4c3298cc71a2e5.jpg?59" border="0" onclick=" window.open('http://bbs.lampbrother.net/attachment/Mon_1205/252_86163_b4c3298cc71a2e5.jpg?59');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ></span><div id="menu_att21089" class="fl" style="display:none;"><div class="pw_menu" style="position:absolute;z-index:1;"><div style="border:1px solid ;background:;padding:5px 10px;"><p><span class="mr10">图片:res59_attpic_brief.jpg</span></p></div></div></div></span></div><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;或许兄弟们每天都忙碌于代码，如果有周末或者其他的课余时间，考虑放松（国内外大片，games）的时候，给大家另一个选择，中国教育台的《职来职往》，这将是你们进入职场的最后一关，除了大家都会努力获得的技术水平之外，关键性的决定生死的就是面试的一关，但这却是大家超过8成的人缺乏的，而在张晓光丰富的教程同时，可以考虑下以下几个方面：<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 面试的时候什么样的着装？<br />　　将要面试的企业的企业文化？<br />　　你应该以什么状态去见HR？<br />　　应该如何根据自己的个性来形成一套自己的介绍流程？<br />　　怎么让HR发现你的亮点，你与同样来面试的人的不同之处？<br />　　你为什么会给公司带来的利益远大于企业给你的工资？<br />　　… …　　<div align="center"><span id="att_21088" class="f12"><span id="td_att21088" onmouseover="postAttImgHover('menu_att21088','td_att21088');" style="display:inline-block;" class="J_attImg"><img src="http://bbs.lampbrother.net/attachment/Mon_1205/252_86163_aa1347441e50489.jpg?63" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://bbs.lampbrother.net/attachment/Mon_1205/252_86163_aa1347441e50489.jpg?63');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ></span><div id="menu_att21088" class="fl" style="display:none;"><div class="pw_menu" style="position:absolute;z-index:1;"><div style="border:1px solid ;background:;padding:5px 10px;"><p><span class="mr10">图片:res59_attpic_brief.jpg</span></p></div></div></div></span></div><br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; 其实有工作经验的和没有工作经验的人都是一样的人，只是前者对现在的企业更了解，更明白在你焦急求职的同时，企业也是在求贤若渴的，如果你真的是能给你的企业创造价值，如果能，那就要把自己的优势都展示给面试的HR！<br />&nbsp;&nbsp;&nbsp;&nbsp; 还有很多的兄弟们都不知道自己的价值在什么地方，那也没什么，把自己认为长处的尽量说出来，或许对方说不定就是你的点金石呢，当然没有前一种主动，不过都是应届生必经的阶段，这个节目里有很多的毕业生，很多的失败，很多的成功，虽然是电视的媒介，但他们面试的问题丝毫不含糊，都是该批则批，只是在咱们面试的时候会说“稍后联系”，如果特看中你的话，就会进一步细谈～～<br />&nbsp;&nbsp;&nbsp;&nbsp; 例如：有一个女生在大学当过一段的学生会干部，算是大学里面的优秀分子，处处透露出骄傲的肢体和语言，但对于招聘人员来说普遍都比较反感，至于为什么估计要去问企业吧～～<div align="center"><span id="att_21090" class="f12"><span id="td_att21090" onmouseover="postAttImgHover('menu_att21090','td_att21090');" style="display:inline-block;" class="J_attImg"><img src="http://bbs.lampbrother.net/attachment/thumb/Mon_1205/252_86163_d713e8e47668a58.jpg?415" border="0" onclick=" window.open('http://bbs.lampbrother.net/attachment/Mon_1205/252_86163_d713e8e47668a58.jpg?415');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ></span><div id="menu_att21090" class="fl" style="display:none;"><div class="pw_menu" style="position:absolute;z-index:1;"><div style="border:1px solid ;background:;padding:5px 10px;"><p><span class="mr10">图片:res59_attpic_brief.jpg</span></p></div></div></div></span></div><br />&nbsp;&nbsp;&nbsp;&nbsp;曾经听光哥（张晓光）说过的：大家在毕业面试的时候，技术都不会差的太大，那层次从哪里出来，就是企业需要的是一个员工，一个有思想有意识，而且都在为老板为上级省心的员工，如果仅仅是代码，那等到有朝一日php代码可以机械化，那公司还留着你有什么用处呢？当然每个人在每个公司之所以能得以重任都是因为他有着只有人，只有有着特定思想的人，不管php代码进化到什么样子，你在代码过关的情况下（兄弟连的基本都没问题）公司需要你～～<div align="center"> </div><br />&nbsp;&nbsp;&nbsp;&nbsp; 里面有很多咱们的同龄人，他们找工作找的很顺利，也有找的很坎坷，不过不管什么样的道路都不要抱怨，因为生活就是这样，没有哭哪有甜，如果一生中连点波澜都没有，那一辈子过的太无味了，始终抱着一颗自信、坚持的心去，要知道你在社会中总会有一个定位的，年轻就是用来奋斗的，到了不惑之年就没有心思去顾着事业了～～<br />&nbsp;&nbsp;&nbsp;&nbsp;如果没有网络想看面试视频《职来职往》的朋友可以去我那拷贝，选择去电影世界和游戏天地的这里就没有资源了.......<br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118609.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (康鹏_43)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sat, 12 May 2012 10:21:16 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[你们的福利。昨天下午做了个瀑布流，有腿哦]]></title>
 <description><![CDATA[<a href="http://stuooo.sinaapp.com/" target="_blank" >http://stuooo.sinaapp.com/</a><br /> <br />最近瀑布流很火，昨天下午也做了一个。<br /> <br />他们说要看大腿，所以...........你懂得<br /> <br />随意变换窗口大小，无限下拉，永无止境，欢迎爆服务器。<br /> <br />要代码的密我&nbsp;&nbsp;&nbsp;&nbsp;<a href="mailto:jay.zhong@ismole.com ">jay.zhong@ismole.com</a><br /> <br /> <span id="att_21100">(附件)</span><br /> <br /> <br /> <br /> <br /> <br /><div style="margin-top: 10px;"><span style="background: none repeat scroll 0 0 #F3F9FB;border: 1px solid #A6CBE7;padding: 3px 10px;">本帖包含的部分附件只能  <a style="color: #014C90;" href="http://bbs.lampbrother.net/read-htm-tid-118605.html" target="_blank">访问</a> 社区查看</span></div>]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118605.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (钟键_35)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Sat, 12 May 2012 02:36:13 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[【转】醒醒吧，雄起吧！最可爱的人！]]></title>
 <description><![CDATA[<span style="color:#454545 ">我们的php真的已经学好了么？</span><br /><span style="color:#454545 "><br /></span><br /><span style="color:#454545 ">1、首先看了PHP的源码API函数，对于许多口水仗的争论一笑而过，只是停留在脚本级别上的什么效率，安全……之争完全就是无稽之谈，没有深入理解API，所有的争论都是臆测和不科学的态度。你做了吗？</span><br /><span style="color:#454545 ">2、不再把PHP看作一门后台语言，而是一门类似JS的脚本，页面表现级的语言，更多的是尝试使用一种软件来做后台，PHP做前台，尝试真正的B/S开发。你的看法呢？</span><br /><span style="color:#454545 ">3、知识更新。PHP中的接口你懂了吗？反射你听过吗？JS中的事件冒泡你懂了吗？原型链知道吗？一切函数都是对象，你能理解否？MYSQL里面的视图，存储过程你尝试过么有？</span><br /><span style="color:#454545 ">4、扎实的学知识。你是不是离开了JQ框架就连个DOM操作的原生JS都不会写了？你是不是离开了DB类，就连个简单的查询都不会写了？你是不是离开了IDE，连个表格都画不出来？你是不是到现在多表查询，子查询都还不会？你是不是到现在就只知道索引是用来加快查询的？<br />你是不是到现在连个PHP5的稍微复杂点的OO类都还不会写？你会正则吗？你的E文水平咋样？</span><br /><span style="color:#454545 ">5、扎实的算法基础。你知道选择排序，插入排序，冒泡排序，二分排序，希尔排序并且能写出来吗？你知道怎么遍历二叉树吗？知道霍夫曼吗？你知道图吗？你知道龙格-库塔，迭代，插值，雅戈尔，牛顿下山法吗？知道ZIP压缩原理吗？你是不是可爱到以为加减乘除加上循环判断就搞定了算法？你知道概率论，微积分，线性方程组在算法中是非常非常基础的吗？</span><br /><span style="color:#454545 ">6、学习的主动性。你是不是自己的网站连个拿的出手的JS都没有写过？你网站的效果是不是都是你下载的JQ插件弄出来的？到现在都还没有看过JQ的代码？你现在的模板引擎是谁的？DB类是谁的？框架是谁的？你是不是一直都很鄙视重复造轮子的事情，就像中国现在，“拿来主义”，永远是MADE IN CHINA，而不是Created in China？</span><br /><span style="color:#454545 ">7、广泛的基础。你会汇编吗？那C总该会点吧。。那C++呢，那简单的JAVA总该会吧。。。那。。那傻瓜化的VB，NET，PY……？什么，你只会PHP？其他啥都不会？JS总该会吧？啊，不会，只会用网上下来的JQ？你除了PHP还会点啥？那假如PHP垮台了或者你所在的公司不用PHP了你吃什么？如果老板让你学J2SE你怕不怕？</span><br /><span style="color:#454545 ">8、你是不是就准备一辈子做个coder?你的知识如果让你传授给别人的话，能支撑三个月吗？三个月后你还能讲得出点其他的东西吗？</span><br /><span style="color:#454545 ">9、你现在的水平和你刚开始学的时候进步了多少？你有过自己的作品吗？有多少代码是你自己写的？你认为是不是只要会写PHP代码就够了？这样的话一个初中生三个月后也就能达到你的水平了，你认为呢？你准备一直停留在这个水平吗？</span><br /><span style="color:#454545 ">10、最后一问，你除了会写仅会的PHP代码，还会点其他的吗？你有把握做其他工作吗？你能养活自己老婆孩子吗？能给他们幸福吗？</span><br /><span style="color:#454545 "><br /></span><br /><span style="background-color:#ffffff "><span style="color:#454545 "><font face="Microsoft Yahei ">问我自己，也问所有PHPer。仅供参考。</font></span></span><br /><span style="color:#454545 "><br /></span><br /> <br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118600.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (张少杰_45)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Fri, 11 May 2012 13:47:57 +0000]]></pubDate>
</item>
<item>
 <title><![CDATA[LAMP兄弟连第一届篮球赛-教师联队内斗！【海量图片】]]></title>
 <description><![CDATA[&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;篮球赛前前后后打了10天左右了，终于轮到备受期待的教师联队内斗了，本次比赛由 一号教学楼教师联队&nbsp;&nbsp;VS&nbsp;&nbsp;二号教学楼教师联队 ，学员来了不少，场下气氛很好，场上气氛很搞。说实话在场的学员观众都说压根没把这当比赛，后来比赛一开始我也才感觉到，这根本就是一场彻头彻尾的喜剧电影，好奇的朋友可以看看全场比赛的录像，可以打开声音听一听摄像师的笑声，就知道比赛的滑稽程度了，当然如果你是兄弟连学员，更会看懂其中的很多幽默。<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;2012.05.08下午六点比赛准时开始，视频录播之前，先上双方首发队员靓照。<br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/07/56284936201205110712091724131041331_033.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/07/56284936201205110712091724131041331_033.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/07/56284936201205110712091724131041331_032.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/07/56284936201205110712091724131041331_032.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><font size="6"><b>YY了一些球场趣事</b></font><br /> <br /><b><font size="5">文凯篇</font></b><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/11/56284936201205111144533145132275128_001.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/11/56284936201205111144533145132275128_001.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/11/56284936201205111144533145132275128_002.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/11/56284936201205111144533145132275128_002.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/11/56284936201205111144533145132275128_000.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/11/56284936201205111144533145132275128_000.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /> <br /><font size="5"><b>晓光篇</b></font><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_004.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_004.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_003.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_003.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_002.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_002.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_001.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_001.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_000.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111159493354482894920_000.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><font size="5"><b>李明篇</b></font><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111252593155474276429_003.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111252593155474276429_003.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111252593155474276429_002.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111252593155474276429_002.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111252593155474276429_000.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111252593155474276429_000.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><font size="5"><b>李超篇</b></font><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_005.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_005.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_004.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_004.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_000.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_000.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_001.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_001.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_003.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_003.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_002.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/12/56284936201205111255471202672400143_002.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><font size="5"><b>高洛峰篇</b></font><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_002.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_002.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_003.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_003.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_000.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_000.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><img src="http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_001.jpg" border="0" onclick="if(this.parentNode.tagName!='A'&&this.width>=700) window.open('http://img170.poco.cn/mypoco/myphoto/20120511/13/56284936201205111345102077961484588_001.jpg');" style="max-width:700px;max-height:700px;" onload="if(is_ie6&&this.offsetWidth>700)this.width=700;" ><br /> <br /><font size="5">一楼更新比赛精彩瞬间</font><br /><font size="5">某楼更新人物篇</font><br />]]></description>
 <link><![CDATA[http://bbs.lampbrother.net/read-htm-tid-118573.html]]></link>
 <author><![CDATA[haifeng@lampbrother.net (张沫)]]></author>
 <category><![CDATA[战地日记]]></category>
 <pubDate><![CDATA[Fri, 11 May 2012 05:54:46 +0000]]></pubDate>
</item>
</channel></rss>
