PHP 与 JS 的另一种数据传递方式 序列化
从 PHP 3 开始为保存对象提供了一组序列化和反序列化的函数:serialize、unserialize,它可以方便的保存数据方便的做成CACHE,而存储体积也比XML要小的多,它结构与 JS 的 JSON 相拟,网上有一组用 JS 模拟 serialize 实现的方法,使用它可以和PHP 在数据传递上更紧密的结合.
JavaScript 版本(stable):http://www.devpro.it/code/102.html
Perl 版本(stable):http://hurring.com/code/perl/serialize/
另一个 Perl 版本:http://www.cpan.org/modules/by-module/PHP/JBROWN/php-serialization/
Python 版本(beta):http://hurring.com/code/python/serialize/
Java 版本(pre-alpha):http://hurring.com/code/java/serialize/
Ruby 版本:http://www.aagh.net/files/ruby/php_serialize.rb
Flash/Actionscript 版本: http://sourceforge.net/projects/serializerclass/
C# 版本:http://sourceforge.net/projects/csphpserial/
相关文档:
PHP循环语句的介绍与应用
1、break n 循环控制语句
Break 跳出一层(本次)循环;break n 跳出n层循环;
2.Continue:continue 在循环结构用用来跳过本次循环中剩余的代码并在条件求值为真时开始执行下一次循环。注:注意在 PHP 中 switch 语句被认为是可以使用 con ......
此文章的安装方法适用于Windows XP
下的Apache+PHP+MySQL
安装,同时也适用于Windows 2003
系统下的安装和配置。
1.
安装环境
操作系统是 Windows XP
中文版, Apache,
PHP, MySQL
的最新版本是截止到 2007.09.07
,分别在其官网下载的:
* Apache 2.2.6
:http://apache.mirror.phpchina.c ......
用php生成excel文件
<?
header("Content-type:application/vnd.ms-excel");
header("Content-Disposition:filename=test.xls");
echo "test1/t";
echo "test2/t/n";
echo "test1/t";
echo "test2/t/n";
echo "test1/t";
echo "test2/t/n";
echo "test1/t";
echo "test2/t/n";
echo "test1/t";
echo "test2 ......
1、嵌入方法:
类似ASP的<%,PHP可以是<?php或者是<?,结束符号是?>,当然您也可以自己指定。
2、引用文件:
引用文件的方法有两种:require 及 include。
require 的使用方法如 require("MyRequireFile.php"); 。这个函数通常放在 PHP 程序的最前面,PHP 程序在执行前,就会先读入 require 所指定引入 ......
作者:Ph4nt0m Security Team
来源:http://www.ph4nt0m.org-a.googlepages.com/PSTZine_0x03_0x06.txt
==Ph4nt0m Security Team==
Issue 0x03, Phile #0x06 of 0x07
|=---------------------------------------- ......