- 博客(31)
- 收藏
- 关注
原创 Two articles on C++ lvalues
http://www.embedded.com/story/OEG20010518S0071http://www.embedded.com/story/OEG20010618S0075 Summary:An expression yields either an lvalue or an rvalue. Lvalue is something referring to an objec
2007-09-01 22:58:00
678
原创 Why size_t matters?
A good article explaining why comes the size_t type for C/C++:http://www.embedded.com/columns/programmingpointers/200900195
2007-09-01 01:25:00
797
原创 JavaScript不同监听事件的方法
以下这几个链接比较全面的介绍了各种监听JavaScript事件的方法:Early event handlers (Inline mode):http://www.quirksmode.org/js/events_early.htmlTraditional event registration model:http://www.quirksmode.org/js/events_tra
2007-08-11 18:06:00
936
1
转载 Linux下的主要文件
boot/grub/grub.conf GRUB 引导器配置文件/boot/module-info-* Linux 核心模块信息/boot/System.map-* Linux 系统影像文件/boot/vmlinuz-* Linux 核心/etc/aliases 邮件别名/etc/at.deny 记录哪些用户静止使用 at 命令/etc/auto.master 配置 autofs 程序,使之能
2007-07-18 23:07:00
782
原创 Cool URIs don't change
A cool article by Tim Berners-Leehttp://www.w3.org/Provider/Style/URI
2007-05-10 00:14:00
613
原创 Memcached
一年多之前就与朋友讨论过memory cache相关的东西,甚至当时还打算自己动手写一个。后来由于当时的系统压力还不需要动用memcache就放弃了。现在发现原来早已存在这样一套缓存系统——memcached。并且这套系统本身已经充分考虑了分布式情况下的应用,同时对目前主流的语言都有了API。打算近期试验一下memcached和drupal结合的性能提升程度。
2007-04-21 21:05:00
945
1
原创 学习Perl闭包几点心得
1. 什么是闭包?《Perl高级编程》里面是这么说的:A closure is a code block that captures the environment where its defined -- specifically, any lexical variables the block uses that were defined in an outer scope.2. 闭包一
2007-01-14 03:30:00
1461
原创 在IE中最小高度问题
由于在不同浏览器中很难显示出相同的外观,通常会采取设置一个空的,赋给一定的高度。但是IE中对于空的会有一个最小高度,我是用的IE7,值为20px。解决办法:1. 在标签中加入一段柱石,如:2. 在标签中加一个 ,同时CSS属性里面加上font-size:1px; line-height:0px;以上两种方法参考http://archivist.incutio.com/view
2006-11-01 11:53:00
1208
转载 Developer's Dilemma: PHP or Perl?
Citing http://www.sci-tech-today.com/story.xhtml?story_id=32961: In some ways, it is the scrappy contender versus the tested old-timer, as PHP and Perl duke it out to win developer attention. But m
2006-10-11 11:12:00
809
转载 常挂在美国人嘴边的口语
From http://sl.iciba.com/html/2006/1010/10/150562_1.htmA thousand times no! 绝对办不到! Dont mention it. 没关系,别客气。 Who knows! 天晓得! It is not a big deal! 没什么了不起! How come… 怎么回事,怎么搞的。 Easy does it. 慢慢来。 Do
2006-10-10 15:56:00
984
原创 The "tr///" operator in Perl
以前一直没仔细关注过tr的用法,今天因为论坛中的一个问题,Google找到这篇文章:http://mailman.linuxchix.org/pipermail/courses/2003-July/001302.html
2006-10-09 15:00:00
1032
原创 A physicist, an engineer, and a computer scientist discussing the nature of God.
A physicist, an engineer, and a computer scientist were discussing the nature of God.“Surely a Physicist,” said the physicist, “because early in the Creation, God made Light; and you know, Maxwell’s
2006-09-25 11:11:00
970
转载 各类数据库SELECT第11条-第20条记录的语句总结
发信人: Corps (最后一次机会了), 信区: Database标 题: 各类数据库SELECT第11条-第20条记录的语句总结发信站: 日月光华 (2004年05月27日11:36:32 星期四), 站内信件如果有表news,其中字段有id, title, date(id为unique key)目标:获得第11条到20条的纪录,按date排序(这里的第11-20条记录是表示记录编号
2006-09-22 19:11:00
2394
1
原创 Apache安装后无法启动的问题
安装Apache 2.0.xx时,可能会出现无法启动的情况,错误信息为:No installed service named "Apache2" .解决办法:"C:/Program Files/Apache Group/Apache2/bin/apache" -k install -n "Apache2"此时如果出现以下错误:(OS 10048)Only one usage o
2006-09-16 16:50:00
1739
转载 西門吹雪的劍道
西門吹雪忽然道:"你學劍?"葉孤城道:"我就是劍。"西門吹雪道:"你知不知道劍的精義何在?"葉孤城道:"你說。"西門吹雪道:"在於誠。"葉孤城道:"誠?"西門吹雪道:"唯有誠心正義,才能到達劍術的巅峰,不誠的人,根本不足論劍。"葉孤城的瞳孔突又收縮。西門吹雪盯著他,道:"你不誠。"葉孤城沉默了很久,忽然也問道:"你學劍?"西門吹雪道:"學無止境,劍更無止境。"葉孤城道:"你既學劍,就該知道學劍的人
2006-09-16 15:20:00
1128
转载 18位身份证格式验证算法
转自:http://blog.youkuaiyun.com/jawsy/archive/2006/08/01/1006223.aspx公民身份号码是特征组合码,由十七位数字本体码和一位数字校验码组成.排列顺序从左至右依次为:六位数字地址码,八位数字出生日期码,三位数字顺序码和一位数字校验码。 1、地址码 表示编码对象常住户口所在县(市、旗、区)的行政区划代码,按 GB/T 2260 的规定执行。
2006-08-06 23:45:00
1598
原创 John Carmack密码:0x5f3759df
有人在Quake III的源代码里面发现这么一段用来求平方根的代码:/*================SquareRootFloat================*/float SquareRootFloat(float number) { long i; float x, y; const float f = 1.5F; x = number * 0.5F;
2006-06-19 16:47:00
1364
1
原创 PerlMagick在Windows下安装的问题
问题:在Windows下安装ImageMagick,会出现Cant load C:/Perl/site/lib/auto/Image/Magick/Magick.dll for module Image::Magick:load_file:/x8ew.......... at C:/Perl/lib/DynaLoader.pm line 230.解决办法:设置环境变量名 MAGI
2006-04-27 00:26:00
1636
原创 qmail tcpserver: fatal: unable to figure out port number for smtp
错误信息:tcpserver: fatal: unable to figure out port number for smtp /usr/local/bin/tcpserver: error while loading shared libraries: libc.so.6: failed to map segment from shared object 解决办法:1. Ope
2006-03-17 01:49:00
1994
原创 Can't load ...Magick.so错误解决
Cant load /usr/lib/perl5/site_perl/5.8.5/i386-linux-thread-multi/auto/Image/Magick/Magick.so for module Image::Magick: libMagick.so.10: cannot open shared object file: No such file or directory at
2006-03-15 07:29:00
1648
原创 CGI::Session什么时候需要手动调用flush()方法呢?
在一个cgi里面,发现总是没有真正把session文件写入目录,手动调用flush()方法之后就好了。但是在CGI::Session的文档里面明明说Normally it will be called for you just before the program terminates, or session object goes out of scope, so you should neve
2006-03-15 02:06:00
1109
原创 Niklaus Wirth
http://www.sinoprise.com/read.php?tid=1056&page=e景仰一下。Q: 您觉得怎样才是一种好的学编程的方式呢?一种编程工具是不是必要的?A: 我们因为要编程而学习语言,而不要本末倒置。本质是编程,编程的工具是语言,是一种形式符号。一种好的方法是从简单的(但不是一眼看穿的)例子开始。当设计一个程序时,必须时刻谨记设计的正确性取决于它的作用。为了构
2006-03-13 22:12:00
1316
原创 Perl闭包以及对mod_perl的影响
先看看这里:http://www.perl.com/doc/FAQs/FAQ/oldfaq-html/Q3.14.html 里面开始引用了Larry关于闭包的说法,翻译成中文大意是“这是一个来自于Lisp世界的名词,意指当你在某个特定的词法范围内定义了一个匿名函数,那么当你在该词法范围之外调用这个匿名函数时,它还是跟在这个词法范围内一样运行”。有点拗口,不过通过例子来更容易解释。#!perl
2006-03-07 16:48:00
915
原创 HTML::FillInForm.pm处理utf8报错的问题
HTML::FillInForm老是报这个错误:Parsing of undecoded UTF-8 will give garbage when decoding entities at /site/lib/HTML/FillInForm.pm line 86./n解决办法:HTML::FillInForm第86行处加上$self->utf8_mode(1);参考:http:
2006-03-06 22:47:00
989
原创 IE中JavaScript错误列表
error # 5 无效的过程调用或参数 error # 6 溢出 error # 7 内存不够 error # 9 下标越界 error # 10 该数组为定长的或临时被锁定 error # 11 被零除 error # 13 类型不匹配 error # 14 字符串空间不够 error # 17 不能执行所需的操作 error # 28 堆栈溢出 error # 35 未定义过程或函数 err
2006-03-06 20:41:00
4011
原创 JavaScript之IE与FireFox不兼容语法整理
1. 形如text的选项,FireFox中,可以用options[i].value来取值,默认等同于options[i].text;而在IE中,则必须要options[i].text,前者是取不到正确的值的。
2006-03-06 20:39:00
964
转载 Perl GD.pm模块的安装
http://www.issociate.de/board/post/153088/problem_installing_GD-2.19.htmlvertigo wrote:> Hello> > I can not install GD-2.19.> I tried with gd-2.0.33 and perl 5.6.8:> #perl Makefile.PL> #make> > an
2006-03-03 11:53:00
4185
1
转载 MySQL忘记root密码
To reset a root password that you forgot (using paths on our system): [root@host root]#killall mysqld[root@host root]#/usr/libexec/mysqld -Sg --user=root &
2006-02-23 07:54:00
1099
原创 DBD::mysql的安装
其实已经装过很多次了,不过以前从来没有遇到今天这样的问题。虽然其实所有的环境配置都是一样的:RHEL4, Perl 5.8.5, MySQL4.1.8。以前也遇到过报错信息为找不到mysql_config,当时只是把/path/to/mysql/bin添加到PATH环境变量中,就全部OK了。今天却不停的提示Cant load ...mysql/mysql.so for module DBD:
2006-02-22 03:38:00
4337
原创 cgi or mod_perl
摘自perlmonks.org( http://www.perlmonks.org/?node_id=518869)的一段讨论:Re: cgi or mod_perlby astaines on Dec 24, 2005 at 10:12 UTCA good question, but, at least partly, the wrong question. CGI is a useful lo
2005-12-25 18:01:00
1193
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人