06 2013 档案
摘要:有个网友问了个问题,如下的html,为什么每次输出都是5闭包演示产品一产品一产品一产品一产品一原因:尽管是多个实例,但它们仍然共享一个外层函数闭包(lv1)中的i值,所以取决于最后一个i的值5。解决方式有很多,1、将变量 i 保存给在每个段落对象(p)上function init() { var pAry = document.getElementsByTagName("p"); for( var i=0; i<pAry.length; i++ ) { pAry[i].i = i; pAry[i].onclick = function() { alert(this.i
阅读全文
摘要:安装完php之后,通常情况下,会在网站目录下创建一个.php的文件,来查看php安装过程中的参数配置,脚本的内容很简单:通常情况下,如果能顺利安装下来不报错的话,这个页面肯定是可以看到的;下面是我PHP配置参数的局部截图, 从我这边的配置可以看到,php的配置文件应该是放在/usr/local/php/etc下面,但是在这个目录下面并没有php.ini这个配置文件,需要手动的拷贝一个模板。我是实用源代码安装的,所以,在模板文件在源码包目录下!我安装的是php 5.3.4,在源码包里看到php.ini-development 和php.ini-production两个模板配置文件,这是针对不同的
阅读全文
摘要:1.假设已经有mysql-5.5.10.tar.gz以及cmake-2.8.4.tar.gz两个源文件(1)先安装cmake(mysql5.5以后是通过cmake来编译的)[root@ rhel5 local]#tar -zxv -f cmake-2.8.4.tar.gz[root@ rhel5 local]#cd cmake-2.8.4[root@ rhel5 cmake-2.8.4]#./configure[root@ rhel5 cmake-2.8.4]#make[root@ rhel5 cmake-2.8.4]#make install(2)创建mysql的安装目录及数据库存放目录[r
阅读全文
摘要:1.获取安装文件:http://www.php.net/downloads.php php-5.3.8.tar.gz 获取安装php需要的支持文件:http://download.csdn.net/download/netlong339/1351852 libxml2-2.6.32.tar.gz2.安装libxml21 tar zxvf libxml2-2.6.32.tar.gz 2 cd libxml2-2.6.323 ./configure --prefix=/usr/local/libxml2 4 make5 make install如果安装成功以后,在/usr/local/libxml
阅读全文
摘要:1.获取软件:http://httpd.apache.org/ httpd-2.2.21.tar.gz2.安装步骤:解压源文件:1 tar zvxf httpd-2.2.21.tar.gz 2 cd httpd-2.2.213 ./configure --prefix=/usr/local/apache2 --enable-so --enable-rewrite 4 make5 make install运行./configure 命令进行编译源代码,--prefix=/usr/local/apach2 是设置编译安装到的系统目录,--enable-so 参数是使httpd服务能够动态加载模块功
阅读全文
摘要:Apache源码安装完毕后,1.下面的脚本运行后就可以直接使用service apachexxx stop/start 来控制apache的启动与停止了!cp /usr/local/apache/bin/apachectl /etc/rc.d/init.d/apachexxx //拷贝apache启动脚本2.下面的脚本运行后是可以使用chkconfig --addapachexxx 了!vi /etc/rc.d/init.d/apachexxx // 这里是编辑apache启动脚本 在开头的#!/bin/sh 下面加上 #chkconfig: 2345 85 15 //此处必须加 否则无法使.
阅读全文
摘要:Starting httpd: AH00558: httpd: Could not reliably determine the server's fully qualified domain name, using localhost.localdomain. Set the 'ServerName' directive globally to suppress this messageapache 启动出现这种错误的解决方法:将 apache 的配置文件中 ServerName 改成可用域名或如下配置ServerName localhost:80
阅读全文
摘要:不知道为什么在安装apache2.2.22版本的时候没有任何问题,直接使用命令./configure --prefix=/home/www/www_test/software/apache-2.2.22 --enable-proxy --enable-so --enable-mods-shared=most --with-mpm=worker没有任何问题,不过在安装新版本2.4.2的时候就会报错。解决方案如下:#./configure --prefix……检查编辑环境时出现:checking for APR... noconfigure: error: APR not found . Plea
阅读全文
摘要:点击进入更详细教程及源码下载 在线演示我们经常会在网站中看见一个时钟的效果。今天向大家分享一个使用jQuery和CSS3实现一个数字时钟教程。http://www.html5cn.org/article-5279-1.html代码:<div id="clock" class="light"> <div class="display"> <div class="weekdays"></div> <div class="ampm"><
阅读全文