<?xml version="1.0" encoding="UTF-8" ?><rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/"><channel><title>大超博客</title><link>http://www.niuchao.com/</link><language>zh-CN</language><webMaster>error@niuchao.com</webMaster><pubDate>Tue, 11 Mar 2008 15:47:50 GMT</pubDate><copyright>Copyright 2007. All rights reserved.</copyright><generator>属于自己和家人的一片宁静~</generator><image><title>大超博客</title><url>http://www.niuchao.com/Images/banner.gif</url><link>http://www.niuchao.com/</link></image><item><link>http://www.niuchao.com/Article/17.aspx</link><title><![CDATA[I must do it. I can do it. I will do it. I will succeed........]]></title><author></author><category>工作笔记</category><pubDate>Tue, 29 Apr 2008 08:40:23 GMT</pubDate><description><![CDATA[As you slowly open your eyes, look around, notice where the light comes into your room, listen carefully, see if there're any new sounds you can recognize, fill with your body inspiring-- see if you can sense the freshness in the air.当你慢慢睁开眼睛，环顾四周，看到阳光照进屋子，仔细聆听，看看有没有新的声音，鼓舞着你的全身——看看你是否能感受到空气中的新鲜Yes!]]></description><content:encoded><![CDATA[<p>As you slowly open your eyes, look around, notice where the light comes into your room, listen carefully, see if there're any new sounds you can recognize, fill with your body inspiring-- see if you can sense the freshness in the air.</p><p>当你慢慢睁开眼睛，环顾四周，看到阳光照进屋子，仔细聆听，看看有没有新的声音，鼓舞着你的全身——看看你是否能感受到空气中的新鲜</p><p><br />Yes! Yes! Yes! It's a new day! It's a different day! And it's a bright day! And most importantly, it's a new beginning for your life, a beginning when you are going to make new decisions, take new actions, make new friends, and take your life a totally unprecedented lever.</p><p>是的！是的！是的！这是新的一天！这是不同的一天！这是明亮的一天！最重要的是，这是你生命中崭新的开始，是你做出新的决定的开始，开始新的行动，结交新的朋友，并且把你的生涯带到一个前所未有的高度</p><p><br />In your minds that-- you can see clearly the things you wanna have, the places you intended to go, the relationships you desire to develop, and the positions you aspired to reach. You can hear your laughters with joy and happiness on the day when everything happens as you dream. You can see the smiles on the people around you when the magic moments strikes. You can feel your face is getting red and your heart is beating fast and your blood is rushing all over your body to every single corner of your being.</p><p>在你的内心中——你能清晰的看到你想拥有的东西，你想要去的地方，你想发展的人脉关系，你渴望达到的地位。当你的梦想全部实现的那一天，你会听到你喜悦和幸福的笑声，当奇妙的时刻到来时，你会看到大家微笑着围绕着你，你会感觉到你的脸庞正在变红、心跳加速、血液涌向你身体的每个角落。</p><p><br />You know all this is real as long as you are confident, passionate and <font size="2">committed!</font>-- , and you are confident, you are passionate, you are <font size="2">committed</font>--. You will no longer fear making new sounds, showing new facial expressions, using your body in new ways, approaching new people, and asking new questions. You will live every single day of your life with absolute passion. You will show your passion through the words you speak and the actions you take. You will focus all your time and effort on the most important goals of your life. You will never succumb to challenges of hardships.You will never waiver in your pursuit of excellence.</p><p>你知道只要你有信心、热情、决心，这一切都是真实的。你有信心，你有热情，你有决心，你将不在害怕做出新的声音，显露新的表情，用新的方式接近新的人，请教新的问题。你将在绝对的激情中度过每一天。你将会通过你的谈吐和行动表现出你的激情。你会在你最重要的人生目标上集中你所有的时间和努力。你将不再屈服挑战困难，你绝不会放弃追求卓越</p><p><br />After all, you are the best, and you deserve the best. As your coaching friend, I can assure you the door to all the best things in the world will open to you, but the key to the door is in your hand. You must do your part. You must faithfully follow the plans you make and take the actions you plan. You must never quit. You must never fail. I know you must do it. You can do it. You will do it. And you will succeed. Now stand firm and tall, make a fist, get excited, and yell it out. I must do it. I can do it. I will do it. I will succeed........</p><p>总之，你是最好的，你该是最好的，作为你的教练朋友，我能向你保证，通过世界上最美好的事情的大门将会向你敞开，但是大门的钥匙掌握在你的手中，你必须做你应该做的，你必须遵循你制定的计划以及你计划开始的行动，你决不能退出，你决不能失败，我知道你必须这样做，你能做到，你将做到，你将成功，现在立场坚定，握住拳头，充满激情的喊出来</p>]]></content:encoded><guid>http://www.niuchao.com/Article/17.aspx</guid><trackback:ping>http://www.niuchao.com/Article/17/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/17.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/17/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/16.aspx</link><title><![CDATA[奥运倒计时js代码]]></title><author></author><category>学习笔记</category><pubDate>Mon, 28 Apr 2008 16:56:32 GMT</pubDate><description><![CDATA[&amp;lt;FONT color=#00cc00&amp;gt;&amp;lt;FONT color=#000000&amp;gt;奥运倒计时:&amp;lt;/FONT&amp;gt;&amp;lt;/B&amp;gt;&amp;lt;/FONT&amp;gt; &amp;lt;SPAN id=span_dt_dt style=&amp;quot;align: center no:1px solid black&amp;quot;&amp;gt;&amp;lt;/SPAN&amp;gt; &amp;lt;SCRIPT language=javascript&amp;gt;   &amp;lt;!--   //document.write(&amp;quot;&amp;quot;);   function show_date_time(){   wind]]></description><content:encoded><![CDATA[<pre><ol class="dp-xml"><li class="alt"><span><span class="tag">&lt;</span><span class="tag-name">FONT</span><span>&nbsp;</span><span class="attribute">color</span><span>=#00cc00</span><span class="tag">&gt;</span><span class="tag">&lt;</span><span class="tag-name">FONT</span><span>&nbsp;</span><span class="attribute">color</span><span>=#000000</span><span class="tag">&gt;</span><span>奥运倒计时:</span><span class="tag">&lt;/</span><span class="tag-name">FONT</span><span class="tag">&gt;</span><span class="tag">&lt;/</span><span class="tag-name">B</span><span class="tag">&gt;</span><span class="tag">&lt;/</span><span class="tag-name">FONT</span><span class="tag">&gt;</span><span>&nbsp;</span><span class="tag">&lt;</span><span class="tag-name">SPAN</span><span>&nbsp;</span><span class="attribute">id</span><span>=</span><span class="attribute-value">span_dt_dt</span><span>&nbsp;</span><span class="attribute">style</span><span>=</span><span class="attribute-value">&quot;align:&nbsp;center&nbsp;no:1px&nbsp;solid&nbsp;black&quot;</span><span class="tag">&gt;</span><span class="tag">&lt;/</span><span class="tag-name">SPAN</span><span class="tag">&gt;</span><span>&nbsp;</span></span></li><li><span class="tag">&lt;</span><span class="tag-name">SCRIPT</span><span>&nbsp;</span><span class="attribute">language</span><span>=</span><span class="attribute-value">javascript</span><span class="tag">&gt;</span><span>&nbsp; &nbsp;</span></li><li class="alt"><span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;!--&nbsp; &nbsp;</span></li><li><span>//document.write(&quot;&quot;);&nbsp; &nbsp;</span></li><li class="alt"><span>function&nbsp;show_date_time(){&nbsp; &nbsp;</span></li><li><span>window.setTimeout(&quot;show_date_time()&quot;,&nbsp;1000);&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">BirthDay</span><span>=</span><span class="attribute-value">new</span><span>&nbsp;Date(&quot;8/08/2008&nbsp;20:00:00&quot;);//这个日期是可以修改的&nbsp; &nbsp;</span></li><li><span class="attribute">today</span><span>=</span><span class="attribute-value">new</span><span>&nbsp;Date();&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">timeold</span><span>=(BirthDay.getTime()-today.getTime());&nbsp; &nbsp;</span></li><li><span class="attribute">sectimeold</span><span>=timeold/1000&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">secondsold</span><span>=</span><span class="attribute-value">Math</span><span>.floor(sectimeold);&nbsp; &nbsp;</span></li><li><span class="attribute">msPerDay</span><span>=</span><span class="attribute-value">24</span><span>*60*60*1000&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">e_daysold</span><span>=</span><span class="attribute-value">timeold</span><span>/msPerDay&nbsp; &nbsp;</span></li><li><span class="attribute">daysold</span><span>=</span><span class="attribute-value">Math</span><span>.floor(e_daysold);&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">e_hrsold</span><span>=(e_daysold-daysold)*24;&nbsp; &nbsp;</span></li><li><span class="attribute">hrsold</span><span>=</span><span class="attribute-value">Math</span><span>.floor(e_hrsold);&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">e_minsold</span><span>=(e_hrsold-hrsold)*60;&nbsp; &nbsp;</span></li><li><span class="attribute">minsold</span><span>=</span><span class="attribute-value">Math</span><span>.floor((e_hrsold-hrsold)*60);&nbsp; &nbsp;</span></li><li class="alt"><span class="attribute">seconds</span><span>=</span><span class="attribute-value">Math</span><span>.floor((e_minsold-minsold)*60);&nbsp; &nbsp;</span></li><li><span class="attribute">span_dt_dt.innerHTML</span><span>=</span><span class="attribute-value">&quot;&lt;b&gt;&lt;align=center&gt;&lt;font&nbsp;color=ff0000&gt;&quot;</span><span>+daysold+&quot;天&quot;+hrsold+&quot;小时&quot;+minsold+&quot;分&quot;+seconds+&quot;秒&quot;+&quot;</span><span class="tag">&lt;/</span><span class="tag-name">b</span><span class="tag">&gt;</span><span class="tag">&lt;</span><span class="tag-name">br</span><span class="tag">&gt;</span><span class="tag">&lt;/</span><span class="tag-name">font</span><span class="tag">&gt;</span><span>&quot;&nbsp;;&nbsp; &nbsp;</span></li><li class="alt"><span>}&nbsp; &nbsp;</span></li><li><span>show_date_time();&nbsp; &nbsp;</span></li><li class="alt"><span>//--</span><span class="tag">&gt;</span><span>&nbsp; &nbsp;</span></li><li><span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span><span class="tag">&lt;/</span><span class="tag-name">SCRIPT</span><span class="tag">&gt;</span><span>&nbsp;</span></li></ol></pre>]]></content:encoded><guid>http://www.niuchao.com/Article/16.aspx</guid><trackback:ping>http://www.niuchao.com/Article/16/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/16.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/16/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/15.aspx</link><title><![CDATA[转换16进制]]></title><author></author><category>学习笔记</category><pubDate>Thu, 24 Apr 2008 13:06:52 GMT</pubDate><description><![CDATA[&amp;lt;%Public Function URLEncoding(v,f)  Dim s,t,i,j,h,l,x : s = &amp;quot;&amp;quot; : x=Len(v)  For i = 1 To x  t = Mid(v,i,1) : j = Asc(t)  If (j&amp;gt;=48 And j&amp;lt;=57) Or (j&amp;gt;=65 And j&amp;lt;=90) Or (j&amp;gt;=97 And j&amp;lt;=122) Then If f Then s = s &amp;amp; &amp;quot;%&amp;quot; &amp;amp; Right(&amp;quot;00&amp;quot; &amp;amp; Hex(j),2)  ]]></description><content:encoded><![CDATA[<pre><ol class="dp-vb"><li class="alt"><span><span>&lt;%</span><span class="keyword">Public</span><span>&nbsp;</span><span class="keyword">Function</span><span>&nbsp;URLEncoding(v,f) &nbsp;</span></span></li><li><span class="keyword">Dim</span><span>&nbsp;s,t,i,j,h,l,x&nbsp;:&nbsp;s&nbsp;=&nbsp;</span><span class="string">&quot;&quot;</span><span>&nbsp;:&nbsp;x=Len(v) &nbsp;</span></li><li class="alt"><span class="keyword">For</span><span>&nbsp;i&nbsp;=&nbsp;1&nbsp;</span><span class="keyword">To</span><span>&nbsp;x &nbsp;</span></li><li><span>t&nbsp;=&nbsp;Mid(v,i,1)&nbsp;:&nbsp;j&nbsp;=&nbsp;Asc(t) &nbsp;</span></li><li class="alt"><span class="keyword">If</span><span>&nbsp;(j&gt;=48&nbsp;</span><span class="keyword">And</span><span>&nbsp;j&lt;=57)&nbsp;</span><span class="keyword">Or</span><span>&nbsp;(j&gt;=65&nbsp;</span><span class="keyword">And</span><span>&nbsp;j&lt;=90)&nbsp;</span><span class="keyword">Or</span><span>&nbsp;(j&gt;=97&nbsp;</span><span class="keyword">And</span><span>&nbsp;j&lt;=122)&nbsp;</span><span class="keyword">Then</span><span>&nbsp;</span></li><li><span class="keyword">If</span><span>&nbsp;f&nbsp;</span><span class="keyword">Then</span><span>&nbsp;</span></li><li class="alt"><span>s&nbsp;=&nbsp;s&nbsp;&amp;&nbsp;</span><span class="string">&quot;%&quot;</span><span>&nbsp;&amp;&nbsp;Right(</span><span class="string">&quot;00&quot;</span><span>&nbsp;&amp;&nbsp;Hex(j),2) &nbsp;</span></li><li><span class="keyword">Else</span><span>&nbsp;</span></li><li class="alt"><span>s&nbsp;=&nbsp;s&nbsp;&amp;&nbsp;t &nbsp;</span></li><li><span class="keyword">End</span><span>&nbsp;</span><span class="keyword">If</span><span>&nbsp;</span></li><li class="alt"><span class="keyword">ElseIf</span><span>&nbsp;j&lt;0&nbsp;</span><span class="keyword">Then</span><span>&nbsp;</span></li><li><span>j&nbsp;=&nbsp;j&nbsp;+&nbsp;&amp;H10000 &nbsp;</span></li><li class="alt"><span>h&nbsp;=&nbsp;(j&nbsp;</span><span class="keyword">And</span><span>&nbsp;&amp;HFF00)&nbsp;\&nbsp;&amp;HFF &nbsp;</span></li><li><span>l&nbsp;=&nbsp;j&nbsp;</span><span class="keyword">And</span><span>&nbsp;&amp;HFF &nbsp;</span></li><li class="alt"><span>s&nbsp;=&nbsp;s&nbsp;&amp;&nbsp;</span><span class="string">&quot;%&quot;</span><span>&nbsp;&amp;&nbsp;Right(</span><span class="string">&quot;00&quot;</span><span>&nbsp;&amp;&nbsp;Hex(h),2)&nbsp;&amp;&nbsp;</span><span class="string">&quot;%&quot;</span><span>&nbsp;&amp;&nbsp;Right(</span><span class="string">&quot;00&quot;</span><span>&nbsp;&amp;&nbsp;Hex(l),2) &nbsp;</span></li><li><span class="keyword">Else</span><span>&nbsp;</span></li><li class="alt"><span>s&nbsp;=&nbsp;s&nbsp;&amp;&nbsp;</span><span class="string">&quot;%&quot;</span><span>&nbsp;&amp;&nbsp;Right(</span><span class="string">&quot;00&quot;</span><span>&nbsp;&amp;&nbsp;Hex(j),2) &nbsp;</span></li><li><span class="keyword">End</span><span>&nbsp;</span><span class="keyword">If</span><span>&nbsp;</span></li><li class="alt"><span class="keyword">Next</span><span>&nbsp;</span></li><li><span>URLEncoding&nbsp;=&nbsp;s &nbsp;</span></li><li class="alt"><span class="keyword">End</span><span>&nbsp;</span><span class="keyword">Function</span><span>&nbsp;</span></li><li><span>response.write&nbsp;URLEncoding(</span><span class="string">&quot;hezu123.com&quot;</span><span>,1) &nbsp;</span></li><li class="alt"><span>%&gt;&nbsp;</span></li></ol></pre>]]></content:encoded><guid>http://www.niuchao.com/Article/15.aspx</guid><trackback:ping>http://www.niuchao.com/Article/15/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/15.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/15/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/14.aspx</link><title><![CDATA[李嘉诚的“人生第一课”]]></title><author></author><category>超之声波</category><pubDate>Thu, 10 Apr 2008 09:13:43 GMT</pubDate><description><![CDATA[李嘉诚是亿万人的偶像。那么，李嘉诚心中的偶像又是谁呢？他的答案是：父亲李云经。李嘉诚说：“我爸爸是非常典型的中国人，有气节，讲义气，且诚恳待人。”1943年，李云经因长期劳累、贫穷、忧愤，终于病倒了。李云经患的是肺病。肺病在当时是一种“不治之症”，染上这种病，等于被判了死刑。他预感到自己不久于人世，把一切希望都寄托于儿子身上。为了维持儿子的学费，他坚持不住院；医生开了药方，他也不去药店买药。李嘉诚的舅舅庄静庵知道这个情况后，“强行”送他住院。李云经住进医院后仍偷偷把药钱省下来，准备给独生子交学费。李嘉诚每每回忆起这段往事，都泪水潸然。父亲病逝以后，小嘉诚和母亲东拼西借，总算凑足了一笔为父亲买块]]></description><content:encoded><![CDATA[<p><font size="3"></font></p><p><span style="font-family: 宋体">李嘉诚是亿万人的偶像。那么，李嘉诚心中的偶像又是谁呢？</span></p><p><span style="font-family: 宋体">他的答案是：父亲李云经。</span></p><p><span style="font-family: 宋体">李嘉诚说：</span><span><font>“</font></span><span style="font-family: 宋体">我爸爸是非常典型的中国人，有气节，讲义气，且诚恳待人。</span><span><font>”</font></span></p><p><span><font>1943</font></span><span style="font-family: 宋体">年，李云经因长期劳累、贫穷、忧愤，终于病倒了。李云经患的是肺病。肺病在当时是一种</span><span><font>“</font></span><span style="font-family: 宋体">不治之症</span><span><font>”</font></span><span style="font-family: 宋体">，染上这种病，等于被判了死刑。他预感到自己不久于人世，把一切希望都寄托于儿子身上。为了维持儿子的学费，他坚持不住院；医生开了药方，他也不去药店买药。李嘉诚的舅舅庄静庵知道这个情况后，</span><span><font>“</font></span><span style="font-family: 宋体">强行</span><span><font>”</font></span><span style="font-family: 宋体">送他住院。李云经住进医院后仍偷偷把药钱省下来，准备给独生子交学费。李嘉诚每每回忆起这段往事，都泪水潸然。</span></p><p><span style="font-family: 宋体">父亲病逝以后，小嘉诚和母亲东拼西借，总算凑足了一笔为父亲买块葬身之地的钱。</span></p><p><span style="font-family: 宋体">按照当时的规矩，买坟地的人必须先付钱，才可以看地。卖地给李家的是两个客家兄弟。他们向小嘉诚吹嘘，说这块风水宝地如何如何好，先人葬在这里，后人必可发达。</span></p><p><span style="font-family: 宋体">小嘉诚希望发达，但不相信自己这么一点钱，能买到风水宝地。他想，只要父亲有个安息之地，他和母亲也就安心了。他将钱交给卖地人之后，便跟着他们看地去。这天，恰巧寒流南下，气温骤降，加上阴雨绵绵，山路泥泞，衣着单薄的小嘉诚冻得瑟瑟发抖。</span></p><p><span style="font-family: 宋体">两个客家人见他是小孩，存心欺骗他。他们走得很快，企图摆脱李嘉诚。但小嘉诚却寸步不离，紧紧地跟着他们。</span></p><p><span style="font-family: 宋体">走到一座山坳上的荒坟时，走在前面的弟弟用客家话对哥哥说：</span><span><font>“</font></span><span style="font-family: 宋体">阿哥，就这里吧！</span><span><font>”</font></span></p><p><span style="font-family: 宋体">被称为</span><span><font>“</font></span><span style="font-family: 宋体">阿哥</span><span><font>”</font></span><span style="font-family: 宋体">的男子说：</span><span><font>“</font></span><span style="font-family: 宋体">这里？你没看见这里已有一座坟了吗？</span><span><font>”<br />“</font></span><span style="font-family: 宋体">不要紧，掘开它，把尸骨弄走就是了。一个小孩子，量他不敢不收货。</span><span><font>”</font></span></p><p><span style="font-family: 宋体">他们的对话，被略懂客家话的李嘉诚全听到了。小嘉诚想，世界上居然有这样黑心的人，为了这么一点钱，连死人也不肯放过。他想到父亲一生光明磊落，鹊巢鸠占的事，父亲是绝对不会做的，即使将他安葬在此，九泉之下，他也是不会安息的。</span></p><p><span style="font-family: 宋体">小嘉诚分析，这两个人如此黑心，要将钱退回，是绝对不可能的了，若同他们纠缠，遭他们毒手倒是有可能的。</span></p><p><span style="font-family: 宋体">所以，当那兄弟俩挥锄要挖坟时，李嘉诚说：</span><span><font>“</font></span><span style="font-family: 宋体">不要挖了，你们的话我全听到了。算了吧，那笔钱只当我施舍给你们罢了！我另找卖主。</span><span><font>”</font></span><span style="font-family: 宋体">说完，头也不回地奔下山去。</span></p><p><span style="font-family: 宋体">这次买地葬父的周折，给李嘉诚上了人生第一课，他告诫自己，不论将来日子如何艰难，一定不可以坑害别人。凭着这样的人生信条，李嘉诚终于成了现在的亚洲首富。</span></p>]]></content:encoded><guid>http://www.niuchao.com/Article/14.aspx</guid><trackback:ping>http://www.niuchao.com/Article/14/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/14.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/14/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/13.aspx</link><title><![CDATA[牛根生哈佛演讲有感（转）]]></title><author></author><category>学习笔记</category><pubDate>Tue, 08 Apr 2008 08:32:17 GMT</pubDate><description><![CDATA[序：2008年3月9日，我受邀在哈佛大学就企业社会责任发表演讲。据有关媒体的同志讲，我是“中国历史上第一个受邀在国际上讲企业社会责任的企业家”。缘何？原因大概有三：第一，中国有企业（现代意义的企业）的历史太短；第二，中国讲企业社会责任的历史也不长；第三，国际舞台上某一领域话语权的让渡标志着该国在这一领域的崛起——中国企业社会责任开始在国际舞台上崛起了！ 在哈佛演讲后，我有五个方面的感想。 第一个感想：“财富权”往往决定“话语权”。 马克思曾说，资本主义在它不到100年的时间里所创造的生产力，比过去所有时代所创造的生产力总和还要多还要大。看了这句话，由不得要问：中国生产力创造的黄金时代是落在哪个]]></description><content:encoded><![CDATA[<p style="font-family: 楷体_GB2312">序：2008年3月9日，我受邀在哈佛大学就企业社会责任发表演讲。据有关媒体的同志讲，我是“中国历史上第一个受邀在国际上讲企业社会责任的企业家”。缘何？原因大概有三：第一，中国有企业（现代意义的企业）的历史太短；第二，中国讲企业社会责任的历史也不长；第三，国际舞台上某一领域话语权的让渡标志着该国在这一领域的崛起——中国企业社会责任开始在国际舞台上崛起了！</p><p>&nbsp;在哈佛演讲后，我有五个方面的感想。</p><p><b>&nbsp;第一个感想：“财富权”往往决定“话语权”。</b></p><p>&nbsp;马克思曾说，资本主义在它不到100年的时间里所创造的生产力，比过去所有时代所创造的生产力总和还要多还要大。</p><p>看了这句话，由不得要问：中国生产力创造的黄金时代是落在哪个区间了呢？它与我们的国际话语权究竟是一种什么关系？</p><p>国际上的发言权，在某种程度上是取决于财富、取决于生产力水平的。人类历史再往前推516年，在“西半球不知道东半球，东半球不知道西半球”的那个漫长时代，古中国曾经拥有过世界上最强大的物质财富与精神财富，但由于时代所限，祖先们没怎么在国际上发出过声音。</p><p>接下来的“屈辱近代史”大家都了解了，列强瓜分中国，“八国联军”所在的每一国，都用中国人的血汗钱垫高了自己的“脚跟”——最早的掠夺者大英帝国自不必说，法、德、俄、意、美也不必说，就连此前追随中国几千年的日本小兄弟也“回刀屠师”，用大清帝国的巨额赔款充实了百年维新的底子。</p><p>从这个意义上追本溯源，我们甚至可以说：发达国家的“长城”是用发展中国家的“砖头”砌成的！（再说得委婉一点：发达国家的“长城”中有我们发展中国家的“砖头”。）</p><p>那时，被人一只脚踩住左肩、另一只脚踩住右肩的殖民地、半殖民地国家，只能切肤痛感一个真理：“落后就要挨打！”“弱国无外交！”（无话语权）</p><p>新中国改革开放30年，是财富创造最快的时期。套用马克思的句式，我们可以说：中国在最近30年所创造的生产力，比它过去300年所创造的生产力总和还要多还要大——这，正是我们今天获得话语权的源泉所在。</p><p>把生产力搞上去，是我们赢得国际“话权语”最为根本的路径！</p><p><b>第二个感想：远离战争，也要拒绝“斗争”。</b></p><p>&nbsp;美国的崛起，与一战、二战都未在其本土上“腥风血雨”是有关联的。</p><p>&nbsp;哈佛大学的传奇，从源头上讲，也可以说是哈佛先生所捐财富催生出的灿烂奇葩。据介绍，哈佛大学的毕业生中，共有六位曾当选过美国总统，他们是约翰·亚当斯(美国第二任总统)、约翰·昆西·亚当斯、拉瑟福德·海斯、西奥多·罗斯福、富兰克林·罗斯福(连任四届)和约翰·肯尼迪；哈佛大学的教授团中，总共产生了34名诺贝尔奖得主。物质决定意识，意识反作用于物质——经济与文化就是这样循环渐进的。</p><p>&nbsp;不管是被迫，还是主动，当我们“与别人较劲”的时候，收获的是“零和游戏”；当我们“与自己较劲”的时候，你赢我赢，没有输家。</p><p>&nbsp;20世纪的中国，我把前半叶看作“负数”，后半叶看作“正数”。为啥？战争，人死物伤，减法；和平，国泰民安，加法。</p><p>&nbsp;最近60年，我把前30年看作“虚数”，后30年看作“实数”。为啥？前30年有“斗争”，“与天斗，与地斗，与人斗，其乐无穷”，外斗修帝主义，内斗地富反坏，直斗得天昏天暗，是非难辨，人身不保，生产力的创造自然也就退居“二线”了。后30年虽有竞争，却没“斗争”，所以，人的主观能动性得到空前解放，我们成为全世界最为耀眼的一个“增长极”！</p><p>&nbsp;下一个30年，“竞争”与“合作”的关系怎么处理？“和谐”怕是硬道理。</p><p><b>第三个感想：“一穷二白”与“后来居上”。</b></p><p>&nbsp;在哈佛大学接受提问的时候，话赶话，赶出这样一个回答：先富有先富的累赘，后富有后富的便利——西方人过去已经购买过的东西，像房子和房子里的贵重物品，他现在就不需要购买了；而我们中国许多人过去没买过这些东西，所以购买力就旺盛。</p><p>&nbsp;毛泽东说过，一穷二白也有一穷二白的好处，可以画最新最美的图画。</p><p>&nbsp;这里好有一比：改革开放30年，这当中许多人曾有个“铁饭碗”，这是优势，似乎不用为未来发愁；但也是劣势，反而捆住了自己的手脚。而另一些连饭碗也没有的人，只好“自己给自己造饭碗”，于是，这些人成为中国最早的万元户、百万富翁乃至杰出企业家。</p><p>&nbsp;西方人富了，富有富的副作用，食利阶层逐步扩大，许多人是在“用钱挣钱”，那种为工作“殚精竭虑，废寝忘食”的“原始图景”在他们的生活中渐行渐远。但我们没有钱，我们还得艰苦创业，我们还得把自己的脑力和体力挖掘到最大化，“别人睡觉的时候，我们得走着”——而这，正是我们可以后来居上的理由。</p><p>&nbsp;众所周知，新建企业的设备一般总是比先建企业的设备要前卫一些，而先建企业又不可能一夜之间把所有的旧设备统统扔进垃圾场。后发国家与先发国家之间也往往面临着同样的际遇。这也是后来居上的理由。</p><p>&nbsp;每一个后发国家的崛起，都与新的历史潮流有关。在互联网、信息化这个历史潮流滚滚涌来的时候，全世界所有国家几乎一下子站到了同一起跑线，这就是机遇。</p><p>我们中国创业者最大的幸福，就是坐拥全世界最大的市场。</p><p>&nbsp;而且，你对这个市场的脉搏最有可能把握得最准。</p><p>&nbsp;所以，还是我老说的那句话：你只要做成中国第一，那你就有机会成为世界第一。</p><p><b>跨国公司与中国公司谁更“善”？</b></p><p style="text-indent: 2em">在哈佛打嘴仗，有提问者说美国公司“如何如何负责”，中国公司“如何如何不负责”……我说，当中国古人说“己所不欲，勿施于人”、“穷则独善其身，达则兼济天下”时，你们还没建国呢！跨国公司虽然很强，但它们在中国，财富度和慈善度是不成比例的，所做善事的比例还不如我们中国企业大。你们不是有这个做善事的习惯吗？那么为什么你们拿走我们的市场，拿走销售额，拿走利润，却不留下更多的善事？结论：外国的月亮不见得就比中国圆。一位对跨国公司有着深刻了解的政界人士曾私下对我说：跨国公司的账算得特细，他们在公益上只花一点点小钱，却用它撬出更大的蛋糕。</p><p style="text-indent: 2em">千万不要误解，别以为我要抨击“公益背后有收益”这一现象。</p><p style="text-indent: 2em">我和公司管理层有过多次讨论，最后得出的结论是：衡量一个企业是否履行社会责任，宜用“行为标准”，而不宜用“动机标准”。不管跨国企业，还是中国公司，只要你做了好事就行，我们最好不要过分琢磨它背后隐藏的动机——第一，探讨动机没有意义，因为同样一件事你可以推测出一万个不同的动机，孰是孰非？第二，如果做了公益有收益，那叫“好人得好报”；如果做了公益的人和不做公益的人统统获得一样的回报，那事实上就等于“好人不得好报”；好人得好报，天公地道；难道非得好人不得好报，你才高兴？第三，做公益也要讲可持续发展，如果只有公益没有收益，只出不入，那就无法形成良性循环，只能进行单向性乃至一次性的“断头公益”；而只有形成“公益——收益——公益”的良性循环、永续循环，才能完成可持续发展的“千头公益”、“万头公益”。&nbsp;</p><p style="text-indent: 2em">所以，如果本着“动机论”，那么，“不为收益做公益”固然是一种高尚，但“为了收益做公益”同样也是一种善举；如果本着“效能论”，那么，“公益背后无收益”是一种“有限公益”（竭泽而渔），“公益背后有收益”是一种“循环公益”（渔养并重）。</p><p style="text-indent: 2em">行文至此，自然有朋友要问了：你是属于“公益——收益”式呢，还是属于“公益——无收益”式呢？</p><p style="text-indent: 2em">坦率地说，这两种我都做过。救人、济穷、赈灾、助学，这方面的投入我们仅最近三年就花出约两三个亿，把它归入“不为收益做公益”的范畴，大家大概没有意见。但我们扶植奶农的活动，的确是“公益”、“收益”双丰收——我们向农民发放种草补贴，投放养牛保险（1000万元），发放养牛贷款（年保持1亿元以上的规模），提供免费培训，实施胚胎移植与性控技术（母牛生母犊率高达93%以上）……这些既有帮助农民脱贫致富的“公益成分”，也有为企业获得优质奶源的“收益成分”</p><p style="text-indent: 2em">（资料：奶贱于水。据报道，250ml利乐砖无菌纯牛奶，1997年的市场价为3.6元/包；1999年的市场价为2.4元/包；2007年的市场价为2.0元/包，有的月份甚至跌到1.6元/包。而2004年至2007年末，北方企业向农民的收奶价由1.7元左右/公斤上涨到3元以上/公斤，约上涨一倍。企业在产品降价、原奶涨价的双重压力下，亏损面逐年扩大，2004年的行业亏损面为1/3，2007年大概有一半乳制品企业陷入亏损境地。而原奶价格虽然攀升，但由于饲料等养牛成本不断上升，几年来奶农的收益也持续下降。这种现象，蒙牛公司在2005年乳业年会上曾将其概括为“三个阵痛”：奶农的阵痛，企业的阵痛，政府的阵痛。2008年，牛奶的市场售价开始回归，奶农的收益也开始回归。</p><p style="text-indent: 2em">在企业社会责任的履行上，存在“公益背后有收益”与“公益背后无收益”之分，也存在“有限公益”与“循环公益”之别，这种认识我们早几年就是有的。但这次巧了，因为要去哈佛大学，我们搜集资料时才偶然发现，迈克尔波特教授2006年12月份曾提出一个理论，将社会责任模式区分为两类：一是“反应型责任模式”，企业向社会捐献，或消减自身对社会带来的负面影响（如环保）；二是“战略型责任模式”，企业和社会双赢（如企业由于开发出污染小的汽车而获得巨大的商业利润）——这也算世界虽大，东西一理，所见略同吧。</p><p style="text-indent: 2em">在哈佛，提问者最不明白的问题是：“你为什么把股份全部捐了？”“你为什么不给后代留下一点？”这和国内的提问是一样的。</p><p style="text-indent: 2em">现在，再回到开头的问题上吧：在中国，跨国公司与中国公司谁更“善”？</p><p style="text-indent: 2em">这个问题的答案其实并不重要，但有一样东西很重要：中国人的责任自信！</p><p><b>大品牌就得负大责任。</b>这不是口号，不是面具，而必须化作企业的“实践”与“瓤子”。承担社会责任是企业的第一要务。</p><p>&nbsp;为什么？</p><p>&nbsp;第一，无责任则无品牌。薪水微薄，员工不满意；质量低劣，顾客不买账；信誉欠佳，银行不放贷；贡献平平，政府不支持……不承担责任的品牌大不了。</p><p>&nbsp;第二，大品牌伴随大监督。你是大品牌，所以，媒体盯你最勤，队友跟你最紧，社会评你最多。不要说“他比我差为什么你不说他”，因为你是大品牌。不要说“你不怕死我也不怕死”，因为你是大品牌。不要说“我栽了树凭什么你也乘凉”，因为你是大品牌。你的四周布满了眼睛。怀疑的眼睛，期待的眼睛，威慑的眼睛，完善的眼睛。</p><p>&nbsp;第三，大品牌关联大市场。假如市场扩大一倍，你受益的比例比别人大；假如市场萎缩一圈，你受损的程度比别人深。你与整个行业同进同退，共生共荣。因此，你要承担更大的责任——你要代表行业与消费者沟通；你要代表行业肩负起产业进步的使命；你要比小品牌更多地关注全局，为了避免“死掉一个小品牌，毁掉一个大行业”的株连效应，你甚至要为小品牌充当免费的导师。</p><p>&nbsp;第四，大责任通向大舞台。负一省之责，你是一省品牌；负一国之责，你是一国品牌；负全球之责，你是世界品牌。责任有多大舞台就有多大。</p><p>&nbsp;第五，大品牌责系大人群。你是行业领导者，最多的人信赖着你，最多的人支持着你，你的一举一动牵涉着最多人的利益——那么，你不负大责任谁负？</p><p>&nbsp;总之，大品牌就得负大责任。有时候，超额负点责任也不怕。下面这个真实的故事，是我3月16日在央视《中国青年创业行动》栏目里讲的：</p><p>&nbsp;2005年有一天，东部沿海的一个城市传来一个消息，说“一盒酸奶喝死了一个孩子！”</p><p>&nbsp;紧跟着，媒体来了，要报道！</p><p>&nbsp;我说：“不行。等查清了再说。一切后果我负责。”</p><p>&nbsp;大家都知道，食品安全，人命关天。一旦发生命案，要的就不是一条命，而是两条命——顾客的命没了，企业的命也没了。</p><p>&nbsp;最终，公安局查清楚了：是孩子姥爷下的毒。原来，这个孩子天生弱智，而女婿还想要一个孩子，就与女儿闹离婚。姥爷心疼女儿，就决定“千斤重担一人挑”，对外孙实施“安乐死”。恰恰这个傻外孙脑子虽傻，肚子却不傻，平时就喜欢喝蒙牛酸奶。这样，他姥爷就在酸奶里下了“毒鼠强”。</p><p>&nbsp;这个事情跟我们没关系！但是，在情况没查清的时候，我们立即回收了这个城市的所有酸奶，一共30吨，统统销毁！为什么？因为消费者的安全与健康是第一位的。是你的责任，你要承担起来；不是你的责任，你不妨也先承担起来，是是非非过后再说。</p><p>&nbsp;我在这里想提醒大家的是：创业难，你不难别人都要难你！即使你兢兢业业，都有可能死掉；而你要是马马虎虎，那活着是偶然的，死掉是必然的！</p>]]></content:encoded><guid>http://www.niuchao.com/Article/13.aspx</guid><trackback:ping>http://www.niuchao.com/Article/13/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/13.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/13/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/12.aspx</link><title><![CDATA[好听的歌：自由飞翔]]></title><author></author><category>超之声波</category><pubDate>Mon, 07 Apr 2008 22:32:21 GMT</pubDate><description><![CDATA[自由飞翔 - 凤凰传奇 Rap：Yo Yo Yo Come OH Yeah （北风吹送）一路的芳香还有婆娑轻波 转了念的想那些是非因果 一路的芳香让我不停捉摸 Rap：Yo Yo Yo Come OH Yeah 是谁在唱歌温暖了寂寞 白云悠悠蓝天依旧泪水在漂泊 在那一片苍茫中一个人生活 看见远方天国那璀璨的烟火 Rap：Yo Yo Yo Come OH Yeah （北风吹送）一路的芳香还有婆娑轻波 转了念的想那些是非因果 一路的芳香让我不停捉摸 Rap：Yo Yo Yo Come OH Yeah 是谁听着歌遗忘了寂寞 漫漫长夜一路芬芳岁月曾流过 在那人潮人海中你也在沉默 和我一起漂泊到天涯的交]]></description><content:encoded><![CDATA[<p>自由飞翔 - 凤凰传奇<br /><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Yo Yo Yo Come OH Yeah</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">（北风吹送）一路的芳香还有婆娑轻波</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">转了念的想那些是非因果</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">一路的芳香让我不停捉摸</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Yo Yo Yo Come OH Yeah</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">是谁在唱歌温暖了寂寞</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">白云悠悠蓝天依旧泪水在漂泊</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">在那一片苍茫中一个人生活</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">看见远方天国那璀璨的烟火</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Yo Yo Yo Come OH Yeah</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">（北风吹送）一路的芳香还有婆娑轻波</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">转了念的想那些是非因果</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">一路的芳香让我不停捉摸</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Yo Yo Yo Come OH Yeah</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">是谁听着歌遗忘了寂寞</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">漫漫长夜一路芬芳岁月曾流过</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">在那人潮人海中你也在沉默</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">和我一起漂泊到天涯的交错</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">在你的心上自由地飞翔</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">灿烂的星光永恒地徜徉</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">一路的方向照耀我心上</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">辽远的边疆随我去远方</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Don`t Come back</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">是谁在唱歌温暖了寂寞</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">白云悠悠蓝天依旧泪水在漂泊</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">在那一片苍茫中一个人生活</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">看见远方天国那璀璨的烟火</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Yo Yo Yo Come OH Yeah</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">在你的心上自由地飞翔</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">灿烂的星光永恒地徜徉</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">一路的方向照耀我心上</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">辽远的边疆随我去远方</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Don`t Come back</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">这是我远行的感受</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">不应该让我继续这种伤痛</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">别覆盖我会坚持往下行走</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">原始界的风伴随我们的行踪</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">脚步重变得重变得失去自我</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">迷恋风景我会尽情大去放松</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">轻风伴我相送岁月如此沉重</font></span><br /><span class="prelrc">&nbsp;早已热泪感动被你一水消融</span><br /><strong><font color="#ff5a00"><span class="nowlrc">&nbsp;（驾驾驾吁……）</span><br /></font></strong><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Rap：Yo Yo Yo Come OH Yeah</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">在你的心上自由地飞翔</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">灿烂的星光永恒地徜徉</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">一路的方向照耀我心上</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">辽远的边疆随我去远方</font></span><br /><span style="font-size: 12px; margin-left: 12px">&nbsp;<font color="#000000">Over...</font></span><br /></p>]]></content:encoded><guid>http://www.niuchao.com/Article/12.aspx</guid><trackback:ping>http://www.niuchao.com/Article/12/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/12.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/12/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/11.aspx</link><title><![CDATA[宝贝儿满月了]]></title><author></author><category>我爱我家</category><pubDate>Wed, 02 Apr 2008 15:41:28 GMT</pubDate><description><![CDATA[]]></description><content:encoded><![CDATA[<p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/xshgwr_IMG0174A.jpg" width="600" /></p><p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/smw6jb_IMG0180A.jpg" width="600" /><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/ecxetw_IMG0181A.jpg" width="600" /><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/ujp6d0_IMG0182A.jpg" width="600" /></p>]]></content:encoded><guid>http://www.niuchao.com/Article/11.aspx</guid><trackback:ping>http://www.niuchao.com/Article/11/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/11.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/11/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/10.aspx</link><title><![CDATA[我家的小狗狗，可爱至极]]></title><author></author><category>我爱我家</category><pubDate>Wed, 02 Apr 2008 08:59:11 GMT</pubDate><description><![CDATA[]]></description><content:encoded><![CDATA[<p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/mmvj7d_IMG0161A.jpg" width="600" /></p><p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/3o1qu4_IMG0170A.jpg" width="600" /></p><p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/flry0b_IMG0162A.jpg" width="600" /></p><p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/fd1ziy_IMG0163A.jpg" width="600" /></p><p><img class="Image" height="450" alt="" src="http://www.niuchao.com/Attach/month_0804/hjkd1j_IMG0168A.jpg" width="600" /></p>]]></content:encoded><guid>http://www.niuchao.com/Article/10.aspx</guid><trackback:ping>http://www.niuchao.com/Article/10/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/10.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/10/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/9.aspx</link><title><![CDATA[用Visual C#实现P2P应用程序]]></title><author></author><category>学习笔记</category><pubDate>Tue, 01 Apr 2008 15:59:13 GMT</pubDate><description><![CDATA[一．前言：P2P，即英文Peer-to-Peer的缩写，中译为对等互联或点对点技术。讲到P2P，人们就会想起Napster，Napster让人们认识到了P2P技术的威力，P2P技术也就通过Napster进入了大多数用户的视野，Napster的音乐文件交换功能是P2P的一个主要应用。P2P技术可以让用户可以直接连接到其他用户的计算机，进行文件共享与交换。同时P2P在深度搜索、分布计算、协同工作等方面也大有用途。简单地说，P2P就是一种用于不同PC用户之间，不经过中继设备直接交换数据或服务的技术，它允许Internet用户直接使用对方的文件。每个人可以直接连接到其他用户的计算机，并进行文件的交换，]]></description><content:encoded><![CDATA[<p><strong>一．前言：</strong></p><p>P2P，即英文Peer-to-Peer的缩写，中译为对等互联或点对点技术。讲到P2P，人们就会想起Napster，Napster让人们认识到了P2P技术的威力，P2P技术也就通过Napster进入了大多数用户的视野，Napster的音乐文件交换功能是P2P的一个主要应用。P2P技术可以让用户可以直接连接到其他用户的计算机，进行文件共享与交换。同时P2P在深度搜索、分布计算、协同工作等方面也大有用途。</p><p>简单地说，P2P就是一种用于不同PC用户之间，不经过中继设备直接交换数据或服务的技术，它允许Internet用户直接使用对方的文件。每个人可以直接连接到其他用户的计算机，并进行文件的交换，而不需要连接到服务器上再进行浏览与下载。因为消除了中间环节，P2P技术使得网络上的沟通变得更容易、更直接。P2P改变了Internet现在的以大网站为中心的状态、重返&quot;非中心化&quot;，并把权力交还给用户。从某种意义上讲，P2P体现了Internet的本质。在网络尚未发展成为现在的Web之前，网民就是利用所谓的&quot;布告板&quot;等渠道彼此直接交换信息和文件。</p><p>目前Internet的存储模式是&quot;内容位于中心&quot;，而P2P技术的运用将使Internet上的内容向边缘移动。这将带来以下改变：首先，客户不再需要将文件上传到服务器，而只需要使用P2P与其他计算机进行共享；其次，使用P2P技术的计算机不需要固定的IP地址和永久的Internet连接，这使得占有极大比例的拨号上网用户也可以享受P2P带来的变革。</p><p>理解P2P技术方面的最好方法是仔细观察并理解一个实际的P2P应用程序。C#作为微软.Net战略的重要棋子，对网络编程提供了很好的支持和优化。本文就通过一个程序，向大家介绍一下C#下的P2P编程的方法和实现机理。本文的这个程序虽然不是很有用，但却很直观地给出了P2P（点对点）编程以及套接口编程的一些基本知识和概念。它是建立在TcpListener以及TcpCl<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1164.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">ie</font></a>nt这两个类基础上的，除外还有相应的输入和输出控制。实现的原理也比较简单，但是用到了P2P技术重返&quot;非中心化&quot;的基本原则。简言之，用这个程序可以在网络中发送、接受信息，任何一台计算机既可以作为服务器端，又可以作为客户端。程序共用到了四个类：一个Listener类（用来监听新的连接）、一个Sender类（用来发送信息）、一个Inputhandler类（用来控制输入）、一个Initialize类（用来完成初始化工作）。下面，我先给大家介绍一下这四个类，最后再给出程序的具体实现方法。</p><p><strong>二．基本类介绍：</strong><strong>1．Listener类：</strong></p><p>Listener类是用来监听新的连接。当它的一个对象被建立并开启后，该对象就开始不断监听来自网络中的连接请求。一旦有了一个连接请求，该对象就设法建立连接并取得它的字节流进而转化成字符串显示在控制台中。当一个连接结束后，该对象就继续进行监听来自网络中的连接请求。</p><p>代码以及注释如下：</p><p>namespace P2PTest</p><p>{</p><p>using System;</p><p>using System.Net.Sockets;</p><p>using System.Threading;</p><p>public class Listener</p><p>{</p><p>private Thread th;</p><p>private TcpListener tcpl;</p><p>public bool listenerRun = true;</p><p>//listenerRun为true，表示可以接受连接请求，false则为结束程序</p><p>public Listener()//构造函数</p><p>{</p><p>th = new Thread(new ThreadStart(Listen));//新建一个用于监听的线程</p><p>th.Start();//打开新线程</p><p>}</p><p>public void Stop()</p><p>{</p><p>tcpl.Stop();</p><p>th.Abort();//终止线程</p><p>}</p><p>private void Listen()</p><p>{</p><p>try</p><p>{</p><p>tcpl = new TcpListener(5656);//在5656端口新建一个TcpListener对象</p><p>tcpl.Start();</p><p>Console.WriteLine(&quot;started listening..&quot;);</p><p>while(listenerRun)//开始监听</p><p>{</p><p>Socket s = tcpl.AcceptSocket();</p><p>string remote = s.RemoteEndPoint.ToString();</p><p>Byte[] stream = new Byte[80];</p><p>int i=s.Receive(stream);//接受连接请求的字节流</p><p>string msg = &quot;&lt;&quot; + remote + &quot;&gt;&quot; + System.Text.Encoding.UTF8.GetString(stream);</p><p>Console.WriteLine(msg);//在控制台显示字符串</p><p>}</p><p>}</p><p>catch(System.Security.SecurityException)</p><p>{</p><p>Console.WriteLine(&quot;firewall says no no to application - application cr<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1164.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">ie</font></a>s..&quot;);</p><p>}</p><p>catch(Exception)</p><p>{</p><p>Console.WriteLine(&quot;stoped listening..&quot;);</p><p>}</p><p>}</p><p>}</p><p>}</p><p><strong>对Listen（）函数的补充说明：</strong></p><p>这个函数是Listener类的核心部分。该函数首先被构造函数调用。只要布尔值listenerRun为true，我们就可以在端口5656创建并开始一个Tcp监听对象TcpListener进行监听网络中的连接请求，而一旦listenerRun被置为false，则表示程序结束了。在循环体内部，我们先接受一个连接，用s.RemoteEndPoint获得它的IP地址并获得其字节流。根据获得的字节流，我们用UTF8编码将它转化为字符串。最后，我们就在控制台中显示获得的字符串。</p><p>对于catch语句，第一个块捕获一个可能由防火墙引起的例外。因为对于防火墙而言，它可能认为这是一个特洛依<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1221.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">木马</font></a>或是儒虫<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1221.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">病毒</font></a>什么的，所以就会拒绝通过。解决办法就是重新配置防火墙。第二个块用于捕获一般的例外，比如当我们调用了stop（）函数后，我们销毁了TcpListener对象，那就自然不可能再进行监听了。</p><p><strong>2．Sender类：</strong></p><p>Sender类就一个函数，所以是相当简单的。</p><p>代码以及注释如下：</p><p>namespace P2PTest</p><p>{</p><p>using System;</p><p>using System.IO;</p><p>using System.Net.Sockets;</p><p>public class Sender</p><p>{</p><p>public void Send(string[] aInput)</p><p>{</p><p>string stream = &quot;&quot;;</p><p>//获得要发送的信息</p><p>for(int i=2; i&lt;aInput.Length; i++)</p><p>{</p><p>stream += aInput[i] + &quot; &quot;;</p><p>}</p><p>try</p><p>{</p><p>TcpClient tcpc = new TcpCl<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1164.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">ie</font></a>nt(aInput, 5656);</p><p>//在5656端口新建一个TcpCl<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1164.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">ie</font></a>nt对象</p><p>NetworkStream tcpStream = tcpc.GetStream();</p><p>StreamWriter reqStreamW = new StreamWriter(tcpStream);</p><p>reqStreamW.Write(stream);</p><p>reqStreamW.Flush();//发送信息</p><p>tcpStream.Close();</p><p>tcpc.Close();</p><p>}</p><p>catch(Exception)</p><p>{</p><p>Console.WriteLine(&quot;connection refused by target computer&quot;);</p><p>}</p><p>}</p><p>}</p><p>}</p><p><strong>对Send（）函数的补充说明：</strong></p><p>Send（string[] aInput）函数将一个数组作为参数。数组的第一个元素Send（aInput[0]）必须包含&quot;send&quot;这个字，否则Sender对象不会被创建（更多内容在InputHandler类中）；第二个元素包含了目标计算机的IP地址；剩下的就是要发送的内容信息了。</p><p>在try块中，我们根据远程计算机的IP地址在端口5656（要确保端口号统一）创建了一个TcpCl<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_1164.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">ie</font></a>nt对象。然后，我们建立一个NetworkStream和一个StremWriter对象来发送我们的信息。在catch块中，我们用它来捕获一般的例外，比如远程计算机拒绝连接请求、网络不通什么的。</p><p><strong>3．InputHandler类：</strong></p><p>InputHandler类主要用来控制用户输入。</p><p>代码以及注释如下：</p><p>namespace P2PTest</p><p>{</p><p>using System;</p><p>public class InputHandler</p><p>{</p><p>public bool appRun = true;//当appRun为false时，程序结束</p><p>public InputHandler()</p><p>{</p><p>Console.WriteLine(&quot;type help for a list of commands.&quot;);</p><p>Input();</p><p>}</p><p>private static Listener li;//一个静态的Listener对象</p><p>private string inparam;</p><p>private string[] aInput;//数组aInput用于接受用户输入的信息</p><p>public void Input()</p><p>{</p><p>while(appRun)</p><p>{</p><p>inparam = Console.ReadLine();</p><p>aInput = inparam.Split(' ');</p><p>//将inparam分割的目的是为了获得字符串中的第一个字，从而执行以下不同的命令</p><p>switch(aInput[0])</p><p>{</p><p>case &quot;send&quot;://如果是&quot;send&quot;，则新建一个Sender对象并发送信息</p><p>Sender se = new Sender();</p><p>se.Send(aInput);</p><p>break;</p><p>case &quot;start&quot;://如果是&quot;start&quot;，则新的开始监听</p><p>try</p><p>{</p><p>li.listenerRun = false;</p><p>li.Stop();</p><p>}</p><p>catch(NullReferenceException)<br /></p><p>{</p><p>;</p><p>}</p><p>finally</p><p>{</p><p>li = new Listener();</p><p>}</p><p>break;</p><p>case &quot;stop&quot;://如果是&quot;stop&quot;，则停止监听</p><p>try</p><p>{</p><p>li.listenerRun = false;</p><p>li.Stop();</p><p>}</p><p>catch(NullReferenceException)</p><p>{</p><p>;</p><p>}</p><p>break;</p><p>case &quot;exit&quot;://退出程序</p><p>try</p><p>{</p><p>li.listenerRun = false;</p><p>li.Stop();</p><p>}</p><p>catch(NullReferenceException)</p><p>{</p><p>;</p><p>}</p><p>finally</p><p>{</p><p>appRun = false;</p><p>}</p><p>break;</p><p>case &quot;help&quot;://显示帮助信息</p><p>Console.WriteLine(&quot;Commands:&quot;);</p><p>Console.WriteLine(&quot;start: starts the listener&quot;);</p><p>Console.WriteLine(&quot;stop: stops the listener if started&quot;);</p><p>Console.WriteLine(&quot;send: send &lt;IP&gt; &lt;message&gt; sends a message&quot;);</p><p>Console.WriteLine(&quot;exit: exits the application&quot;);</p><p>Console.WriteLine(&quot;help: you already know&quot;);</p><p>break;</p><p>default:</p><p>Console.WriteLine(&quot;Invalid command&quot;);</p><p>break;</p><p>}</p><p>}</p><p>}</p><p>}</p><p>}</p><p><strong>对InputHandler类的补充说明：</strong></p><p>该类中有一个静态的Listener对象li，一旦计算机运行此程序并执行&quot;start&quot;操作，该计算机就可以成为网络中的服务器来监听其他计算机的连接请求。而该类的核心部分是一个switch case语句系列，通过不同的操作，我们可以使计算机扮演不同的角色：&quot;send&quot;操作表明该计算机相对目的计算机而言成了客户端；而&quot;start&quot;操作就将计算机自身置为服务器端，这正体现了P2P的既是服务器端又是客户端的&quot;非中心化&quot;的原则；同时程序也提供了一些其他的辅助操作。</p><p><strong>4．Initialize类：</strong></p><p>Initialize类进行程序的初始化工作，它新建了一个InputHandler对象，只要该对象的布尔值appRun为true，就一直运行之，直到该值为false，程序退出。</p><p>代码以及注释如下：</p><p>namespace P2PTest</p><p>{</p><p>using System;</p><p>public class Init</p><p>{</p><p>public static void Main()</p><p>{</p><p>InputHandler ih = new InputHandler();//新建一个InputHandler对象</p><p>while(ih.appRun);//直到ih.appRun为false，程序退出</p><p>Console.WriteLine(&quot;exiting..&quot;);</p><p>}</p><p>}</p><p>}</p><p>到此为止，四个类已经介绍完毕，我想大家也早已等不及了吧，下面就简单给大家介绍一下具体实现程序的方法。</p><p><strong>三．实现方法</strong> ： 首先，打开Visual Studio.Net，新建一个名为P2Ptest的控制台应用程序的Visual C#项目，图示如下：图1 其次，将以上四个类分别保存为四个文件：listener.cs，sender.cs，inputHandler.cs，initialize.cs。然后将这四个文件添加到当前的工程中，同时把原有的主文件删除即可（因为在initialize.cs中已经有主函数了）。 最后，按Ctrl+F5即可执行程序了。 为了进行测试，我们需要打开两个P2Ptest程序，一个作为服务器端，另一个作为客户端。服务器端的图示如下（此时已经开始监听了）：图2 客户端的图示如下（输入命令行：send 10.85.7.79 Hello,I'm Pitt.Can you hear me??）：图3 再看服务器端的情况，图示如下：图4 从图示可以看到服务器端已经收到消息了。同时，只要客户端也开启了监听功能，服务器端也就能向客户端发送信息了。这样它们的关系就不再是服务器－客户机的关系了，而是Peer-to-Peer的关系了。</p><p><strong>四．总结：</strong></p><p>现在一个很基本的P2P应用程序以及完成，通过它，我们可以利用P2P技术的基本特性实现点对点通信。通过这个程序，我相信大家对C#下的P2P编程应该有了大致的了解。对于这个程序，不足的一点是功能比较简单，只可以发送、接受信息，而且还是基于控制台的，读者可以试着开发出功能更强大的基于<a class="channel_keylink" href="http://www.ttadd.com/diannao/List/List_420.html" target="_blank" target="_blank" target="_blank"><font color="#000000" size="2">Windows</font></a> Forms的P2P应用程序。</p><p>最后，笔者希望能通过此文唤起大家对P2P技术的兴趣。因为P2P身后所蕴藏着的无比的创造力使人们对未来互联网充满了美好的憧憬，现在世界范围的P2P应用热潮也是一浪高过一浪。在可以预见的未来，随着对P2P研究的进一步深入和关注P2P的群体逐渐增多，P2P必将进入一个飞速发展的新时期。</p>]]></content:encoded><guid>http://www.niuchao.com/Article/9.aspx</guid><trackback:ping>http://www.niuchao.com/Article/9/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/9.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/9/Feeds.ashx</wfw:commentRss></item><item><link>http://www.niuchao.com/Article/8.aspx</link><title><![CDATA[喜欢许巍的歌]]></title><author></author><category>超之声波</category><pubDate>Sun, 30 Mar 2008 16:25:31 GMT</pubDate><description><![CDATA[蓝莲花、曾经的你、完美生活、旅行、像风一样自由、时光给人一种涤荡心灵的感觉听着他的歌，适合喝点小酒、睡个小觉、抽个小烟、聊个小天]]></description><content:encoded><![CDATA[<p><img class="Image" alt="" src="http://www.niuchao.com/Attach/month_0803/4i90pv_163056_1.jpg" /></p><p>蓝莲花、曾经的你、完美生活、旅行、像风一样自由、时光</p><p>给人一种涤荡心灵的感觉</p><p>听着他的歌，适合喝点小酒、睡个小觉、抽个小烟、聊个小天</p>]]></content:encoded><guid>http://www.niuchao.com/Article/8.aspx</guid><trackback:ping>http://www.niuchao.com/Article/8/Track.aspx</trackback:ping><comments>http://www.niuchao.com/Article/8.aspx#CommentPostAnchor</comments><wfw:commentRss>http://www.niuchao.com/Article/8/Feeds.ashx</wfw:commentRss></item></channel></rss>