易截截图软件、单文件、免安装、纯绿色、仅160KB

Eclipse Debug PHP (关于ZendDebugger)的使用

Apache 版本: 2.2
PHP 版本:5.2.11
Eclipse下载地址:http://downloads.zend.com/pdt/all-in-one/zend-eclipse-php-galileo-SR1-win32-x86.zip
解压后运行Eclipse.exe
选择工作空间
我选择了E:\PHPworkspace
这时要插入一步
打开Apache的配置文件httpd.conf
查找”DocumentRoot“
修改documentroot的值
DocumentRoot "E:/PHPworkspace"
建立PHP项目
命名为"DebugPHP"
创建一个PHP文件:“debug.php”
写入代码如下:
<HTML>
<BODY>
<H1>Debug Demo</H1>
<table border="1" width="700">
<tr bgcolor="red">
<th>Name</th>
<th>Address</th>
<th>Phone</th>
</tr>
<?php
$db = array(
array ("John", "E 10th St., NYC, NY 23742", "(212) 555-4456"),
array ("Francois", "12 Bd. de Grenelle, Paris, 74897","(33) 433-544"),
array ("Klaus", "312 Beethoven St., Frankfurt, Germany", "(44) 332-8065"),
array ("Shirly", "72 Independence St., Tel Aviv, Israel 67283", "(972) 156-7777"),
array ("Bill", "127 Maine St., San Francisco, CA 90298", "(415) 555-6565")
);
/**
@return string
@param i int
@desc Returns 'white' for even numbers and 'yellow' for odd numbers
*/
function row_color($i)
{
$bgcolor1 = "white";
$bgcolor2 = "yellow";
if ( ($i % 2) == 0 ) {
return $bgcolor1;
} else {
return $bgcolor2;
}
}
/**
@return void
@desc Displays a table of the workers
*/
function display_workers()
{
global $db;
for ($i=0, $n=count($db); $i<$n; $i++) {
$worker_data = $db[$i];
$worker_name = $worker_data[0];
$worker_address = $worker_data[1];
$worker_phone = $worker_data[2];
print "<tr bgcolor=\"".row_color($i)."\">\n";
print "<td>$worker_name</td>\n";
print "<td>$worker_address</td>\n";


相关文档:

php数据库导出类 导出JSON,XML,WORD,EXCEL

from:http://www.xland.com.cn/article/7/81/0804/28778.htm
本类实现:
数据库信息导出:word,excel,json,xml,sql
数据库恢复:从sql,从文件
具体用法:
首先新建测试用数据库mytest,然后在里面建张表
PHP代码:
以下是代码片段:
--
-- 表的结构 `test`
--
CREATE TABLE `test` (
   `id ......

lighttpd + mysql + php(fast cgi)安装与配置

准备:
lighttpd-1.4.15.tar.gz
php-4.4.2.tar.gz
mysql-5.0.20a.tar.gz
开始:
1 编译安装lighttpd
 # tar zxvf lighttpd-1.4.15.tar.gz
 # cd lighttpd-1.4.15
 #  ls
 # ./configure --prefix=/usr/local/lighttpd    //此部无法编译时提示安装prce-devel
 #&nbs ......

php初学者

我也是一ASP转PHP的初学者,我这里有一好的网站拿来与大家一起分享,希望大家会喜欢!
http://www.w3school.com.cn/
也还有一些好的视频也拿来与大家一起分享!
http://hi.baidu.com/ylinuxs/blog/item/4433d3354a58fed1a2cc2b26.html ......

php中使用header函数的http头设置

/ ok
header('HTTP/1.1 200 OK');
//设置一个404头:
header('HTTP/1.1 404 Not Found');
//设置地址被永久的重定向
header('HTTP/1.1 301 Moved Permanently');
//转到一个新地址
header('Location: http://www.example.org/'
);
//文件延迟转向:
header('Refresh: 10; url=http://www.example.org/');
print 'Y ......

nginx + php + https 配置用例

#
启动服务的用户和组
user
lighttpd lighttpd;
#
开多少进程
worker_processes
2;
#
错误日志
error_log
/data/log/nginx/nginx_error/nginx_error.log crit;
#
pid
pid
        /var/run/nginx.pid;
#
Specifies
the value for maximum file descriptors t ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号