2009/11/09 04:51 P.M.
还是得好好看手册。
chr 和 ord
函数原型:
int ord ( string $string ) //返回$string 首字母的ascii。
string chr ( int $ascii ) |
2009/11/04 06:36 P.M.
寻找,是的就是在寻找。
寻找一个比较适合自己得地方,但是想来也是没有办法得事情。最终由于很多原因还是搞砸了。只有回到原点再继续。
不过呢,还是对自己这几天得经历打个九十分。这几天让我成长了不少,让我有了很多认识。有了对自己得一个比较全面的评价。很多东西要得是自己的探讨,仔细细致的研究。而不是知道,知道太容易了。记得老大说“知行合一”。进过我的多番查考,知道了这句话的意思。这是伟大的王 |
2009/11/01 06:47 P.M.
" Encoding settings {
set encoding=utf-8
set fileencodings=utf-8,chinese,latin-1
" }
" Modeline and Notes {
" vim: set foldmarker={,} foldlevel=0 spell:
"
" This is my personal .vimrc, I don't recommend you copy it, just
|
2009/10/28 08:56 A.M.
实现串中单词首字母大写:
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <ctype.h> #define SIZE 50 void trim(char *); int main() { char str[SIZE] = " my name is xiang shou ding "; int len = strlen(str); int flag = 0; int i; //去除字串两边的空字符 trim(str); for (i = 0; i < len; i++) { if (isspace(str[i |
2009/10/27 04:56 P.M.
<html>
<head>
<title>Window object</title>
</head>
<body>
<script type="text/javascript">
for (f in document) {
document.write("document." + f + " = " + document[f]);
document.write("<br />");
}
</script>
</body>
</html>
贴到h |
2009/09/27 02:55 P.M.
is_numeric函数以前是没有怎么用过。但是今天在看代码的时候出现了,然后就好奇的看了下。 也引出了一个小问题:那就是关于数字字符串的识别(其中字符都是数字)。
is_numeric定义如下
is_numeric — Finds whether a variable is a number or a numeric string
Description
bool is_numeric ( mixed $var )
Finds whether the given variable is numeric. Numeric strings consist of optional sign, any number of digits, optional decimal part and optional exponential part. Th |
2009/09/13 11:23 P.M.
如题,咱们就可以开始了,vim号称是万年编辑器,如果没有它的好是得不到这个称号的。现在面对网络开发,php相对流行,不断得到认可,估摸着也学了两把,可是有的时候还是函数有点多,再加上扩展函数,没招,咱们得找个方法一步搞定。我是用vim出生的,所以就拿它来想办法了。也好,有个插件叫superTab,这家伙牛啊,用我们的tab键就搞定了自动补全,本来vim也是支持自动补全的,用的键是<c-p>(ctrl+p),在编写代码的过程当中,我们很容易发现,如果你的文件(指得是php文件)有 |
2009/09/12 10:24 A.M.
呵呵,在打入vi命令的时候是不是感觉很不顺手(当然不包括那种“变态”人种),这就要用到vim中强大的键映射了。且看:
" let mapleader="," let g:mapleader="," "两个键映射 nmap <leader>w :w<cr> nmap <leader>q :wq<cr>
哈哈,这样,就可以 用",w", ",q" 来快速保存了。 |
2009/09/10 10:57 P.M.
确实,这几天的痛苦可谓深痛,面对着将近一千多行的js不规整代码,徒然汗下。确实没有想到我所接到的代码是那么完成的,在我的意识里对js还是相当崇拜的,但是看到那一千行代码后我感触良多,也许应该说是尽显js开发网站之本质吧,呵呵。每行代码,每一个时间都在哪儿调函数,每一个时间几乎要调用好几个函数才能完成,其逻辑也是相当不确定。但是很庆幸,我终于搞定了我的测试,我看完了几乎以前的代码,就如我负责的那块本来是没有工作量的,但是看来估计是错的,以前的代码几乎不可用。感慨万千……,重写,还是修改?最后在没有人给 |
2009/09/06 04:17 P.M.
Examples:
SELECT * FROM `your_table` LIMIT 0, 10
This will display the first 10 results from the database.
SELECT * FROM `your_table` LIMIT 5, 5
This will show records 6, 7, 8, 9, and 10
|
|
|
|