Index: /branches/beta/.project
===================================================================
--- /branches/beta/.project	(revision 13282)
+++ /branches/beta/.project	(revision 14676)
@@ -6,6 +6,12 @@
 	</projects>
 	<buildSpec>
-	</buildSpec>
-	<natures>
-	</natures>
+   <buildCommand>
+       <name>net.sourceforge.phpeclipse.parserbuilder</name>
+       <arguments>
+       </arguments>
+   </buildCommand>
+ </buildSpec>
+ <natures>
+   <nature>net.sourceforge.phpeclipse.phpnature</nature>
+ </natures>
 </projectDescription>
Index: /branches/beta/html/input_zip_json.php
===================================================================
--- /branches/beta/html/input_zip_json.php	(revision 14676)
+++ /branches/beta/html/input_zip_json.php	(revision 14676)
@@ -0,0 +1,60 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+
+require_once("./require.php");
+//header("Content-Type: text/json; charset=euc-jp");
+
+
+$conn = new SC_DBconn(ZIP_DSN);
+
+// ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+$arrErr = fnErrorCheck();
+
+// ÆþÎÏ¥¨¥é¡¼¤Î¾ì¹ç¤Ï½ªÎ»
+if(count($arrErr) == 0) {
+
+// Í¹ÊØÈÖ¹æ¸¡º÷Ê¸ºîÀ®
+$zipcode = $_GET['zip01'].$_GET['zip02'];
+$zipcode = mb_convert_kana($zipcode ,"n");
+$sqlse = "SELECT state, city, town FROM mtb_zip WHERE zipcode = ?";
+
+$data_list = $conn->getAll($sqlse, array($zipcode));
+
+// ¥¤¥ó¥Ç¥Ã¥¯¥¹¤ÈÃÍ¤òÈ¿Å¾¤µ¤»¤ë¡£
+$arrREV_PREF = array_flip($arrPref);
+$pref = $arrREV_PREF[$data_list[0]['state']];
+$city = $data_list[0]['city'];
+$town =  $data_list[0]['town'];
+/*
+	ÁíÌ³¾Ê¤«¤é¥À¥¦¥ó¥í¡¼¥É¤·¤¿¥Ç¡¼¥¿¤ò¤½¤Î¤Þ¤Þ¥¤¥ó¥Ý¡¼¥È¤¹¤ë¤È
+	°Ê²¼¤Î¤è¤¦¤ÊÊ¸»úÎó¤¬Æþ¤Ã¤Æ¤¤¤ë¤Î¤Ç	ÂÐºö¤¹¤ë¡£
+	¡¦¡Ê£±¢·£±£¹ÃúÌÜ¡Ë
+	¡¦°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç
+*/
+$town = ereg_replace("¡Ê.*¡Ë$","",$town);
+$town = ereg_replace("°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç","",$town);
+
+// Í¹ÊØÈÖ¹æ¤¬È¯¸«¤µ¤ì¤¿¾ì¹ç
+if(count($data_list[0]) > 0) {
+	echo "{'pref':'$pref','city':'$city','town':'$town','flag':'1'}" ;
+} else {
+    echo "{'flag' : '0'}" ;
+    }
+}
+/* ÆþÎÏ¥¨¥é¡¼¤Î¥Á¥§¥Ã¥¯ */
+function fnErrorCheck() {
+	// ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸ÇÛÎó¤Î½é´ü²½
+	$objErr = new SC_CheckError();
+	
+	// Í¹ÊØÈÖ¹æ
+	$objErr->doFunc( array("Í¹ÊØÈÖ¹æ1",'zip01',ZIP01_LEN ) ,array( "NUM_COUNT_CHECK" ) );
+	$objErr->doFunc( array("Í¹ÊØÈÖ¹æ2",'zip02',ZIP02_LEN ) ,array( "NUM_COUNT_CHECK" ) );
+	
+	return $objErr->arrErr;
+}
+
+?>
Index: /branches/beta/html/entry/index.php
===================================================================
--- /branches/beta/html/entry/index.php	(revision 12196)
+++ /branches/beta/html/entry/index.php	(revision 14676)
@@ -231,5 +231,4 @@
 		}
 		$arrRegist["status"] = "2";				// ËÜ²ñ°÷
-		$arrRegist["status"] = $arrInfo['welcome_point'];
 	}
 	
Index: /branches/beta/html/require.php
===================================================================
--- /branches/beta/html/require.php	(revision 12179)
+++ /branches/beta/html/require.php	(revision 14676)
@@ -5,9 +5,8 @@
  * http://www.lockon.co.jp/
  */
-
+ 
 $include_dir = realpath(dirname( __FILE__));
 require_once($include_dir . "/define.php");
-
-require_once($include_dir . HTML2DATA_DIR. "conf/conf.php");	
+require_once($include_dir . HTML2DATA_DIR. "conf/conf.php");
 require_once($include_dir . HTML2DATA_DIR . "include/module.inc");
 require_once($include_dir . HTML2DATA_DIR . "lib/glib.php");
Index: /branches/beta/html/products/detail.php
===================================================================
--- /branches/beta/html/products/detail.php	(revision 13583)
+++ /branches/beta/html/products/detail.php	(revision 14676)
@@ -190,5 +190,6 @@
 
 // ³ÈÂç²èÁü¤Î¥¦¥£¥ó¥É¥¦¥µ¥¤¥º¤ò¥»¥Ã¥È
-list($large_width, $large_height) = getimagesize(IMAGE_SAVE_DIR . basename($objPage->arrFile["main_large_image"]["filepath"]));
+$image_path = IMAGE_SAVE_DIR . basename($objPage->arrFile["main_large_image"]["filepath"]);
+list($large_width, $large_height) = getimagesize($image_path);
 $objPage->tpl_large_width = $large_width + 60;
 $objPage->tpl_large_height = $large_height + 80;
Index: /branches/beta/html/install/user_data/include/bloc/best5.tpl
===================================================================
--- /branches/beta/html/install/user_data/include/bloc/best5.tpl	(revision 17)
+++ /branches/beta/html/install/user_data/include/bloc/best5.tpl	(revision 14676)
@@ -19,5 +19,5 @@
 		<table width="190" border="0" cellspacing="0" cellpadding="0" summary=" ">
 			<tr valign="top">
-				<td align="center" valign="middle"><a href="<!--{$smarty.const.URL_DIR}-->products/detail.php?product_id=<!--{$arrBestProducts[cnt].product_id}-->"><img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[cnt].name|escape}-->"></a></td>
+				<td align="center" valign="middle"><a href="<!--{$smarty.const.URL_DIR}-->products/detail.php?product_id=<!--{$arrBestProducts[cnt].product_id}-->"><img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[cnt].name|escape}-->"></a></td>
 				<td align="right">
 				<table width="132" border="0" cellspacing="0" cellpadding="0" summary=" ">
@@ -51,5 +51,5 @@
 			<table width="190" border="0" cellspacing="0" cellpadding="0" summary=" ">
 				<tr valign="top">
-					<td align="center" valign="middle"><a href="<!--{$smarty.const.URL_DIR}-->products/detail.php?product_id=<!--{$arrBestProducts[$cnt2].product_id}-->"><img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[$cnt2].name|escape}-->"></a></td>
+					<td align="center" valign="middle"><a href="<!--{$smarty.const.URL_DIR}-->products/detail.php?product_id=<!--{$arrBestProducts[$cnt2].product_id}-->"><img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[$cnt2].name|escape}-->"></a></td>
 					<td align="right">
 					<table width="132" border="0" cellspacing="0" cellpadding="0" summary=" ">
Index: /branches/beta/html/install/user_data/include/campaign/default/src/index.php
===================================================================
--- /branches/beta/html/install/user_data/include/campaign/default/src/index.php	(revision 37)
+++ /branches/beta/html/install/user_data/include/campaign/default/src/index.php	(revision 14676)
@@ -73,5 +73,5 @@
 		}
 		$objCartSess->setPrevURL($_SERVER['REQUEST_URI']);
-		$objCartSess->addProduct(array($_POST['product_id'], $classcategory_id1, $classcategory_id2), $_POST[$quantity]);
+		$objCartSess->addProduct(array($_POST['product_id'], $classcategory_id1, $classcategory_id2), $_POST[$quantity], $campaign_id);
 		header("Location: " . URL_CART_TOP);
 		exit;
Index: /branches/beta/html/install/user_data/templates/detail.tpl
===================================================================
--- /branches/beta/html/install/user_data/templates/detail.tpl	(revision 11977)
+++ /branches/beta/html/install/user_data/templates/detail.tpl	(revision 14676)
@@ -382,5 +382,5 @@
 										<!--{assign var=image_path value="`$smarty.const.NO_IMAGE_DIR`"}-->
 									<!--{/if}-->
-									<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[cnt].name|escape}-->"></a></td>
+									<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[cnt].name|escape}-->"></a></td>
 									<td align="right">
 									<table width="145" border="0" cellspacing="0" cellpadding="0" summary=" ">
@@ -423,5 +423,5 @@
 										<!--{assign var=image_path value="`$smarty.const.NO_IMAGE_DIR`"}-->
 									<!--{/if}-->
-									<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[$nextCnt].name|escape}-->"></a></td>
+									<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[$nextCnt].name|escape}-->"></a></td>
 									<td align="right">
 									<table width="145" border="0" cellspacing="0" cellpadding="0" summary=" ">
Index: /branches/beta/html/install/user_data/templates/default1/templates/detail.tpl
===================================================================
--- /branches/beta/html/install/user_data/templates/default1/templates/detail.tpl	(revision 24)
+++ /branches/beta/html/install/user_data/templates/default1/templates/detail.tpl	(revision 14676)
@@ -345,5 +345,5 @@
 										<!--{assign var=image_path value="`$smarty.const.NO_IMAGE_DIR`"}-->
 									<!--{/if}-->
-									<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[cnt].name|escape}-->"></a></td>
+									<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[cnt].name|escape}-->"></a></td>
 									<td align="right">
 									<table width="145" border="0" cellspacing="0" cellpadding="0" summary=" ">
@@ -386,5 +386,5 @@
 										<!--{assign var=image_path value="`$smarty.const.NO_IMAGE_DIR`"}-->
 									<!--{/if}-->
-									<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[$nextCnt].name|escape}-->"></a></td>
+									<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=65&height=65" alt="<!--{$arrRecommend[$nextCnt].name|escape}-->"></a></td>
 									<td align="right">
 									<table width="145" border="0" cellspacing="0" cellpadding="0" summary=" ">
Index: /branches/beta/html/install/user_data/templates/default1/include/bloc/best5.tpl
===================================================================
--- /branches/beta/html/install/user_data/templates/default1/include/bloc/best5.tpl	(revision 17)
+++ /branches/beta/html/install/user_data/templates/default1/include/bloc/best5.tpl	(revision 14676)
@@ -19,5 +19,5 @@
 		<table width="190" border="0" cellspacing="0" cellpadding="0" summary=" ">
 			<tr valign="top">
-				<td align="center" valign="middle"><a href="<!--{$smarty.const.URL_DIR}-->products/detail.php?product_id=<!--{$arrBestProducts[cnt].product_id}-->"><img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[cnt].name|escape}-->"></a></td>
+				<td align="center" valign="middle"><a href="<!--{$smarty.const.URL_DIR}-->products/detail.php?product_id=<!--{$arrBestProducts[cnt].product_id}-->"><img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[cnt].name|escape}-->"></a></td>
 				<td align="right">
 				<table width="132" border="0" cellspacing="0" cellpadding="0" summary=" ">
@@ -51,5 +51,5 @@
 			<table width="190" border="0" cellspacing="0" cellpadding="0" summary=" ">
 				<tr valign="top">
-					<td align="center" valign="middle"><a href="./products/detail.php?product_id=<!--{$arrBestProducts[$cnt2].product_id}-->"><img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[$cnt2].name|escape}-->"></a></td>
+					<td align="center" valign="middle"><a href="./products/detail.php?product_id=<!--{$arrBestProducts[$cnt2].product_id}-->"><img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&width=48&height=48" alt="<!--{$arrBestProducts[$cnt2].name|escape}-->"></a></td>
 					<td align="right">
 					<table width="132" border="0" cellspacing="0" cellpadding="0" summary=" ">
Index: /branches/beta/html/install/index.php
===================================================================
--- /branches/beta/html/install/index.php	(revision 12318)
+++ /branches/beta/html/install/index.php	(revision 14676)
@@ -8,5 +8,4 @@
 $INSTALL_DIR = realpath(dirname( __FILE__));
 require_once("../" . HTML2DATA_DIR . "module/Request.php");
-
 define("INSTALL_LOG", "./temp/install.log");
 
@@ -20,5 +19,5 @@
 			'pgsql' => '',
 			'mysql' => ''	
-		);
+		);    
 	}
 }
@@ -110,5 +109,5 @@
 	$objPage->arrErr = lfAddTable("dtb_site_control", $dsn);	// ¥µ¥¤¥È¾ðÊó´ÉÍý¥Æ¡¼¥Ö¥ë
 	$objPage->arrErr = lfAddTable("dtb_trackback", $dsn);	// ¥È¥é¥Ã¥¯¥Ð¥Ã¥¯´ÉÍý¥Æ¡¼¥Ö¥ë
-	
+    $objPage->arrErr = lfAddTable("dtb_blayn", $dsn);   // ¥Ö¥ì¥¤¥óIP´ÉÍý¥Æ¡¼¥Ö¥ë	
 	
 	// ¥«¥é¥à¤òÄÉ²Ã
@@ -207,4 +206,5 @@
 	lfDropTable("dtb_site_control", $dsn);
 	lfDropTable("dtb_trackback", $dsn);
+    lfDropTable("dtb_blayn", $dsn);
 			
 	if ($arrRet['db_type'] == 'pgsql'){
@@ -410,4 +410,8 @@
 			mkdir($path);
 		}
+		$path = ".." . HTML2DATA_DIR . "Smarty/templates_c/mobile";
+		if(!file_exists($path)) {
+			mkdir($path); 
+		}
 		$path = "../upload/temp_template";
 		if(!file_exists($path)) {
@@ -824,35 +828,4 @@
 		fclose($fp);
 	}
-/* install_mobile.inc¤Ï»ÈÍÑ¤·¤Ê¤¤ÍÑ¤ËÊÑ¹¹
-
-	// ¥â¥Ð¥¤¥ëÈÇ¤ÎÀßÄê¥Õ¥¡¥¤¥ë install_mobile.inc ¤òºîÀ®¤¹¤ë¡£
-	$filepath = $data_path . "install_mobile.inc";
-	
-	$config_data = 
-	"<?php\n".
-	"    define ('ECCUBE_INSTALL', 'ON');\n" .
-	"    define ('HTML_PATH', '" . $root_dir . "mobile/');\n" .	 
-	"    define ('PC_HTML_PATH', '" . $root_dir . "');\n" .	 
-	"    define ('SITE_URL', '" . $normal_url . "mobile/');\n" .
-	"    define ('PC_SITE_URL', '" . $normal_url . "');\n" .
-	"    define ('SSL_URL', '" . $secure_url . "mobile/');\n" .
-	"    define ('PC_SSL_URL', '" . $secure_url . "');\n" .
-	"    define ('URL_DIR', '" . $url_dir . "mobile/');\n" .	
-	"    define ('PC_URL_DIR', '" . $url_dir . "');\n" .	
-	"    define ('DOMAIN_NAME', '" . $objWebParam->getValue('domain') . "');\n" .
-	"    define ('DB_TYPE', '" . $objDBParam->getValue('db_type') . "');\n" .
-	"    define ('DB_USER', '" . $objDBParam->getValue('db_user') . "');\n" . 
-	"    define ('DB_PASSWORD', '" . $objDBParam->getValue('db_password') . "');\n" .
-	"    define ('DB_SERVER', '" . $objDBParam->getValue('db_server') . "');\n" .
-	"    define ('DB_NAME', '" . $objDBParam->getValue('db_name') . "');\n" .
-	"    define ('DB_PORT', '" . $objDBParam->getValue('db_port') .  "');\n" .
-	"    define ('DATA_PATH', '".$data_path."');\n" .
-	"?>";
-	
-	if($fp = fopen($filepath,"w")) {
-		fwrite($fp, $config_data);
-		fclose($fp);
-	}
-*/
 }
 
Index: /branches/beta/html/install/sql/column_comment.sql
===================================================================
--- /branches/beta/html/install/sql/column_comment.sql	(revision 12153)
+++ /branches/beta/html/install/sql/column_comment.sql	(revision 14676)
@@ -90,4 +90,5 @@
 INSERT INTO dtb_table_comment(table_name,column_name,description) values ('dtb_mailtemplate','header','¥Ø¥Ã¥À¡¼Ê¸½ñ');
 INSERT INTO dtb_table_comment(table_name,column_name,description) values ('dtb_mailtemplate','footer','¥Õ¥Ã¥¿¡¼Ê¸½ñ');
+INSERT INTO dtb_table_comment(table_name,column_name,description) values ('dtb_mailtemplate','body','ËÜÊ¸Ê¸½ñ');
 INSERT INTO dtb_table_comment(table_name,column_name,description) values ('dtb_mailtemplate','creator_id','ºîÀ®¤·¤¿´ÉÍý¼ÔID');
 INSERT INTO dtb_table_comment(table_name,column_name,description) values ('dtb_mailtemplate','del_flg','0:´ûÄê¡¢1:ºï½ü');
Index: /branches/beta/html/install/sql/create_table_mysql.sql
===================================================================
--- /branches/beta/html/install/sql/create_table_mysql.sql	(revision 13629)
+++ /branches/beta/html/install/sql/create_table_mysql.sql	(revision 14676)
@@ -181,4 +181,7 @@
     header text,
     footer text,
+    body   text,
+    send_type int,
+    template_name text,
     creator_id int NOT NULL,
     del_flg smallint NOT NULL DEFAULT 0,
Index: /branches/beta/html/install/sql/create_table_pgsql.sql
===================================================================
--- /branches/beta/html/install/sql/create_table_pgsql.sql	(revision 11731)
+++ /branches/beta/html/install/sql/create_table_pgsql.sql	(revision 14676)
@@ -181,4 +181,7 @@
     header text,
     footer text,
+    body   text,
+    send_type   int2,
+    template_name text,
     creator_id int4 NOT NULL,
     del_flg int2 NOT NULL DEFAULT 0,
Index: /branches/beta/html/install/sql/add/dtb_blayn_pgsql.sql
===================================================================
--- /branches/beta/html/install/sql/add/dtb_blayn_pgsql.sql	(revision 14676)
+++ /branches/beta/html/install/sql/add/dtb_blayn_pgsql.sql	(revision 14676)
@@ -0,0 +1,3 @@
+CREATE TABLE dtb_blayn (
+    blayn_ip text
+);
Index: /branches/beta/html/install/sql/add/dtb_blayn_mysql.sql
===================================================================
--- /branches/beta/html/install/sql/add/dtb_blayn_mysql.sql	(revision 14676)
+++ /branches/beta/html/install/sql/add/dtb_blayn_mysql.sql	(revision 14676)
@@ -0,0 +1,3 @@
+CREATE TABLE dtb_blayn (
+    blayn_ip text
+) TYPE=InnoDB;
Index: /branches/beta/html/install/sql/insert_data.sql
===================================================================
--- /branches/beta/html/install/sql/insert_data.sql	(revision 11769)
+++ /branches/beta/html/install/sql/insert_data.sql	(revision 14676)
@@ -220,15 +220,13 @@
 INSERT INTO dtb_templates (template_code, template_name, create_date, update_date) VALUES('default1','¥Ç¥Õ¥©¥ë¥È1', now(), now());
 
-insert into dtb_mailtemplate (template_id, subject, header, footer, creator_id, update_date, create_date) values (
-1,
+insert into dtb_mailtemplate (template_id, subject, body, creator_id, update_date, create_date, send_type, template_name) values (
+0,
 '¤´ÃíÊ¸¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤¹¡£',
-'¤³¤ÎÅÙ¤Ï¤´ÃíÊ¸¤¤¤¿¤À¤­À¿¤ËÍ­Æñ¤¦¤´¤¶¤¤¤Þ¤¹¡£
+'{name}ÍÍ
+
+¤³¤ÎÅÙ¤Ï¤´ÃíÊ¸¤¤¤¿¤À¤­À¿¤ËÍ­Æñ¤¦¤´¤¶¤¤¤Þ¤¹¡£
 ²¼µ­¤´ÃíÊ¸ÆâÍÆ¤Ë¤ª´Ö°ã¤¨¤¬¤Ê¤¤¤«¤´³ÎÇ§²¼¤µ¤¤¡£
 
-',
-'
-
-==============================================================¡ù
-
+{order}
 
 ¤³¤Î¥á¥Ã¥»¡¼¥¸¤Ï¤ªµÒÍÍ¤Ø¤Î¤ªÃÎ¤é¤»ÀìÍÑ¤Ç¤¹¤Î¤Ç¡¢
@@ -236,8 +234,31 @@
 ¤´Î»¾µ¤¯¤À¤µ¤¤¡£
 
-¤´¼ÁÌä¤ä¤´ÉÔÌÀ¤ÊÅÀ¤¬¤´¤¶¤¤¤Þ¤·¤¿¤é¡¢¤³¤Á¤é¤«¤é¤ª´ê¤¤¤¤¤¿¤·¤Þ¤¹¡£
-http://------.co.jp
-
-',0,Now(), now());
+¤´¼ÁÌä¤ä¤´ÉÔÌÀ¤ÊÅÀ¤¬¤´¤¶¤¤¤Þ¤·¤¿¤é¡¢¤³¤Á¤é¤«¤é¤ª´ê¤¤¤¤¤¿¤·¤Þ¤¹¡£',
+0,
+Now(),
+Now(),
+0,
+'¼õÃí´°Î»¥Æ¥ó¥×¥ì¡¼¥È(PCÍÑ)');
+
+insert into dtb_mailtemplate (template_id, subject, body, creator_id, update_date, create_date, send_type, template_name) values (
+1,
+'¤´ÃíÊ¸¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤¹¡£',
+'{name}ÍÍ
+
+¤³¤ÎÅÙ¤Ï¤´ÃíÊ¸¤¤¤¿¤À¤­À¿¤ËÍ­Æñ¤¦¤´¤¶¤¤¤Þ¤¹¡£
+²¼µ­¤´ÃíÊ¸ÆâÍÆ¤Ë¤ª´Ö°ã¤¨¤¬¤Ê¤¤¤«¤´³ÎÇ§²¼¤µ¤¤¡£
+
+{order}
+
+¤³¤Î¥á¥Ã¥»¡¼¥¸¤Ï¤ªµÒÍÍ¤Ø¤Î¤ªÃÎ¤é¤»ÀìÍÑ¤Ç¤¹¤Î¤Ç¡¢
+¤³¤Î¥á¥Ã¥»¡¼¥¸¤Ø¤ÎÊÖ¿®¤È¤·¤Æ¤´¼ÁÌä¤ò¤ªÁ÷¤ê¤¤¤¿¤À¤¤¤Æ¤â²óÅú¤Ç¤­¤Þ¤»¤ó¡£
+¤´Î»¾µ¤¯¤À¤µ¤¤¡£
+
+¤´¼ÁÌä¤ä¤´ÉÔÌÀ¤ÊÅÀ¤¬¤´¤¶¤¤¤Þ¤·¤¿¤é¡¢¤³¤Á¤é¤«¤é¤ª´ê¤¤¤¤¤¿¤·¤Þ¤¹¡£',
+0,
+Now(),
+Now(),
+1,
+'¼õÃí´°Î»¥Æ¥ó¥×¥ì¡¼¥È(·ÈÂÓÍÑ)');
 
 insert into dtb_news (news_date,rank, news_title, news_comment, creator_id, create_date, update_date) 
Index: /branches/beta/html/tb/index.php
===================================================================
--- /branches/beta/html/tb/index.php	(revision 14326)
+++ /branches/beta/html/tb/index.php	(revision 14676)
@@ -180,5 +180,10 @@
 	$arrData["create_date"] = "now()";
 	$arrData["update_date"] = "now()";
-
+    
+    if(!isset($arrData['url'])){
+        $arrData['url'] = '';
+    }elseif(!isset($arrData['excerpt'])){
+        $arrData['excerpt'] = '';
+    }
     if(!isset($arrData['url'])){
         $arrData['url'] = '';
Index: /branches/beta/html/mobile/products/payment.php
===================================================================
--- /branches/beta/html/mobile/products/payment.php	(revision 14676)
+++ /branches/beta/html/mobile/products/payment.php	(revision 14676)
@@ -0,0 +1,372 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+	var $arrSession;
+	var $tpl_mode;
+	function LC_Page() {
+		$this->tpl_css = '/css/layout/shopping/pay.css';
+		$this->tpl_mainpage = 'nonmember/payment.tpl';
+		$this->tpl_onload = 'fnCheckInputPoint();';
+		$this->tpl_title = "¤ª»ÙÊ§ÊýË¡¤Î»ØÄê";
+		/*
+		 session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+		 ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+		 private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+		*/
+		session_cache_limiter('private-no-expire');		
+	}
+}
+
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objCustomer = new SC_Customer();
+$objSiteInfo = $objView->objSiteInfo;
+$arrInfo = $objSiteInfo->data;
+
+// ¥Ñ¥é¥á¡¼¥¿´ÉÍý¥¯¥é¥¹
+$objFormParam = new SC_FormParam();
+// ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+lfInitParam();
+// POSTÃÍ¤Î¼èÆÀ
+$objFormParam->setParam($_POST);
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+// ¥æ¥Ë¡¼¥¯ID¤ò°ú¤­·Ñ¤°
+$objPage->tpl_uniqid = $uniqid;
+
+// ²ñ°÷¥í¥°¥¤¥ó¥Á¥§¥Ã¥¯
+if($objCustomer->isLoginSuccess()) {
+	$objPage->tpl_login = '1';
+	$objPage->tpl_user_point = $objCustomer->getValue('point');
+}
+
+// ¶â³Û¤Î¼èÆÀ (¹ØÆþÅÓÃæ¤ÇÇä¤êÀÚ¤ì¤¿¾ì¹ç¤Ë¤Ï¤³¤Î´Ø¿ôÆâ¤Ë¤Æ¤½¤Î¾¦ÉÊ¤Î¸Ä¿ô¤¬£°¤Ë¤Ê¤ë)
+$objPage = sfTotalCart($objPage, $objCartSess, $arrInfo);
+$objPage->arrData = sfTotalConfirm($arrData, $objPage, $objCartSess, $arrInfo);
+
+// ¥«¡¼ÅÔÆâ¤Î¾¦ÉÊ¤ÎÇä¤êÀÚ¤ì¥Á¥§¥Ã¥¯
+$objCartSess->chkSoldOut($objCartSess->getCartList(), true);
+
+// Ìá¤ë¥Ü¥¿¥ó¤Î½èÍý
+if (!empty($_POST['return'])) {
+	switch ($_POST['mode']) {
+	case 'confirm':
+		$_POST['mode'] = 'payment';
+		break;
+	default:
+		// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+		$objSiteSess->setRegistFlag();
+		//header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_TOP));
+        header("Location: " . gfAddSessionId('index.php'));
+		exit;
+	}
+}
+switch($_POST['mode']) {
+// »ÙÊ§¤¤ÊýË¡»ØÄê ¢ª ÇÛÃ£Æü»þ»ØÄê
+case 'deliv_date':
+	
+    // ÆþÎÏÃÍ¤ÎÊÑ´¹
+	$objFormParam->convParam();
+	$objPage->arrErr = lfCheckError($objPage->arrData);
+	if (!isset($objPage->arrErr['payment_id'])) {
+		// »ÙÊ§¤¤ÊýË¡¤ÎÆþÎÏ¥¨¥é¡¼¤Ê¤·
+		$objPage->tpl_mainpage = 'nonmember/deliv_date.tpl';
+		$objPage->tpl_title = "ÇÛÃ£Æü»þ»ØÄê";
+		break;
+	} else {
+		// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+		$uniqid = $objSiteSess->getUniqId();
+		// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+		lfSetOrderTempData($uniqid);
+	}
+	break;
+case 'confirm':
+	// ÆþÎÏÃÍ¤ÎÊÑ´¹
+	$objFormParam->convParam();
+	$objPage->arrErr = lfCheckError($objPage->arrData );
+	// ÆþÎÏ¥¨¥é¡¼¤Ê¤·
+	if(count($objPage->arrErr) == 0) {
+		// DB¤Ø¤Î¥Ç¡¼¥¿ÅÐÏ¿
+		lfRegistData($uniqid);
+		// Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+		$objSiteSess->setRegistFlag();
+		// ³ÎÇ§¥Ú¡¼¥¸¤Ø°ÜÆ°
+		//header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_CONFIRM));
+        header("Location: " . gfAddSessionId('./confirm.php'));
+		exit;
+	}else{
+		// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+		$uniqid = $objSiteSess->getUniqId();
+		// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+		lfSetOrderTempData($uniqid);
+		if (!isset($objPage->arrErr['payment_id'])) {
+			// »ÙÊ§¤¤ÊýË¡¤ÎÆþÎÏ¥¨¥é¡¼¤Ê¤·
+			$objPage->tpl_mainpage = 'nonmember/deliv_date.tpl';
+			$objPage->tpl_title = "ÇÛÃ£Æü»þ»ØÄê";
+		}
+	}
+	break;
+// Á°¤Î¥Ú¡¼¥¸¤ËÌá¤ë
+case 'return':
+	// Èó²ñ°÷¤Î¾ì¹ç
+	// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+	$objSiteSess->setRegistFlag();
+	header("Location: " . gfAddSessionId('index.php'));
+	exit;
+	break;
+// »ÙÊ§¤¤ÊýË¡¤¬ÊÑ¹¹¤µ¤ì¤¿¾ì¹ç
+case 'payment':
+	// ¤³¤³¤Îbreak¤Ï¡¢°ÕÌ£¤¬¤¢¤ë¤Î¤Ç³°¤µ¤Ê¤¤¤Ç²¼¤µ¤¤¡£
+	break;
+default:
+	// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+	lfSetOrderTempData($uniqid);
+	break;
+}
+
+// Å¹ÊÞ¾ðÊó¤Î¼èÆÀ
+$arrInfo = $objSiteInfo->data;
+// ¹ØÆþ¶â³Û¤Î¼èÆÀÆÀ
+$total_pretax = $objCartSess->getAllProductsTotal($arrInfo);
+// »ÙÊ§¤¤ÊýË¡¤Î¼èÆÀ
+$objPage->arrPayment = lfGetPayment($total_pretax);
+// ÇÛÁ÷»þ´Ö¤Î¼èÆÀ
+$arrRet = sfGetDelivTime($objFormParam->getValue('payment_id'));
+$objPage->arrDelivTime = sfArrKeyValue($arrRet, 'time_id', 'deliv_time');
+$objPage->objCustomer = $objCustomer;
+//¡¡ÇÛÁ÷Æü°ìÍ÷¤Î¼èÆÀ
+$objPage->arrDelivDate = lfGetDelivDate();
+
+$objPage->arrForm = $objFormParam->getFormParamList();
+
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+//--------------------------------------------------------------------------------------------------------------------------
+/* ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½ */
+function lfInitParam() {
+	global $objFormParam;
+	$objFormParam->addParam("¤ª»ÙÊ§¤¤ÊýË¡", "payment_id", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+	$objFormParam->addParam("¥Ý¥¤¥ó¥È", "use_point", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK", "ZERO_START"));
+	$objFormParam->addParam("ÇÛÃ£»þ´Ö", "deliv_time_id", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+	$objFormParam->addParam("¤´¼ÁÌä", "message", LTEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+	$objFormParam->addParam("¥Ý¥¤¥ó¥È¤ò»ÈÍÑ¤¹¤ë", "point_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), '2');
+	$objFormParam->addParam("ÇÛÃ£Æü", "deliv_date", STEXT_LEN, "KVa", array("MAX_LENGTH_CHECK"));
+}
+
+function lfGetPayment($total_pretax) {
+	$objQuery = new SC_Query();
+	$objQuery->setorder("rank DESC");
+	//ºï½ü¤µ¤ì¤Æ¤¤¤Ê¤¤»ÙÊ§ÊýË¡¤ò¼èÆÀ
+	$arrRet = $objQuery->select("payment_id, payment_method, rule, upper_rule, note, payment_image", "dtb_payment", "del_flg = 0 AND deliv_id IN (SELECT deliv_id FROM dtb_deliv WHERE del_flg = 0) ");
+	//ÍøÍÑ¾ò·ï¤«¤é»ÙÊ§²ÄÇ½ÊýË¡¤òÈ½Äê
+	foreach($arrRet as $data) {
+		//²¼¸Â¤È¾å¸Â¤¬ÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		if($data['rule'] > 0 && $data['upper_rule'] > 0) {
+			if($data['rule'] <= $total_pretax && $data['upper_rule'] >= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//²¼¸Â¤Î¤ßÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		} elseif($data['rule'] > 0) {	
+			if($data['rule'] <= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//¾å¸Â¤Î¤ßÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		} elseif($data['upper_rule'] > 0) {
+			if($data['upper_rule'] >= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//ÀßÄê¤Ê¤·
+		} else {
+			$arrPayment[] = $data;
+		}	
+	}
+	return $arrPayment;	
+}
+
+/* ÆþÎÏÆâÍÆ¤Î¥Á¥§¥Ã¥¯ */
+function lfCheckError($arrData) {
+	global $objFormParam;
+	global $objCustomer;
+	// ÆþÎÏ¥Ç¡¼¥¿¤òÅÏ¤¹¡£
+	$arrRet =  $objFormParam->getHashArray();
+	$objErr = new SC_CheckError($arrRet);
+	$objErr->arrErr = $objFormParam->checkError();
+	
+	if($_POST['point_check'] == '1') {
+		$objErr->doFunc(array("¥Ý¥¤¥ó¥È¤ò»ÈÍÑ¤¹¤ë", "point_check"), array("EXIST_CHECK"));
+		$objErr->doFunc(array("¥Ý¥¤¥ó¥È", "use_point"), array("EXIST_CHECK"));
+		$max_point = $objCustomer->getValue('point');
+		if($max_point == "") {
+			$max_point = 0;
+		}
+		if($arrRet['use_point'] > $max_point) {
+			$objErr->arrErr['use_point'] = "¢¨ ¤´ÍøÍÑ¥Ý¥¤¥ó¥È¤¬½ê»ý¥Ý¥¤¥ó¥È¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£<br>";
+		}
+		if(($arrRet['use_point'] * POINT_VALUE) > $arrData['subtotal']) {
+			$objErr->arrErr['use_point'] = "¢¨ ¤´ÍøÍÑ¥Ý¥¤¥ó¥È¤¬¤´¹ØÆþ¶â³Û¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£<br>";
+		}
+	}
+	return $objErr->arrErr;
+}
+
+/* »ÙÊ§¤¤ÊýË¡Ê¸»úÎó¤Î¼èÆÀ */
+function lfGetPaymentInfo($payment_id) {
+	$objQuery = new SC_Query();
+	$where = "payment_id = ?";
+	$arrRet = $objQuery->select("payment_method, charge", "dtb_payment", $where, array($payment_id));
+	return (array($arrRet[0]['payment_method'], $arrRet[0]['charge']));
+}
+
+/* ÇÛÁ÷»þ´ÖÊ¸»úÎó¤Î¼èÆÀ */
+function lfGetDelivTimeInfo($time_id) {
+	$objQuery = new SC_Query();
+	$where = "time_id = ?";
+	$arrRet = $objQuery->select("deliv_id, deliv_time", "dtb_delivtime", $where, array($time_id));
+	return (array($arrRet[0]['deliv_id'], $arrRet[0]['deliv_time']));
+}
+
+/* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
+function lfRegistData($uniqid) {
+	global $objFormParam;
+	$arrRet = $objFormParam->getHashArray();
+	$sqlval = $objFormParam->getDbArray();
+	// ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+	$sqlval['order_temp_id'] = $uniqid;
+	$sqlval['update_date'] = 'Now()';
+	
+	if($sqlval['payment_id'] != "") {
+		list($sqlval['payment_method'], $sqlval['charge']) = lfGetPaymentInfo($sqlval['payment_id']);
+	} else {
+		$sqlval['payment_id'] = '0';
+		$sqlval['payment_method'] = "";
+	}
+	
+	if($sqlval['deliv_time_id'] != "") {
+		list($sqlval['deliv_id'], $sqlval['deliv_time']) = lfGetDelivTimeInfo($sqlval['deliv_time_id']);
+	} else {
+		$sqlval['deliv_time_id'] = '0';
+		$sqlval['deliv_id'] = '0';
+		$sqlval['deliv_time'] = "";
+	}
+	
+	// »ÈÍÑ¥Ý¥¤¥ó¥È¤ÎÀßÄê
+	if($sqlval['point_check'] != '1') {
+		$sqlval['use_point'] = 0;
+	}
+	
+	sfRegistTempOrder($uniqid, $sqlval);
+}
+
+/* ÇÛÃ£Æü°ìÍ÷¤ò¼èÆÀ¤¹¤ë */
+function lfGetDelivDate() {
+	$objCartSess = new SC_CartSession();
+	$objQuery = new SC_Query();
+	// ¾¦ÉÊID¤Î¼èÆÀ
+	$max = $objCartSess->getMax();
+	for($i = 1; $i <= $max; $i++) {
+		if($_SESSION[$objCartSess->key][$i]['id'][0] != "") {
+			$arrID['product_id'][$i] = $_SESSION[$objCartSess->key][$i]['id'][0];
+		}
+	}
+	if(count($arrID['product_id']) > 0) {
+		$id = implode(",", $arrID['product_id']);
+		//¾¦ÉÊ¤«¤éÈ¯Á÷ÌÜ°Â¤Î¼èÆÀ
+		$deliv_date = $objQuery->get("dtb_products", "MAX(deliv_date_id)", "product_id IN (".$id.")");
+		//È¯Á÷ÌÜ°Â
+		switch($deliv_date) {
+		//Â¨ÆüÈ¯Á÷
+		case '1':
+			$start_day = 1;
+			break;
+		//1-2Æü¸å
+		case '2':
+			$start_day = 3;
+			break;
+		//3-4Æü¸å
+		case '3':
+			$start_day = 5;
+			break;
+		//1½µ´Ö°ÊÆâ
+		case '4':
+			$start_day = 8;
+			break;
+		//2½µ´Ö°ÊÆâ
+		case '5':
+			$start_day = 15;
+			break;
+		//3½µ´Ö°ÊÆâ
+		case '6':
+			$start_day = 22;
+			break;
+		//1¥ö·î°ÊÆâ
+		case '7':
+			$start_day = 32;
+			break;
+		//2¥ö·î°Ê¹ß
+		case '8':
+			$start_day = 62;			
+			break;
+		//¤ª¼è¤ê´ó¤»(¾¦ÉÊÆþ²Ù¸å)
+		case '9':
+			$start_day = "";
+			break;
+		default:
+			//¤ªÆÏ¤±Æü¤¬ÀßÄê¤µ¤ì¤Æ¤¤¤Ê¤¤¾ì¹ç
+			$start_day = "";
+			break;
+		}
+		//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤«¤é¡¢ÇÛÃ£Æü¤ÎÇÛÎó¤ò¼èÆÀ¤¹¤ë
+		$arrDelivDate = lfGetDateArray($start_day, DELIV_DATE_END_MAX);
+	}
+	return $arrDelivDate;
+}
+
+//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤«¤é¡¢ÇÛÃ£Æü¤ÎÇÛÎó¤ò¼èÆÀ¤¹¤ë
+function lfGetDateArray($start_day, $end_day) {
+	global $arrWDAY;
+	//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤¬¥»¥Ã¥È¤µ¤ì¤Æ¤¤¤ì¤Ð
+	if($start_day >= 1) {
+		$now_time = time();
+		$max_day = $start_day + $end_day;
+		// ½¸·×
+		for ($i = $start_day; $i < $max_day; $i++) {
+			// ´ðËÜ»þ´Ö¤«¤éÆü¿ô¤òÄÉ²Ã¤·¤Æ¤¤¤¯
+			$tmp_time = $now_time + ($i * 24 * 3600);
+			list($y, $m, $d, $w) = split(" ", date("y m d w", $tmp_time));	
+			$val = sprintf("%02d/%02d/%02d(%s)", $y, $m, $d, $arrWDAY[$w]);
+			$arrDate[$val] = $val;
+		}
+	} else {
+		$arrDate = false;
+	}
+	return $arrDate;
+}
+
+//°ì»þ¼õÃí¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼¤¹¤ë
+function lfSetOrderTempData($uniqid) {
+	global $objQuery;
+	global $objFormParam;
+	
+	$objQuery = new SC_Query();
+	$col = "payment_id, use_point, deliv_time_id, message, point_check, deliv_date";
+	$from = "dtb_order_temp";
+	$where = "order_temp_id = ?";
+	$arrRet = $objQuery->select($col, $from, $where, array($uniqid));
+	// DBÃÍ¤Î¼èÆÀ
+	$objFormParam->setParam($arrRet[0]);
+	return $objFormParam;
+}
+
+
+?>
Index: /branches/beta/html/mobile/nonmember/confirm.php
===================================================================
--- /branches/beta/html/mobile/nonmember/confirm.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/confirm.php	(revision 14676)
@@ -0,0 +1,123 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+	var $arrSession;
+	var $tpl_mode;
+	var $tpl_total_deliv_fee;
+	function LC_Page() {
+		$this->tpl_mainpage = 'nonmember/confirm.tpl';
+		$this->tpl_css = '/css/layout/shopping/confirm.css';
+		$this->tpl_title = "¤´ÆþÎÏÆâÍÆ¤Î¤´³ÎÇ§";
+		global $arrPref;
+		$this->arrPref = $arrPref;
+		global $arrSex;
+		$this->arrSex = $arrSex;
+		global $arrMAILMAGATYPE;
+		$this->arrMAILMAGATYPE = $arrMAILMAGATYPE;
+		global $arrReminder;
+		$this->arrReminder = $arrReminder;
+		/*
+		 session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+		 ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+		 private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+		*/
+		session_cache_limiter('private-no-expire');		
+
+	}
+}
+
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objCartSess = new SC_CartSession();
+$objSiteInfo = $objView->objSiteInfo;
+$objSiteSess = new SC_SiteSession();
+$objCustomer = new SC_Customer();
+$arrInfo = $objSiteInfo->data;
+$objQuery = new SC_Query();
+
+// Á°¤Î¥Ú¡¼¥¸¤ÇÀµ¤·¤¯ÅÐÏ¿¼êÂ³¤­¤¬¹Ô¤ï¤ì¤¿µ­Ï¿¤¬¤¢¤ë¤«È½Äê
+sfIsPrePage($objSiteSess, true);
+
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+$objPage->tpl_uniqid = $uniqid;
+
+// ¥«¡¼¥È½¸·×½èÍý
+$objPage = sfTotalCart($objPage, $objCartSess, $arrInfo);
+// °ì»þ¼õÃí¥Æ¡¼¥Ö¥ë¤ÎÆÉ¹þ
+$arrData = sfGetOrderTemp($uniqid);
+// ¥«¡¼¥È½¸·×¤ò¸µ¤ËºÇ½ª·×»»
+$arrData = sfTotalConfirm($arrData, $objPage, $objCartSess, $arrInfo, $objCustomer);
+
+// ¥«¡¼ÅÔÆâ¤Î¾¦ÉÊ¤ÎÇä¤êÀÚ¤ì¥Á¥§¥Ã¥¯
+$objCartSess->chkSoldOut($objCartSess->getCartList());
+
+// ²ñ°÷¥í¥°¥¤¥ó¥Á¥§¥Ã¥¯
+if($objCustomer->isLoginSuccess()) {
+	$objPage->tpl_login = '1';
+	$objPage->tpl_user_point = $objCustomer->getValue('point');
+}
+
+// ·èºÑ¶èÊ¬¤ò¼èÆÀ¤¹¤ë
+$payment_type = "";
+if(sfColumnExists("dtb_payment", "memo01")){
+	// MEMO03¤ËÃÍ¤¬Æþ¤Ã¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢¥â¥¸¥å¡¼¥ëÄÉ²Ã¤µ¤ì¤¿¤â¤Î¤È¤ß¤Ê¤¹
+	$sql = "SELECT memo03 FROM dtb_payment WHERE payment_id = ?";
+	$arrPayment = $objQuery->getall($sql, array($arrData['payment_id']));
+	$payment_type = $arrPayment[0]["memo03"];
+}
+$objPage->payment_type = $payment_type;
+
+
+switch($_POST['mode']) {
+// Á°¤Î¥Ú¡¼¥¸¤ËÌá¤ë
+case 'return':
+	// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+	$objSiteSess->setRegistFlag();
+	//header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_PAYMENT));
+    header("Location: " . gfAddSessionId('nonmember/payment.php'));
+    exit;
+	break;
+case 'confirm':
+	// ¤³¤Î»þÅÀ¤Ç¥ª¡¼¥À¡¼ID¤ò³ÎÊÝ¤·¤Æ¤ª¤¯¡Ê¥¯¥ì¥¸¥Ã¥È¡¢¥³¥ó¥Ó¥Ë·èºÑ¤ÇÉ¬Í×¤Ê¤¿¤á¡Ë
+	// postgresql¤Èmysql¤È¤Ç½èÍý¤òÊ¬¤±¤ë
+	if (DB_TYPE == "pgsql") {
+		$order_id = $objQuery->nextval("dtb_order","order_id");
+	}elseif (DB_TYPE == "mysql") {
+		$order_id = $objQuery->get_auto_increment("dtb_order");
+	}
+	$arrData["order_id"] = $order_id;
+	
+	// ½¸·×·ë²Ì¤ò¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤ËÈ¿±Ç
+	sfRegistTempOrder($uniqid, $arrData);
+	// Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+	$objSiteSess->setRegistFlag();
+	
+	// ·èºÑÊýË¡¤Ë¤è¤ê²èÌÌÀÚÂØ
+	if($payment_type != "") {
+		$_SESSION["payment_id"] = $arrData['payment_id'];
+		header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_MODULE));
+	}else{
+		header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_COMPLETE));
+	}
+	break;
+default:
+	break;
+}
+
+
+$objPage->arrData = $arrData;
+$objPage->arrInfo = $arrInfo;
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+//--------------------------------------------------------------------------------------------------------------------------
+?>
Index: /branches/beta/html/mobile/nonmember/deliv_addr.php
===================================================================
--- /branches/beta/html/mobile/nonmember/deliv_addr.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/deliv_addr.php	(revision 14676)
@@ -0,0 +1,323 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ * ÇÛÁ÷Àè¤ÎÄÉ²Ã
+ */
+require_once("../require.php");
+
+class LC_Page{
+	function LC_Page(){
+		$this->tpl_mainpage = 'nonmember/deliv_addr.tpl';
+		$this->tpl_title = "Â¾¤Î¤ªÆÏ¤±Àè¤ÎÅÐÏ¿";
+	}
+}
+
+$objPage = new LC_Page();
+$objView = new SC_MobileView(false);
+$objQuery = new SC_Query();
+$objCustomer = new SC_Customer();
+$objConn = new SC_DBConn();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+
+////¥í¥°¥¤¥óÈ½Äê
+//if (!$objCustomer->isLoginSuccess()){
+//	sfDispSiteError(CUSTOMER_ERROR, "", false, "", true);
+//}
+
+$objPage->arrForm = $_POST;
+$objPage->arrPref = $arrPref;
+
+//ÊÌ¤Î¤ªÆÏ¤±Àè£Ä£ÂÅÐÏ¿ÍÑ¥«¥é¥àÇÛÎó
+$arrRegistColumn = array(
+                             array(  "column" => "name01",      "convert" => "aKV" ),
+                             array(  "column" => "name02",      "convert" => "aKV" ),
+                             array(  "column" => "kana01",      "convert" => "CKV" ),
+                             array(  "column" => "kana02",      "convert" => "CKV" ),
+                             array(  "column" => "zip01",       "convert" => "n" ),
+                             array(  "column" => "zip02",       "convert" => "n" ),
+                             array(  "column" => "pref",        "convert" => "n" ),
+                             array(  "column" => "addr01",      "convert" => "aKV" ),
+                             array(  "column" => "addr02",      "convert" => "aKV" ),
+                             array(  "column" => "tel01",       "convert" => "n" ),
+                             array(  "column" => "tel02",       "convert" => "n" ),
+                             array(  "column" => "tel03",       "convert" => "n" ),
+                        );
+
+//-- ¥Ç¡¼¥¿ÀßÄê
+foreach($_POST as $key => $val) {
+	if ($key != "mode" && $key != "return" && $key != "submit" && $key != session_name()) {
+		$objPage->list_data[ $key ] = $val;
+	}
+}
+
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+
+                      
+ //-- ÆþÎÏ¥Ç¡¼¥¿¤ÎÊÑ´¹
+    $objPage->arrForm = lfConvertParam($objPage->arrForm, $arrRegistColumn);                        
+
+// Ìá¤ë¥Ü¥¿¥óÍÑ½èÍý
+if (!empty($_POST["return"])) {
+	switch ($_POST["mode"]) {
+	case 'complete':
+		$_POST["mode"] = "set2";
+		break;
+	case 'set2':
+		$_POST["mode"] = "set1";
+		break;
+	default:
+        
+		header("Location: " . gfAddSessionId('index.php'));
+		exit;
+	}
+}
+
+switch ($_POST['mode']){
+	case 'set1':
+		$objPage->arrErr = lfErrorCheck1($objPage->arrForm);
+		if (count($objPage->arrErr) == 0 && empty($_POST["return"])) {
+			$objPage->tpl_mainpage = 'nonmember/set1.tpl';
+
+			$checkVal = array("pref", "addr01", "addr02", "addr03", "tel01", "tel02", "tel03");
+			foreach($checkVal as $key) {
+				unset($objPage->list_data[$key]);
+			}
+
+			// Í¹ÊØÈÖ¹æ¤«¤é½»½ê¤Î¼èÆÀ
+			if (@$objPage->arrForm['pref'] == "" && @$objPage->arrForm['addr01'] == "" && @$objPage->arrForm['addr02'] == "") {
+				$address = lfGetAddress($_REQUEST['zip01'].$_REQUEST['zip02']);
+
+				$objPage->arrForm['pref'] = @$address[0]['state'];
+				$objPage->arrForm['addr01'] = @$address[0]['city'] . @$address[0]['town'];
+			}
+		} else {
+			$checkVal = array("name01", "name02", "kana01", "kana02", "zip01", "zip02");
+			foreach($checkVal as $key) {
+				unset($objPage->list_data[$key]);
+			}
+		}
+		break;
+	case 'set2':
+		$objPage->arrErr = lfErrorCheck2($objPage->arrForm);
+		if (count($objPage->arrErr) == 0 && empty($_POST["return"])) {
+			$objPage->tpl_mainpage = 'nonmember/set2.tpl';
+		} else {
+			$objPage->tpl_mainpage = 'nonmember/set1.tpl';
+
+			$checkVal = array("pref", "addr01", "addr02", "addr03", "tel01", "tel02", "tel03");
+			foreach($checkVal as $key) {
+				unset($objPage->list_data[$key]);
+			}
+		}
+		break;
+	case 'complete':
+		$objPage->arrErr = lfErrorCheck($objPage->arrForm);
+		if (count($objPage->arrErr) == 0) {
+            // ÅÐÏ¿
+			$other_deliv_id = lfRegistData($_POST,$arrRegistColumn,$uniqid);
+
+			// ÅÐÏ¿ºÑ¤ß¤ÎÊÌ¤Î¤ªÆÏ¤±Àè¤ò¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Ë½ñ¤­¹þ¤à
+			lfRegistOtherDelivData($uniqid, $objCustomer, $other_deliv_id);
+
+			// Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+			$objSiteSess->setRegistFlag();
+			// ¤ª»ÙÊ§¤¤ÊýË¡ÁªÂò¥Ú¡¼¥¸¤Ø°ÜÆ°
+			header("Location: " . gfAddSessionId('./payment.php'));
+			exit;
+		} else {
+			sfDispSiteError(CUSTOMER_ERROR, "", false, "", true);
+		}
+		break;
+	default:
+		$deliv_count = $objQuery->count("dtb_other_deliv", "customer_id=?", array($objCustomer->getValue('customer_id')));
+		if ($deliv_count >= DELIV_ADDR_MAX){
+			sfDispSiteError(FREE_ERROR_MSG, "", false, "ºÇÂçÅÐÏ¿·ï¿ô¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£");
+		}
+}
+
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+
+//-------------------------------------------------------------------------------------------------------------
+
+//----¡¡¼èÆÀÊ¸»úÎó¤ÎÊÑ´¹
+function lfConvertParam($array, $arrRegistColumn) {
+    /*
+     *  Ê¸»úÎó¤ÎÊÑ´¹
+     *  K :  ¡ÖÈ¾³Ñ(ÊÝ¶¸)ÊÒ²¾Ì¾¡×¤ò¡ÖÁ´³ÑÊÒ²¾Ì¾¡×¤ËÊÑ´¹
+     *  C :  ¡ÖÁ´³Ñ¤Ò¤é²¾Ì¾¡×¤ò¡ÖÁ´³Ñ¤«¤¿²¾Ì¾¡×¤ËÊÑ´¹
+     *  V :  ÂùÅÀÉÕ¤­¤ÎÊ¸»ú¤ò°ìÊ¸»ú¤ËÊÑ´¹¡£"K","H"¤È¶¦¤Ë»ÈÍÑ¤·¤Þ¤¹ 
+     *  n :  ¡ÖÁ´³Ñ¡×¿ô»ú¤ò¡ÖÈ¾³Ñ(ÊÝ¶¸)¡×¤ËÊÑ´¹
+     *  a :  Á´³Ñ±Ñ¿ô»ú¤òÈ¾³Ñ±Ñ¿ô»ú¤ËÊÑ´¹¤¹¤ë
+     */
+    // ¥«¥é¥àÌ¾¤È¥³¥ó¥Ð¡¼¥È¾ðÊó   
+    foreach ($arrRegistColumn as $data) {
+        $arrConvList[ $data["column"] ] = $data["convert"];
+    }
+    
+    // Ê¸»úÊÑ´¹
+    foreach ($arrConvList as $key => $val) {
+        // POST¤µ¤ì¤Æ¤­¤¿ÃÍ¤Î¤ßÊÑ´¹¤¹¤ë¡£
+        if(strlen(($array[$key])) > 0) {
+            $array[$key] = mb_convert_kana($array[$key] ,$val);
+        }
+    }
+    return $array;
+}
+
+/* ¥¨¥é¡¼¥Á¥§¥Ã¥¯ */
+function lfErrorCheck() {
+	$objErr = new SC_CheckError();
+	
+	$objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", 'name01', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", 'name02', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/À«¡Ë", 'kana01', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK", "MAX_LENGTH_CHECK", "KANA_CHECK"));
+	$objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/Ì¾¡Ë", 'kana02', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK", "MAX_LENGTH_CHECK", "KANA_CHECK"));
+	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "zip01", ZIP01_LEN ) ,array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "zip02", ZIP02_LEN ) ,array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK")); 
+	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "zip01", "zip02"), array("ALL_EXIST_CHECK"));
+	$objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", 'pref'), array("SELECT_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("»Ô¶èÄ®Â¼", "addr01", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("ÈÖÃÏ", "addr02", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", 'tel01'), array("EXIST_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", 'tel02'), array("EXIST_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", 'tel03'), array("EXIST_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ", "tel01", "tel02", "tel03", TEL_LEN) ,array("TEL_CHECK"));
+	return $objErr->arrErr;
+	
+}
+
+/* ¥¨¥é¡¼¥Á¥§¥Ã¥¯ */
+function lfErrorCheck1() {
+	$objErr = new SC_CheckError();
+	
+	$objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", 'name01', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", 'name02', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/À«¡Ë", 'kana01', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK", "MAX_LENGTH_CHECK", "KANA_CHECK"));
+	$objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/Ì¾¡Ë", 'kana02', STEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK", "MAX_LENGTH_CHECK", "KANA_CHECK"));
+	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "zip01", ZIP01_LEN ) ,array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "zip02", ZIP02_LEN ) ,array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK")); 
+	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "zip01", "zip02"), array("ALL_EXIST_CHECK"));
+	return $objErr->arrErr;
+	
+}
+
+/* ¥¨¥é¡¼¥Á¥§¥Ã¥¯ */
+function lfErrorCheck2() {
+	$objErr = new SC_CheckError();
+	
+	$objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", 'pref'), array("SELECT_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("»Ô¶èÄ®Â¼", "addr01", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("ÈÖÃÏ", "addr02", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", 'tel01'), array("EXIST_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", 'tel02'), array("EXIST_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", 'tel03'), array("EXIST_CHECK","NUM_CHECK"));
+	$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ", "tel01", "tel02", "tel03", TEL_LEN) ,array("TEL_CHECK"));
+	return $objErr->arrErr;
+	
+}
+
+
+
+/* ÅÐÏ¿¼Â¹Ô Èó²ñ°÷¹ØÆþ¤Ç¤¢¤ë¤¿¤á¤Ë¹±µ×Åª¤ÊÅÐÏ¿¤Ï¤·¤Ê¤¤*/
+function lfRegistData($array, $arrRegistColumn,$uniqid) {
+	global $objConn;
+	global $objCustomer;
+	
+    $objQuery = new SC_Query();
+    
+    $sqlse = "SELECT customer_id FROM dtb_order_temp WHERE order_temp_id = ?";
+    $arrRegist['customer_id'] = $objConn->getOne($sqlse, array($uniqid));
+    
+	foreach ($arrRegistColumn as $data) {
+		if (strlen($array[ $data["column"] ]) > 0) {
+			$arrRegist[ $data["column"] ] = $array[ $data["column"] ];
+		}
+	}
+	
+	//$arrRegist['customer_id'] = $objCustomer->getvalue('customer_id');
+    
+	//-- ÊÔ½¸ÅÐÏ¿¼Â¹Ô
+	$objConn->query("BEGIN");
+	if ($array['other_deliv_id'] != ""){
+		$objConn->autoExecute("dtb_other_deliv", $arrRegist, "other_deliv_id='" .addslashes($array["other_deliv_id"]). "'");
+	}else{
+		$objConn->autoExecute("dtb_other_deliv", $arrRegist);
+
+		$sqlse = "SELECT max(other_deliv_id) FROM dtb_other_deliv WHERE customer_id = ?";
+		$array['other_deliv_id'] = $objConn->getOne($sqlse, array($arrRegist['customer_id']));
+	}
+
+	$objConn->query("COMMIT");
+
+	return $array['other_deliv_id'];
+}
+
+
+
+// Í¹ÊØÈÖ¹æ¤«¤é½»½ê¤Î¼èÆÀ
+function lfGetAddress($zipcode) {
+	global $arrPref;
+
+	$conn = new SC_DBconn(ZIP_DSN);
+
+	// Í¹ÊØÈÖ¹æ¸¡º÷Ê¸ºîÀ®
+	$zipcode = mb_convert_kana($zipcode ,"n");
+	$sqlse = "SELECT state, city, town FROM mtb_zip WHERE zipcode = ?";
+
+	$data_list = $conn->getAll($sqlse, array($zipcode));
+
+	// ¥¤¥ó¥Ç¥Ã¥¯¥¹¤ÈÃÍ¤òÈ¿Å¾¤µ¤»¤ë¡£
+	$arrREV_PREF = array_flip($arrPref);
+
+	/*
+		ÁíÌ³¾Ê¤«¤é¥À¥¦¥ó¥í¡¼¥É¤·¤¿¥Ç¡¼¥¿¤ò¤½¤Î¤Þ¤Þ¥¤¥ó¥Ý¡¼¥È¤¹¤ë¤È
+		°Ê²¼¤Î¤è¤¦¤ÊÊ¸»úÎó¤¬Æþ¤Ã¤Æ¤¤¤ë¤Î¤Ç	ÂÐºö¤¹¤ë¡£
+		¡¦¡Ê£±¡¦£±£¹ÃúÌÜ¡Ë
+		¡¦°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç
+	*/
+	$town =  $data_list[0]['town'];
+	$town = ereg_replace("¡Ê.*¡Ë$","",$town);
+	$town = ereg_replace("°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç","",$town);
+	$data_list[0]['town'] = $town;
+	$data_list[0]['state'] = $arrREV_PREF[$data_list[0]['state']];
+
+	return $data_list;
+}
+
+/* ÊÌ¤Î¤ªÆÏ¤±Àè½»½ê¤ò°ì»þ¼õÃí¥Æ¡¼¥Ö¥ë¤Ø */
+function lfRegistOtherDelivData($uniqid, $objCustomer, $other_deliv_id) {
+	// ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+	$sqlval['order_temp_id'] = $uniqid;
+	$sqlval['update_date'] = 'Now()';
+	$sqlval['customer_id'] = '0';
+    //$sqlval['customer_id'] = $objCustomer->getValue('customer_id');
+	$sqlval['order_birth'] = $objCustomer->getValue('birth');
+
+	$objQuery = new SC_Query();
+	$where = "other_deliv_id = ?";
+	$arrRet = $objQuery->select("*", "dtb_other_deliv", $where, array($other_deliv_id));
+	
+	$sqlval['deliv_check'] = '1';
+    $sqlval['deliv_name01'] = $arrRet[0]['name01'];
+    $sqlval['deliv_name02'] = $arrRet[0]['name02'];
+    $sqlval['deliv_kana01'] = $arrRet[0]['kana01'];
+    $sqlval['deliv_kana02'] = $arrRet[0]['kana02'];
+    $sqlval['deliv_zip01'] = $arrRet[0]['zip01'];
+    $sqlval['deliv_zip02'] = $arrRet[0]['zip02'];
+    $sqlval['deliv_pref'] = $arrRet[0]['pref'];
+    $sqlval['deliv_addr01'] = $arrRet[0]['addr01'];
+    $sqlval['deliv_addr02'] = $arrRet[0]['addr02'];
+    $sqlval['deliv_tel01'] = $arrRet[0]['tel01'];
+    $sqlval['deliv_tel02'] = $arrRet[0]['tel02'];
+	$sqlval['deliv_tel03'] = $arrRet[0]['tel03'];
+	sfRegistTempOrder($uniqid, $sqlval);
+}
+
+?>
Index: /branches/beta/html/mobile/nonmember/payment.php
===================================================================
--- /branches/beta/html/mobile/nonmember/payment.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/payment.php	(revision 14676)
@@ -0,0 +1,372 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+	var $arrSession;
+	var $tpl_mode;
+	function LC_Page() {
+		$this->tpl_css = '/css/layout/shopping/pay.css';
+		$this->tpl_mainpage = 'nonmember/payment.tpl';
+		$this->tpl_onload = 'fnCheckInputPoint();';
+		$this->tpl_title = "¤ª»ÙÊ§ÊýË¡¤Î»ØÄê";
+		/*
+		 session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+		 ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+		 private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+		*/
+		session_cache_limiter('private-no-expire');		
+	}
+}
+
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objCustomer = new SC_Customer();
+$objSiteInfo = $objView->objSiteInfo;
+$arrInfo = $objSiteInfo->data;
+
+// ¥Ñ¥é¥á¡¼¥¿´ÉÍý¥¯¥é¥¹
+$objFormParam = new SC_FormParam();
+// ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+lfInitParam();
+// POSTÃÍ¤Î¼èÆÀ
+$objFormParam->setParam($_POST);
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+// ¥æ¥Ë¡¼¥¯ID¤ò°ú¤­·Ñ¤°
+$objPage->tpl_uniqid = $uniqid;
+
+// ²ñ°÷¥í¥°¥¤¥ó¥Á¥§¥Ã¥¯
+if($objCustomer->isLoginSuccess()) {
+	$objPage->tpl_login = '1';
+	$objPage->tpl_user_point = $objCustomer->getValue('point');
+}
+
+// ¶â³Û¤Î¼èÆÀ (¹ØÆþÅÓÃæ¤ÇÇä¤êÀÚ¤ì¤¿¾ì¹ç¤Ë¤Ï¤³¤Î´Ø¿ôÆâ¤Ë¤Æ¤½¤Î¾¦ÉÊ¤Î¸Ä¿ô¤¬£°¤Ë¤Ê¤ë)
+$objPage = sfTotalCart($objPage, $objCartSess, $arrInfo);
+$objPage->arrData = sfTotalConfirm($arrData, $objPage, $objCartSess, $arrInfo);
+
+// ¥«¡¼ÅÔÆâ¤Î¾¦ÉÊ¤ÎÇä¤êÀÚ¤ì¥Á¥§¥Ã¥¯
+$objCartSess->chkSoldOut($objCartSess->getCartList(), true);
+
+// Ìá¤ë¥Ü¥¿¥ó¤Î½èÍý
+if (!empty($_POST['return'])) {
+	switch ($_POST['mode']) {
+	case 'confirm':
+		$_POST['mode'] = 'payment';
+		break;
+	default:
+		// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+		$objSiteSess->setRegistFlag();
+		//header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_TOP));
+        header("Location: " . gfAddSessionId('../shopping/index.php'));
+		exit;
+	}
+}
+switch($_POST['mode']) {
+// »ÙÊ§¤¤ÊýË¡»ØÄê ¢ª ÇÛÃ£Æü»þ»ØÄê
+case 'deliv_date':
+	
+    // ÆþÎÏÃÍ¤ÎÊÑ´¹
+	$objFormParam->convParam();
+	$objPage->arrErr = lfCheckError($objPage->arrData);
+	if (!isset($objPage->arrErr['payment_id'])) {
+		// »ÙÊ§¤¤ÊýË¡¤ÎÆþÎÏ¥¨¥é¡¼¤Ê¤·
+		$objPage->tpl_mainpage = 'nonmember/deliv_date.tpl';
+		$objPage->tpl_title = "ÇÛÃ£Æü»þ»ØÄê";
+		break;
+	} else {
+		// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+		$uniqid = $objSiteSess->getUniqId();
+		// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+		lfSetOrderTempData($uniqid);
+	}
+	break;
+case 'confirm':
+	// ÆþÎÏÃÍ¤ÎÊÑ´¹
+	$objFormParam->convParam();
+	$objPage->arrErr = lfCheckError($objPage->arrData );
+	// ÆþÎÏ¥¨¥é¡¼¤Ê¤·
+	if(count($objPage->arrErr) == 0) {
+		// DB¤Ø¤Î¥Ç¡¼¥¿ÅÐÏ¿
+		lfRegistData($uniqid);
+		// Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+		$objSiteSess->setRegistFlag();
+		// ³ÎÇ§¥Ú¡¼¥¸¤Ø°ÜÆ°
+		//header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_CONFIRM));
+        header("Location: " . gfAddSessionId('./confirm.php'));
+		exit;
+	}else{
+		// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+		$uniqid = $objSiteSess->getUniqId();
+		// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+		lfSetOrderTempData($uniqid);
+		if (!isset($objPage->arrErr['payment_id'])) {
+			// »ÙÊ§¤¤ÊýË¡¤ÎÆþÎÏ¥¨¥é¡¼¤Ê¤·
+			$objPage->tpl_mainpage = 'nonmember/deliv_date.tpl';
+			$objPage->tpl_title = "ÇÛÃ£Æü»þ»ØÄê";
+		}
+	}
+	break;
+// Á°¤Î¥Ú¡¼¥¸¤ËÌá¤ë
+case 'return':
+	// Èó²ñ°÷¤Î¾ì¹ç
+	// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+	$objSiteSess->setRegistFlag();
+	header("Location: " . gfAddSessionId('../shopping/index.php'));
+	exit;
+	break;
+// »ÙÊ§¤¤ÊýË¡¤¬ÊÑ¹¹¤µ¤ì¤¿¾ì¹ç
+case 'payment':
+	// ¤³¤³¤Îbreak¤Ï¡¢°ÕÌ£¤¬¤¢¤ë¤Î¤Ç³°¤µ¤Ê¤¤¤Ç²¼¤µ¤¤¡£
+	break;
+default:
+	// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+	lfSetOrderTempData($uniqid);
+	break;
+}
+
+// Å¹ÊÞ¾ðÊó¤Î¼èÆÀ
+$arrInfo = $objSiteInfo->data;
+// ¹ØÆþ¶â³Û¤Î¼èÆÀÆÀ
+$total_pretax = $objCartSess->getAllProductsTotal($arrInfo);
+// »ÙÊ§¤¤ÊýË¡¤Î¼èÆÀ
+$objPage->arrPayment = lfGetPayment($total_pretax);
+// ÇÛÁ÷»þ´Ö¤Î¼èÆÀ
+$arrRet = sfGetDelivTime($objFormParam->getValue('payment_id'));
+$objPage->arrDelivTime = sfArrKeyValue($arrRet, 'time_id', 'deliv_time');
+$objPage->objCustomer = $objCustomer;
+//¡¡ÇÛÁ÷Æü°ìÍ÷¤Î¼èÆÀ
+$objPage->arrDelivDate = lfGetDelivDate();
+
+$objPage->arrForm = $objFormParam->getFormParamList();
+
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+//--------------------------------------------------------------------------------------------------------------------------
+/* ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½ */
+function lfInitParam() {
+	global $objFormParam;
+	$objFormParam->addParam("¤ª»ÙÊ§¤¤ÊýË¡", "payment_id", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+	$objFormParam->addParam("¥Ý¥¤¥ó¥È", "use_point", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK", "ZERO_START"));
+	$objFormParam->addParam("ÇÛÃ£»þ´Ö", "deliv_time_id", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+	$objFormParam->addParam("¤´¼ÁÌä", "message", LTEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+	$objFormParam->addParam("¥Ý¥¤¥ó¥È¤ò»ÈÍÑ¤¹¤ë", "point_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), '2');
+	$objFormParam->addParam("ÇÛÃ£Æü", "deliv_date", STEXT_LEN, "KVa", array("MAX_LENGTH_CHECK"));
+}
+
+function lfGetPayment($total_pretax) {
+	$objQuery = new SC_Query();
+	$objQuery->setorder("rank DESC");
+	//ºï½ü¤µ¤ì¤Æ¤¤¤Ê¤¤»ÙÊ§ÊýË¡¤ò¼èÆÀ
+	$arrRet = $objQuery->select("payment_id, payment_method, rule, upper_rule, note, payment_image", "dtb_payment", "del_flg = 0 AND deliv_id IN (SELECT deliv_id FROM dtb_deliv WHERE del_flg = 0) ");
+	//ÍøÍÑ¾ò·ï¤«¤é»ÙÊ§²ÄÇ½ÊýË¡¤òÈ½Äê
+	foreach($arrRet as $data) {
+		//²¼¸Â¤È¾å¸Â¤¬ÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		if($data['rule'] > 0 && $data['upper_rule'] > 0) {
+			if($data['rule'] <= $total_pretax && $data['upper_rule'] >= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//²¼¸Â¤Î¤ßÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		} elseif($data['rule'] > 0) {	
+			if($data['rule'] <= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//¾å¸Â¤Î¤ßÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		} elseif($data['upper_rule'] > 0) {
+			if($data['upper_rule'] >= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//ÀßÄê¤Ê¤·
+		} else {
+			$arrPayment[] = $data;
+		}	
+	}
+	return $arrPayment;	
+}
+
+/* ÆþÎÏÆâÍÆ¤Î¥Á¥§¥Ã¥¯ */
+function lfCheckError($arrData) {
+	global $objFormParam;
+	global $objCustomer;
+	// ÆþÎÏ¥Ç¡¼¥¿¤òÅÏ¤¹¡£
+	$arrRet =  $objFormParam->getHashArray();
+	$objErr = new SC_CheckError($arrRet);
+	$objErr->arrErr = $objFormParam->checkError();
+	
+	if($_POST['point_check'] == '1') {
+		$objErr->doFunc(array("¥Ý¥¤¥ó¥È¤ò»ÈÍÑ¤¹¤ë", "point_check"), array("EXIST_CHECK"));
+		$objErr->doFunc(array("¥Ý¥¤¥ó¥È", "use_point"), array("EXIST_CHECK"));
+		$max_point = $objCustomer->getValue('point');
+		if($max_point == "") {
+			$max_point = 0;
+		}
+		if($arrRet['use_point'] > $max_point) {
+			$objErr->arrErr['use_point'] = "¢¨ ¤´ÍøÍÑ¥Ý¥¤¥ó¥È¤¬½ê»ý¥Ý¥¤¥ó¥È¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£<br>";
+		}
+		if(($arrRet['use_point'] * POINT_VALUE) > $arrData['subtotal']) {
+			$objErr->arrErr['use_point'] = "¢¨ ¤´ÍøÍÑ¥Ý¥¤¥ó¥È¤¬¤´¹ØÆþ¶â³Û¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£<br>";
+		}
+	}
+	return $objErr->arrErr;
+}
+
+/* »ÙÊ§¤¤ÊýË¡Ê¸»úÎó¤Î¼èÆÀ */
+function lfGetPaymentInfo($payment_id) {
+	$objQuery = new SC_Query();
+	$where = "payment_id = ?";
+	$arrRet = $objQuery->select("payment_method, charge", "dtb_payment", $where, array($payment_id));
+	return (array($arrRet[0]['payment_method'], $arrRet[0]['charge']));
+}
+
+/* ÇÛÁ÷»þ´ÖÊ¸»úÎó¤Î¼èÆÀ */
+function lfGetDelivTimeInfo($time_id) {
+	$objQuery = new SC_Query();
+	$where = "time_id = ?";
+	$arrRet = $objQuery->select("deliv_id, deliv_time", "dtb_delivtime", $where, array($time_id));
+	return (array($arrRet[0]['deliv_id'], $arrRet[0]['deliv_time']));
+}
+
+/* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
+function lfRegistData($uniqid) {
+	global $objFormParam;
+	$arrRet = $objFormParam->getHashArray();
+	$sqlval = $objFormParam->getDbArray();
+	// ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+	$sqlval['order_temp_id'] = $uniqid;
+	$sqlval['update_date'] = 'Now()';
+	
+	if($sqlval['payment_id'] != "") {
+		list($sqlval['payment_method'], $sqlval['charge']) = lfGetPaymentInfo($sqlval['payment_id']);
+	} else {
+		$sqlval['payment_id'] = '0';
+		$sqlval['payment_method'] = "";
+	}
+	
+	if($sqlval['deliv_time_id'] != "") {
+		list($sqlval['deliv_id'], $sqlval['deliv_time']) = lfGetDelivTimeInfo($sqlval['deliv_time_id']);
+	} else {
+		$sqlval['deliv_time_id'] = '0';
+		$sqlval['deliv_id'] = '0';
+		$sqlval['deliv_time'] = "";
+	}
+	
+	// »ÈÍÑ¥Ý¥¤¥ó¥È¤ÎÀßÄê
+	if($sqlval['point_check'] != '1') {
+		$sqlval['use_point'] = 0;
+	}
+	
+	sfRegistTempOrder($uniqid, $sqlval);
+}
+
+/* ÇÛÃ£Æü°ìÍ÷¤ò¼èÆÀ¤¹¤ë */
+function lfGetDelivDate() {
+	$objCartSess = new SC_CartSession();
+	$objQuery = new SC_Query();
+	// ¾¦ÉÊID¤Î¼èÆÀ
+	$max = $objCartSess->getMax();
+	for($i = 1; $i <= $max; $i++) {
+		if($_SESSION[$objCartSess->key][$i]['id'][0] != "") {
+			$arrID['product_id'][$i] = $_SESSION[$objCartSess->key][$i]['id'][0];
+		}
+	}
+	if(count($arrID['product_id']) > 0) {
+		$id = implode(",", $arrID['product_id']);
+		//¾¦ÉÊ¤«¤éÈ¯Á÷ÌÜ°Â¤Î¼èÆÀ
+		$deliv_date = $objQuery->get("dtb_products", "MAX(deliv_date_id)", "product_id IN (".$id.")");
+		//È¯Á÷ÌÜ°Â
+		switch($deliv_date) {
+		//Â¨ÆüÈ¯Á÷
+		case '1':
+			$start_day = 1;
+			break;
+		//1-2Æü¸å
+		case '2':
+			$start_day = 3;
+			break;
+		//3-4Æü¸å
+		case '3':
+			$start_day = 5;
+			break;
+		//1½µ´Ö°ÊÆâ
+		case '4':
+			$start_day = 8;
+			break;
+		//2½µ´Ö°ÊÆâ
+		case '5':
+			$start_day = 15;
+			break;
+		//3½µ´Ö°ÊÆâ
+		case '6':
+			$start_day = 22;
+			break;
+		//1¥ö·î°ÊÆâ
+		case '7':
+			$start_day = 32;
+			break;
+		//2¥ö·î°Ê¹ß
+		case '8':
+			$start_day = 62;			
+			break;
+		//¤ª¼è¤ê´ó¤»(¾¦ÉÊÆþ²Ù¸å)
+		case '9':
+			$start_day = "";
+			break;
+		default:
+			//¤ªÆÏ¤±Æü¤¬ÀßÄê¤µ¤ì¤Æ¤¤¤Ê¤¤¾ì¹ç
+			$start_day = "";
+			break;
+		}
+		//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤«¤é¡¢ÇÛÃ£Æü¤ÎÇÛÎó¤ò¼èÆÀ¤¹¤ë
+		$arrDelivDate = lfGetDateArray($start_day, DELIV_DATE_END_MAX);
+	}
+	return $arrDelivDate;
+}
+
+//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤«¤é¡¢ÇÛÃ£Æü¤ÎÇÛÎó¤ò¼èÆÀ¤¹¤ë
+function lfGetDateArray($start_day, $end_day) {
+	global $arrWDAY;
+	//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤¬¥»¥Ã¥È¤µ¤ì¤Æ¤¤¤ì¤Ð
+	if($start_day >= 1) {
+		$now_time = time();
+		$max_day = $start_day + $end_day;
+		// ½¸·×
+		for ($i = $start_day; $i < $max_day; $i++) {
+			// ´ðËÜ»þ´Ö¤«¤éÆü¿ô¤òÄÉ²Ã¤·¤Æ¤¤¤¯
+			$tmp_time = $now_time + ($i * 24 * 3600);
+			list($y, $m, $d, $w) = split(" ", date("y m d w", $tmp_time));	
+			$val = sprintf("%02d/%02d/%02d(%s)", $y, $m, $d, $arrWDAY[$w]);
+			$arrDate[$val] = $val;
+		}
+	} else {
+		$arrDate = false;
+	}
+	return $arrDate;
+}
+
+//°ì»þ¼õÃí¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼¤¹¤ë
+function lfSetOrderTempData($uniqid) {
+	global $objQuery;
+	global $objFormParam;
+	
+	$objQuery = new SC_Query();
+	$col = "payment_id, use_point, deliv_time_id, message, point_check, deliv_date";
+	$from = "dtb_order_temp";
+	$where = "order_temp_id = ?";
+	$arrRet = $objQuery->select($col, $from, $where, array($uniqid));
+	// DBÃÍ¤Î¼èÆÀ
+	$objFormParam->setParam($arrRet[0]);
+	return $objFormParam;
+}
+
+
+?>
Index: /branches/beta/html/mobile/nonmember/load_payment_module.php
===================================================================
--- /branches/beta/html/mobile/nonmember/load_payment_module.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/load_payment_module.php	(revision 14676)
@@ -0,0 +1,44 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+require_once("../require.php");
+
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objQuery = new SC_Query();
+
+// Á°¤Î¥Ú¡¼¥¸¤ÇÀµ¤·¤¯ÅÐÏ¿¼êÂ³¤­¤¬¹Ô¤ï¤ì¤¿µ­Ï¿¤¬¤¢¤ë¤«È½Äê
+sfIsPrePage($objSiteSess, true);
+
+// ¥¢¥¯¥»¥¹¤ÎÀµÅöÀ­¤ÎÈ½Äê
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+
+$payment_id = $_SESSION["payment_id"];
+
+// »ÙÊ§¤¤ID¤¬Ìµ¤¤¾ì¹ç¤Ë¤Ï¥¨¥é¡¼
+if($payment_id == ""){
+	sfDispSiteError(PAGE_ERROR, "", true, "", true);
+}
+
+// ·èºÑ¾ðÊó¤ò¼èÆÀ¤¹¤ë
+if(sfColumnExists("dtb_payment", "memo01")){
+	$sql = "SELECT module_path, memo01, memo02, memo03, memo04, memo05, memo06, memo07, memo08, memo09, memo10 FROM dtb_payment WHERE payment_id = ?";
+	$arrPayment = $objQuery->getall($sql, array($payment_id));
+}
+
+if(count($arrPayment) > 0) {
+	$path = $arrPayment[0]['module_path'];
+	if(file_exists($path)) {
+		require_once($path);
+		exit;
+	} else {
+		sfDispSiteError(FREE_ERROR_MSG, "", true, "¥â¥¸¥å¡¼¥ë¥Õ¥¡¥¤¥ë¤Î¼èÆÀ¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£<br />¤³¤Î¼êÂ³¤­¤ÏÌµ¸ú¤È¤Ê¤ê¤Þ¤·¤¿¡£", true);
+	}
+}
+
+?>
Index: /branches/beta/html/mobile/nonmember/deliv.php
===================================================================
--- /branches/beta/html/mobile/nonmember/deliv.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/deliv.php	(revision 14676)
@@ -0,0 +1,217 @@
+<?php 
+
+require_once("../require.php");
+
+class LC_Page {
+    var $arrSession;
+    var $tpl_mode;
+    var $tpl_login_email;
+    function LC_Page() {
+        $this->tpl_mainpage = 'nonmember/index.tpl';
+        global $arrPref;
+        $this->arrPref = $arrPref;
+        global $arrSex;
+        $this->arrSex = $arrSex;
+        global $arrJob;
+        $this->arrJob = $arrJob;
+        $this->tpl_onload = 'fnCheckInputDeliv();';
+        
+        /*
+         session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+         ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+         private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+        */
+        session_cache_limiter('private-no-expire');             
+    }
+}
+
+$conn = new SC_DBConn();
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objCustomer = new SC_Customer();
+$objCookie = new SC_Cookie();
+$objFormParam = new SC_FormParam();         // ¥Õ¥©¡¼¥àÍÑ
+lfInitParam();                              // ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+$objFormParam->setParam($_POST);            // POSTÃÍ¤Î¼èÆÀ
+
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+
+// ¥æ¥Ë¡¼¥¯ID¤ò°ú¤­·Ñ¤°
+$objPage->tpl_uniqid = $uniqid;
+
+if(!empty($_POST["mode2"]) ){
+    if ($_POST["mode2"] == "deliv") {
+            
+            $objFormParam = new SC_FormParam();
+            // ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+           
+            // POSTÃÍ¤Î¼èÆÀ
+            $objFormParam->setParam($_POST);
+            $arrRet = $objFormParam->getHashArray();
+            $sqlval = $objFormParam->getDbArray();
+            
+            // ÆþÎÏÃÍ¤Î¼èÆÀ
+            $objPage->arrForm = $objFormParam->getFormParamList();
+            $objPage->arrErr = $arrErr;
+            
+           foreach($_POST as $key => $value){
+               $objPage->arrAddr[0][$key] = $value;
+           }
+            
+            //¥Ç¡¼¥¿¥Ù¡¼¥¹¤Î°ì»þÊÝÂ¸ÍÑ¥Æ¡¼¥Ö¥ëdtb_order_temp¤Ë¥Ç¡¼¥¿¤ò³ÊÇ¼¤¹¤ë
+            lfRegistDataTemp($objPage->arrAddr[0]['uniqid'],$objPage->arrAddr[0]); 
+            
+            lfCopyDeliv($objPage->tpl_uniqid, $_POST);
+           
+            $objPage->tpl_mainpage = 'nonmember/nonmember_deliv.tpl';
+            $objPage->tpl_title = '¤ªÆÏ¤±Àè¾ðÊó';
+            //objPage¤Î¾ðÊó¤òobjView¤Ë³ÊÇ¼
+            $objView->assignobj($objPage);
+            $objView->display(SITE_FRAME);
+        }
+        
+        if ($_POST["mode2"] == "customer_addr") {
+            //print_r($_POST);
+            if ($_POST['deli'] != "") {
+                header("Location:" . gfAddSessionId("./payment.php"));
+            exit;
+            }else{
+                // ¥¨¥é¡¼¤òÊÖ¤¹
+                $arrErr['deli'] = '¢¨ ¤ªÆÏ¤±Àè¤òÁªÂò¤·¤Æ¤¯¤À¤µ¤¤¡£';
+            }
+        }
+//Ìá¤ë¥Ü¥¿¥óÍÑ½èÍý        
+}elseif(!empty($_POST["mode"]) && $_POST["mode"]=="deliv_date"){  
+    //uniqid¤«¤é¥Ç¡¼¥¿¥Ù¡¼¥¹¤Î¥Ç¡¼¥¿¤òÆÉ¤ß¹þ¤ßÉ½¼¨¤¹¤ë
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $arrRet = $objQuery->select("*", "dtb_order_temp", $where, array($objPage->tpl_uniqid));
+    $objFormParam->setParam($arrRet[0]);
+    $objPage->arrForm = $objFormParam->getFormParamList();        
+    
+         foreach($objPage->arrForm as $key => $value){
+           $objPage->arrAddr[0][str_replace("order_","",$key)] = $value['value'];
+       }
+    $objPage->tpl_mainpage = 'nonmember/nonmember_deliv.tpl';
+    $objPage->tpl_title = '¤ªÆÏ¤±Àè¾ðÊó';
+    $objView->assignobj($objPage);
+    $objView->display(SITE_FRAME);
+}
+
+/**
+ *ÆþÎÏ¤µ¤ì¤¿¾ðÊó¤ò¥Ç¡¼¥¿¥Ù¡¼¥¹dtb_order_temp¤Ë³ÊÇ¼¤¹¤ë
+ * 
+ * @param string $uniqid unique id
+ * @param array $array 
+ * 
+*/
+function lfRegistDataTemp($uniqid,$array) {
+    global $objFormParam;
+    $arrRet = $objFormParam->getHashArray();
+    $sqlval = $objFormParam->getDbArray();
+        
+    // ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+    $sqlval['order_temp_id'] = $uniqid;
+    $sqlval['order_birth'] = sfGetTimestamp($arrRet['year'], $arrRet['month'], $arrRet['day']);
+    $sqlval['update_date'] = 'Now()';
+    $sqlval['customer_id'] = '0';
+    
+    $sqlval['order_name01'] = $array['name01'];
+    $sqlval['order_name02'] = $array['name02'];
+    $sqlval['order_kana01'] = $array['kana01'];
+    $sqlval['order_kana02'] = $array['kana02'];
+    $sqlval['order_zip01'] = $array['zip01'];
+    $sqlval['order_zip02'] = $array['zip02'];
+    $sqlval['order_pref'] = $array['pref'];
+    $sqlval['order_addr01'] = $array['addr01'];
+    $sqlval['order_addr02'] = $array['addr02'];
+    $sqlval['order_tel01'] = $array['tel01'];
+    $sqlval['order_tel02'] = $array['tel02'];
+    $sqlval['order_tel03'] = $array['tel03'];
+    $sqlval['order_email'] = $array['email'];
+    $sqlval['order_sex'] = $array['sex'];
+          
+    // ´ûÂ¸¥Ç¡¼¥¿¤Î¥Á¥§¥Ã¥¯
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $cnt = $objQuery->count("dtb_order_temp", $where, array($uniqid));
+    // ´ûÂ¸¥Ç¡¼¥¿¤¬¤Ê¤¤¾ì¹ç
+    if ($cnt == 0) {
+        $sqlval['create_date'] = 'Now()';
+        $objQuery->insert("dtb_order_temp", $sqlval);
+    } else {
+        $objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+    }
+}
+
+/* ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½ */
+function lfInitParam() {
+    global $objFormParam;
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "order_name01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "order_name02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "order_kana01", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "order_kana02", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "order_zip01", ZIP01_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "order_zip02", ZIP02_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "order_pref", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("½»½ê1", "order_addr01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("½»½ê2", "order_addr02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "order_tel01", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "order_tel02", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "order_tel03", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ1", "order_fax01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ2", "order_fax02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ3", "order_fax03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹", "order_email", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email_check", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"), "", false);
+    $objFormParam->addParam("Ç¯", "year", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("·î", "month", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("Æü", "day", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("À­ÊÌ", "order_sex", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("¿¦¶È", "order_job", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("ÊÌ¤Î¤ªÆÏ¤±Àè", "deliv_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "deliv_zip01", ZIP01_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "deliv_zip02", ZIP02_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "deliv_pref", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("½»½ê1", "deliv_addr01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("½»½ê2", "deliv_addr02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "deliv_tel01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "deliv_tel02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "deliv_tel03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥Þ¥¬¥¸¥ó", "mail_flag", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), 1);
+}
+
+/* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
+
+
+// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Î¤ªÆÏ¤±Àè¤ò¥³¥Ô¡¼¤¹¤ë
+function lfCopyDeliv($uniqid, $arrData) {
+    $objQuery = new SC_Query();
+    
+    // ÊÌ¤Î¤ªÆÏ¤±Àè¤ò»ØÄê¤·¤Æ¤¤¤Ê¤¤¾ì¹ç¡¢ÇÛÁ÷Àè¤ËÅÐÏ¿½»½ê¤ò¥³¥Ô¡¼¤¹¤ë¡£
+    if($arrData["deliv_check"] != "1") {
+        $sqlval['deliv_name01'] = $arrData['order_name01'];
+        $sqlval['deliv_name02'] = $arrData['order_name02'];
+        $sqlval['deliv_kana01'] = $arrData['order_kana01'];
+        $sqlval['deliv_kana02'] = $arrData['order_kana02'];
+        $sqlval['deliv_pref'] = $arrData['order_pref'];
+        $sqlval['deliv_zip01'] = $arrData['order_zip01'];
+        $sqlval['deliv_zip02'] = $arrData['order_zip02'];
+        $sqlval['deliv_addr01'] = $arrData['order_addr01'];
+        $sqlval['deliv_addr02'] = $arrData['order_addr02'];
+        $sqlval['deliv_tel01'] = $arrData['order_tel01'];
+        $sqlval['deliv_tel02'] = $arrData['order_tel02'];
+        $sqlval['deliv_tel03'] = $arrData['order_tel03'];
+        $where = "order_temp_id = ?";
+        $objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+    }
+}
+
+?>
Index: /branches/beta/html/mobile/nonmember/index.php
===================================================================
--- /branches/beta/html/mobile/nonmember/index.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/index.php	(revision 14676)
@@ -0,0 +1,528 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+    var $arrSession;
+    var $tpl_mode;
+    var $tpl_login_email;
+    function LC_Page() {
+        $this->tpl_mainpage = 'nonmember/index.tpl';
+        global $arrPref;
+        $this->arrPref = $arrPref;
+        global $arrSex;
+        $this->arrSex = $arrSex;
+        global $arrJob;
+        $this->arrJob = $arrJob;
+        $this->tpl_onload = 'fnCheckInputDeliv();';
+        
+        /*
+         session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+         ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+         private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+        */
+        session_cache_limiter('private-no-expire');             
+    }
+}
+
+$conn = new SC_DBConn();
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objCustomer = new SC_Customer();
+$objCookie = new SC_Cookie();
+$objFormParam = new SC_FormParam();         // ¥Õ¥©¡¼¥àÍÑ
+lfInitParam();                              // ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+$objFormParam->setParam($_POST);            // POSTÃÍ¤Î¼èÆÀ
+
+//-------------------------------------¢§NONMEMBER----------------------------------------------
+//---- ¥Ú¡¼¥¸½é´üÀßÄê
+
+$CONF = sf_getBasisData();                  // Å¹ÊÞ´ðËÜ¾ðÊó
+$objDate = new SC_Date(START_BIRTH_YEAR, date("Y",strtotime("now")));
+$objPage->arrPref = $arrPref;
+$objPage->arrJob = $arrJob;
+$objPage->arrReminder = $arrReminder;
+$objPage->arrYear = $objDate->getYear('', 1950);    //¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
+$objPage->arrMonth = $objDate->getMonth();
+$objPage->arrDay = $objDate->getDay();
+
+//SSLURLÈ½Äê
+if (SSLURL_CHECK == 1){
+    $ssl_url= sfRmDupSlash(MOBILE_SSL_URL.$_SERVER['REQUEST_URI']);
+    if (!ereg("^https://", $non_ssl_url)){
+        sfDispSiteError(URL_ERROR, "", false, "", true);
+    }
+}
+
+// ¥ì¥¤¥¢¥¦¥È¥Ç¥¶¥¤¥ó¤ò¼èÆÀ
+$objPage = sfGetPageLayout($objPage, false, DEF_LAYOUT);
+
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+
+$objPage->tpl_uniqid = $uniqid;
+
+switch($_POST['mode']) {
+case 'nonmember_confirm':
+    $objPage = lfSetNonMember($objPage);
+    // ¢¨break¤Ê¤·
+case 'confirm':
+    // ÆþÎÏÃÍ¤ÎÊÑ´¹
+    $objFormParam->convParam();
+    $objFormParam->toLower('order_mail');
+    $objFormParam->toLower('order_mail_check');
+    $objPage->arrErr = lfCheckError();
+    // ÆþÎÏ¥¨¥é¡¼¤Ê¤·
+    if(count($objPage->arrErr) == 0) {
+        // DB¤Ø¤Î¥Ç¡¼¥¿ÅÐÏ¿
+        lfRegistData($uniqid);
+        // Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+        $objSiteSess->setRegistFlag();
+        // ¤ª»ÙÊ§¤¤ÊýË¡ÁªÂò¥Ú¡¼¥¸¤Ø°ÜÆ°
+        header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_PAYMENT));
+        exit;       
+    }
+    
+    break;
+// Á°¤Î¥Ú¡¼¥¸¤ËÌá¤ë
+case 'return':
+    // ³ÎÇ§¥Ú¡¼¥¸¤Ø°ÜÆ°
+    header("Location: " . gfAddSessionId(MOBILE_URL_CART_TOP));
+    exit;
+    break;
+case 'nonmember':
+    $objPage = lfSetNonMember($objPage);
+    // ¢¨break¤Ê¤·
+default:
+    if($_GET['from'] == 'nonmember') {
+        $objPage = lfSetNonMember($objPage);
+    }
+    // ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+    $uniqid = $objSiteSess->getUniqId();
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $arrRet = $objQuery->select("*", "dtb_order_temp", $where, array($uniqid));
+    // DBÃÍ¤Î¼èÆÀ
+    $objFormParam->setParam($arrRet[0]);
+    $objFormParam->setValue('order_email_check', $arrRet[0]['order_email']);
+    $objFormParam->setDBDate($arrRet[0]['order_birth']);
+    break;
+}
+
+// ¥¯¥Ã¥­¡¼È½Äê
+$objPage->tpl_login_email = $objCookie->getCookie('login_email');
+if($objPage->tpl_login_email != "") {
+    $objPage->tpl_login_memory = "1";
+}
+
+// ÁªÂòÍÑÆüÉÕ¤Î¼èÆÀ
+$objDate = new SC_Date(START_BIRTH_YEAR);
+$objPage->arrYear = $objDate->getYear('', 1950);    //¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
+$objPage->arrMonth = $objDate->getMonth();
+$objPage->arrDay = $objDate->getDay();
+
+// ÆþÎÏÃÍ¤Î¼èÆÀ
+$objPage->arrForm = $objFormParam->getFormParamList();
+
+//objPage¤Î¾ðÊó¤òobjView¤Ë³ÊÇ¼
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+
+//--------------------------------------------------------------------------------------------------------------------------
+/* Èó²ñ°÷ÆþÎÏ¥Ú¡¼¥¸¤Î¥»¥Ã¥È */
+function lfSetNonMember($objPage) {
+    
+    $arrRegistColumn = array(
+                             array(  "column" => "name01", "convert" => "aKV" ),
+                             array(  "column" => "name02", "convert" => "aKV" ),
+                             array(  "column" => "kana01", "convert" => "CKV" ),
+                             array(  "column" => "kana02", "convert" => "CKV" ),
+                             array(  "column" => "zip01", "convert" => "n" ),
+                             array(  "column" => "zip02", "convert" => "n" ),
+                             array(  "column" => "pref", "convert" => "n" ),
+                             array(  "column" => "addr01", "convert" => "aKV" ),
+                             array(  "column" => "addr02", "convert" => "aKV" ),
+                             array(  "column" => "email", "convert" => "a" ),
+                             array(  "column" => "email2", "convert" => "a" ),
+                             array(  "column" => "email_mobile", "convert" => "a" ),
+                             array(  "column" => "email_mobile2", "convert" => "a" ),
+                             array(  "column" => "tel01", "convert" => "n" ),
+                             array(  "column" => "tel02", "convert" => "n" ),
+                             array(  "column" => "tel03", "convert" => "n" ),
+                             array(  "column" => "fax01", "convert" => "n" ),
+                             array(  "column" => "fax02", "convert" => "n" ),
+                             array(  "column" => "fax03", "convert" => "n" ),
+                             array(  "column" => "sex", "convert" => "n" ),
+                             array(  "column" => "job", "convert" => "n" ),
+                             array(  "column" => "birth", "convert" => "n" ),
+                             array(  "column" => "reminder", "convert" => "n" ),
+                             array(  "column" => "reminder_answer", "convert" => "aKV"),
+                             array(  "column" => "password", "convert" => "a" ),
+                             array(  "column" => "password02", "convert" => "a" ),
+                             array(  "column" => "mailmaga_flg", "convert" => "n" ),
+                         );
+
+//---- ÅÐÏ¿½ü³°ÍÑ¥«¥é¥àÇÛÎó
+//$arrRejectRegistColumn = array("year", "month", "day", "email02", "email_mobile02","password","password02","reminder","reminder_answer");
+$arrRejectRegistColumn = array("year", "month", "day", "email02", "email_mobile02", "password02");
+        
+    $objPage->tpl_mainpage = 'nonmember/nonmember_set1.tpl';
+    $objPage->tpl_css = array();
+    $objPage->tpl_css[] = '/css/layout/login/nonmember.css';
+    
+    //-- POST¥Ç¡¼¥¿¤Î°ú¤­·Ñ¤®
+    $objPage->arrForm = $_POST;
+    
+    if($objPage->arrForm['year'] == '----') {
+        $objPage->arrForm['year'] = '';
+    }
+    
+    //$objPage->arrForm['email'] = strtolower($objPage->arrForm['email']);        // email¤Ï¤¹¤Ù¤Æ¾®Ê¸»ú¤Ç½èÍý
+    
+    //-- ÆþÎÏ¥Ç¡¼¥¿¤ÎÊÑ´¹
+    $objPage->arrForm = lfConvertParam($objPage->arrForm, $arrRegistColumn);
+
+    // Ìá¤ë¥Ü¥¿¥óÍÑ½èÍý
+    //return¤ÎÃæ¤Ë¸µ¤Î¥Ú¡¼¥¸¤ÎÌ¾Á°¤¬Æþ¤Ã¤Æ¤¤¤ë
+    if (!empty($_POST["return"])) {
+        switch ($_POST["mode2"]) {
+        case "deliv_date":  
+        
+            break;
+        case "deliv":
+            $_POST["mode2"] = "set3";
+            break;
+        case "set3":
+            $_POST["mode2"] = "set2";
+            break;
+        default:
+            $_POST["mode2"] = "set1";
+            break;
+        }
+    }    
+
+    //--¡¡ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+    if (!empty($_POST["mode2"])) {
+            if ($_POST["mode2"] == "set2") {
+            $objPage->arrErr = lfErrorCheck1($objPage->arrForm);
+            $objPage->tpl_mainpage = 'nonmember/nonmember_set1.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(1/3)';
+        } elseif ($_POST["mode2"] == "set3") {
+            
+            $objPage->arrErr = lfErrorCheck2($objPage->arrForm);
+            $objPage->tpl_mainpage = 'nonmember/nonmember_set2.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(2/3)';
+        } elseif ($_POST["mode2"] == "deliv"){
+            $objPage->arrErr = lfErrorCheck3($objPage->arrForm);
+            $objPage->tpl_mainpage = 'nonmember/nonmember_set3.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(3/3)';
+        }
+    
+    //¥Õ¥©¡¼¥à¤ÎÃÍ¤ò$objPage¤Î¥­¡¼¤È¤·¤ÆÂåÆþ¤·¤Æ¤¤¤¯
+   foreach($objPage->arrForm as $key => $val) {
+        $objPage->$key = $val;
+        }
+    }
+
+        // ÆþÎÏ¥¨¥é¡¼¤Î¥Á¥§¥Ã¥¯
+    if ($objPage->arrErr || !empty($_POST["return"])) {     
+
+        //-- ¥Ç¡¼¥¿¤ÎÀßÄê
+        if ($_POST["mode2"] == "set2") {
+            $checkVal = array("email", "name01", "name02", "kana01", "kana02");
+        } elseif ($_POST["mode2"] == "set3") {
+            $checkVal = array("sex", "year", "month", "day", "zip01", "zip02");
+        } else {
+            $checkVal = array("pref", "addr01", "addr02", "tel01", "tel02", "tel03", "mail_flag");
+        }
+
+        foreach($objPage->arrForm as $key => $val) {
+            if ($key != "mode2" && $key != "submit" && $key != "return" && $key != session_name() && !in_array($key, $checkVal))
+                $objPage->list_data[ $key ] = $val;
+        }
+
+    } else {
+
+        //--¡¡¥Æ¥ó¥×¥ì¡¼¥ÈÀßÄê
+        if ($_POST["mode2"] == "set2") {
+            
+            $objPage->tpl_mainpage = 'nonmember/nonmember_set2.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(2/3)';
+        } elseif ($_POST["mode2"] == "set3") {
+            $objPage->tpl_mainpage = 'nonmember/nonmember_set3.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(3/3)';
+
+            if (@$objPage->arrForm['pref'] == "" && @$objPage->arrForm['addr01'] == "" && @$objPage->arrForm['addr02'] == "") {
+                $address = lfGetAddress($_REQUEST['zip01'].$_REQUEST['zip02']);
+                $objPage->pref = @$address[0]['state'];
+                $objPage->addr01 = @$address[0]['city'] . @$address[0]['town'];
+            }
+        }
+
+        //-- ¥Ç¡¼¥¿ÀßÄê
+        unset($objPage->list_data);
+        if ($_POST["mode2"] == "set2") {
+            $checkVal = array("sex", "year", "month", "day", "zip01", "zip02");
+        } elseif ($_POST["mode2"] == "set3") {
+            $checkVal = array("pref", "addr01", "addr02", "tel01", "tel02", "tel03", "mail_flag");
+        } else {
+            $checkVal = array();
+        }
+
+        //$objPage->arrForm¥Õ¥©¡¼¥à¤ÎÃÍ¤òlist¤Ë³ÊÇ¼
+        foreach($objPage->arrForm as $key => $val) {
+            if ($key != "mode2" && $key != "submit" && $key != "confirm" && $key != "return" && $key != session_name() && !in_array($key, $checkVal)) {
+                $objPage->list_data[ $key ] = $val;
+            }
+        }
+        
+        //header("Location:" . gfAddSessionId("./deliv.php"));
+        
+    }
+    return $objPage;
+}
+
+
+/**
+ * regist data function
+ * 
+ * @param string $uniqid this parameter is unique ID of user. 
+ * 
+ * 
+ */
+ //¥Ç¡¼¥¿¤ÎÅÐÏ¿¤ò¹Ô¤¦
+function lfRegistData($uniqid) {
+    global $objFormParam;
+    $arrRet = $objFormParam->getHashArray();
+    $sqlval = $objFormParam->getDbArray();
+    
+    // ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+    $sqlval['order_temp_id'] = $uniqid;
+    $sqlval['order_birth'] = sfGetTimestamp($arrRet['year'], $arrRet['month'], $arrRet['day']);
+    $sqlval['update_date'] = 'Now()';
+    $sqlval['customer_id'] = '0';
+    $sqlval['order_name01'] = $objPage->arrAddr[0]['name01'];
+          
+    // ´ûÂ¸¥Ç¡¼¥¿¤Î¥Á¥§¥Ã¥¯
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $cnt = $objQuery->count("dtb_order_temp", $where, array($uniqid));
+    // ´ûÂ¸¥Ç¡¼¥¿¤¬¤Ê¤¤¾ì¹ç
+    if ($cnt == 0) {
+        $sqlval['create_date'] = 'Now()';
+        $objQuery->insert("dtb_order_temp", $sqlval);
+    } else {
+        $objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+    }
+}
+
+
+/* ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½ */
+function lfInitParam() {
+    global $objFormParam;
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "order_name01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "order_name02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "order_kana01", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "order_kana02", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "order_zip01", ZIP01_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "order_zip02", ZIP02_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "order_pref", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("½»½ê1", "order_addr01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("½»½ê2", "order_addr02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "order_tel01", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "order_tel02", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "order_tel03", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ1", "order_fax01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ2", "order_fax02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ3", "order_fax03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹", "order_email", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email_check", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"), "", false);
+    $objFormParam->addParam("Ç¯", "year", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("·î", "month", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("Æü", "day", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("À­ÊÌ", "order_sex", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("¿¦¶È", "order_job", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("ÊÌ¤Î¤ªÆÏ¤±Àè", "deliv_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "deliv_zip01", ZIP01_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "deliv_zip02", ZIP02_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "deliv_pref", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("½»½ê1", "deliv_addr01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("½»½ê2", "deliv_addr02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "deliv_tel01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "deliv_tel02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "deliv_tel03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥Þ¥¬¥¸¥ó", "mail_flag", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), 1);
+}
+
+/* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
+
+/* ÆþÎÏÆâÍÆ¤Î¥Á¥§¥Ã¥¯ */
+function lfCheckError() {
+    global $objFormParam;
+    // ÆþÎÏ¥Ç¡¼¥¿¤òÅÏ¤¹¡£
+    $arrRet =  $objFormParam->getHashArray();
+    $objErr = new SC_CheckError($arrRet);
+    $objErr->arrErr = $objFormParam->checkError();
+        
+    // ÊÌ¤Î¤ªÆÏ¤±Àè¥Á¥§¥Ã¥¯
+    if($_POST['deliv_check'] == "1") { 
+        $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "deliv_zip01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "deliv_zip02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", "deliv_pref"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("½»½ê1", "deliv_addr01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("½»½ê2", "deliv_addr02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", "deliv_tel01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", "deliv_tel02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", "deliv_tel03"), array("EXIST_CHECK"));
+    }
+    
+    // Ê£¿ô¹àÌÜ¥Á¥§¥Ã¥¯
+    $objErr->doFunc(array("TEL", "order_tel01", "order_tel02", "order_tel03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("FAX", "order_fax01", "order_fax02", "order_fax03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "order_zip01", "order_zip02"), array("ALL_EXIST_CHECK"));
+    $objErr->doFunc(array("TEL", "deliv_tel01", "deliv_tel02", "deliv_tel03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("FAX", "deliv_fax01", "deliv_fax02", "deliv_fax03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "deliv_zip01", "deliv_zip02"), array("ALL_EXIST_CHECK"));
+    $objErr->doFunc(array("À¸Ç¯·îÆü", "year", "month", "day"), array("CHECK_DATE"));
+    $objErr->doFunc(array("¥á¡¼¥ë¥¢¥É¥ì¥¹", "¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email", "order_email_check"), array("EQUAL_CHECK"));
+    
+    // ¤¹¤Ç¤Ë¥á¥ë¥Þ¥¬¥Æ¡¼¥Ö¥ë¤Ë²ñ°÷¤È¤·¤Æ¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¾ì¹ç
+    if(sfCheckCustomerMailMaga($arrRet['order_email'])) {
+        $objErr->arrErr['order_email'] = "¤³¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤Ï¤¹¤Ç¤ËÅÐÏ¿¤µ¤ì¤Æ¤¤¤Þ¤¹¡£<br>";
+    }
+        
+    return $objErr->arrErr;
+}
+
+
+//-----------------------------NONMEMBER´Ø¿ô·²¢§------------------------------------------------------------------
+//----¡¡¼èÆÀÊ¸»úÎó¤ÎÊÑ´¹
+function lfConvertParam($array, $arrRegistColumn) {
+    /*
+     *  Ê¸»úÎó¤ÎÊÑ´¹
+     *  K :  ¡ÖÈ¾³Ñ(ÊÝ¶¸)ÊÒ²¾Ì¾¡×¤ò¡ÖÁ´³ÑÊÒ²¾Ì¾¡×¤ËÊÑ´¹
+     *  C :  ¡ÖÁ´³Ñ¤Ò¤é²¾Ì¾¡×¤ò¡ÖÁ´³Ñ¤«¤¿²¾Ì¾¡×¤ËÊÑ´¹
+     *  V :  ÂùÅÀÉÕ¤­¤ÎÊ¸»ú¤ò°ìÊ¸»ú¤ËÊÑ´¹¡£"K","H"¤È¶¦¤Ë»ÈÍÑ¤·¤Þ¤¹ 
+     *  n :  ¡ÖÁ´³Ñ¡×¿ô»ú¤ò¡ÖÈ¾³Ñ(ÊÝ¶¸)¡×¤ËÊÑ´¹
+     *  a :  Á´³Ñ±Ñ¿ô»ú¤òÈ¾³Ñ±Ñ¿ô»ú¤ËÊÑ´¹¤¹¤ë
+     */
+    // ¥«¥é¥àÌ¾¤È¥³¥ó¥Ð¡¼¥È¾ðÊó
+    foreach ($arrRegistColumn as $data) {
+        $arrConvList[ $data["column"] ] = $data["convert"];
+    }
+    // Ê¸»úÊÑ´¹
+    foreach ($arrConvList as $key => $val) {
+        // POST¤µ¤ì¤Æ¤­¤¿ÃÍ¤Î¤ßÊÑ´¹¤¹¤ë¡£
+        if(strlen(($array[$key])) > 0) {
+            $array[$key] = mb_convert_kana($array[$key] ,$val);
+        }
+    }
+    return $array;
+}
+
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck1($array) {
+
+    global $objConn;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", 'name01', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", 'name02', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" , "MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/À«¡Ë", 'kana01', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK", "KANA_CHECK"));
+    $objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/Ì¾¡Ë", 'kana02', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK", "KANA_CHECK"));
+    $objErr->doFunc(array('¥á¡¼¥ë¥¢¥É¥ì¥¹', "email", MTEXT_LEN) ,array("NO_SPTAB", "EXIST_CHECK", "EMAIL_CHECK", "SPTAB_CHECK" ,"EMAIL_CHAR_CHECK", "MAX_LENGTH_CHECK", "MOBILE_EMAIL_CHECK"));
+
+    return $objErr->arrErr;
+}
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck2($array) {
+
+    global $objConn, $objDate;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "zip01", ZIP01_LEN ) ,array("EXIST_CHECK", "SPTAB_CHECK" ,"NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "zip02", ZIP02_LEN ) ,array("EXIST_CHECK", "SPTAB_CHECK" ,"NUM_CHECK", "NUM_COUNT_CHECK")); 
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "zip01", "zip02"), array("ALL_EXIST_CHECK"));
+
+    $objErr->doFunc(array("À­ÊÌ", "sex") ,array("SELECT_CHECK", "NUM_CHECK")); 
+    $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", 4), array("EXIST_CHECK", "SPTAB_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    if (!isset($objErr->arrErr['year'])) {
+        $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", $objDate->getStartYear()), array("MIN_CHECK"));
+        $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", $objDate->getEndYear()), array("MAX_CHECK"));
+    }
+    $objErr->doFunc(array("À¸Ç¯·îÆü (·îÆü)", "month", "day"), array("SELECT_CHECK"));
+    if (!isset($objErr->arrErr['year']) && !isset($objErr->arrErr['month']) && !isset($objErr->arrErr['day'])) {
+        $objErr->doFunc(array("À¸Ç¯·îÆü", "year", "month", "day"), array("CHECK_DATE"));
+    }
+    
+    return $objErr->arrErr;
+}
+
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck3($array) {
+
+    global $objConn;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", 'pref'), array("SELECT_CHECK","NUM_CHECK"));
+    $objErr->doFunc(array("»Ô¶èÄ®Â¼", "addr01", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("ÈÖÃÏ", "addr02", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", 'tel01'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", 'tel02'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", 'tel03'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ", "tel01", "tel02", "tel03",TEL_ITEM_LEN) ,array("TEL_CHECK"));
+    
+    return $objErr->arrErr;
+}
+
+// Í¹ÊØÈÖ¹æ¤«¤é½»½ê¤Î¼èÆÀ
+function lfGetAddress($zipcode) {
+    global $arrPref;
+
+    $conn = new SC_DBconn(ZIP_DSN);
+
+    // Í¹ÊØÈÖ¹æ¸¡º÷Ê¸ºîÀ®
+    $zipcode = mb_convert_kana($zipcode ,"n");
+    $sqlse = "SELECT state, city, town FROM mtb_zip WHERE zipcode = ?";
+
+    $data_list = $conn->getAll($sqlse, array($zipcode));
+
+    // ¥¤¥ó¥Ç¥Ã¥¯¥¹¤ÈÃÍ¤òÈ¿Å¾¤µ¤»¤ë¡£
+    $arrREV_PREF = array_flip($arrPref);
+
+    /*
+        ÁíÌ³¾Ê¤«¤é¥À¥¦¥ó¥í¡¼¥É¤·¤¿¥Ç¡¼¥¿¤ò¤½¤Î¤Þ¤Þ¥¤¥ó¥Ý¡¼¥È¤¹¤ë¤È
+        °Ê²¼¤Î¤è¤¦¤ÊÊ¸»úÎó¤¬Æþ¤Ã¤Æ¤¤¤ë¤Î¤Ç   ÂÐºö¤¹¤ë¡£
+        ¡¦¡Ê£±¡¦£±£¹ÃúÌÜ¡Ë
+        ¡¦°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç
+    */
+    $town =  $data_list[0]['town'];
+    $town = ereg_replace("¡Ê.*¡Ë$","",$town);
+    $town = ereg_replace("°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç","",$town);
+    $data_list[0]['town'] = $town;
+    $data_list[0]['state'] = $arrREV_PREF[$data_list[0]['state']];
+
+    return $data_list;
+}
+//NONMEMBER_´Ø¿ô·²---------------------------------------------------------------------------------------
+?>
Index: /branches/beta/html/mobile/nonmember/complete.php
===================================================================
--- /branches/beta/html/mobile/nonmember/complete.php	(revision 14676)
+++ /branches/beta/html/mobile/nonmember/complete.php	(revision 14676)
@@ -0,0 +1,510 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+require_once("../require.php");
+
+class LC_Page {
+	function LC_Page() {
+		$this->tpl_mainpage = 'shopping/complete.tpl';
+		$this->tpl_css = '/css/layout/shopping/complete.css';
+		$this->tpl_title = "¤´ÃíÊ¸´°Î»";
+		global $arrCONVENIENCE;
+		$this->arrCONVENIENCE = $arrCONVENIENCE;
+		global $arrCONVENIMESSAGE;
+		$this->arrCONVENIMESSAGE = $arrCONVENIMESSAGE;
+		global $arrCONVENIENCE;
+		global $arrCONVENIMESSAGE;
+		$objPage->arrCONVENIENCE = $arrCONVENIENCE;
+		$objPage->arrCONVENIMESSAGE = $arrCONVENIMESSAGE;
+		/*
+		 session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+		 ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+		 private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+		*/
+		session_cache_limiter('private-no-expire');		
+
+	}
+}
+
+$conn = new SC_DBConn();
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objSiteInfo = $objView->objSiteInfo;
+$arrInfo = $objSiteInfo->data;
+$objCustomer = new SC_Customer();
+
+// Á°¤Î¥Ú¡¼¥¸¤ÇÀµ¤·¤¯ÅÐÏ¿¼êÂ³¤­¤¬¹Ô¤ï¤ì¤¿¤«È½Äê
+sfIsPrePage($objSiteSess, true);
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+if ($uniqid != "") {
+	
+	// ´°Î»½èÍý
+	$objQuery = new SC_Query();
+	$objQuery->begin();
+	$order_id = lfDoComplete($objQuery, $uniqid);
+	$objQuery->commit();
+	
+	// ¥»¥Ã¥·¥ç¥ó¤ËÊÝ´É¤µ¤ì¤Æ¤¤¤ë¾ðÊó¤ò¹¹¿·¤¹¤ë
+	$objCustomer->updateSession();
+
+    // ´°Î»¥á¡¼¥ëÁ÷¿® 4¤Ï·ÈÂÓÈÇ
+    if($order_id != "") {
+        $order_email = $objQuery->select("order_email", "dtb_order", "order_id = ?", array($order_id));
+    
+    //ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬·ÈÂÓ¤«PC¤«¤Ë±þ¤¸¤ÆÃíÊ¸´°Î»¥á¡¼¥ë¤Î¥Æ¥ó¥×¥ì¡¼¥È¤òÊÑ¤¨¤ë
+    if(ereg("(ezweb.ne.jp$|docomo.ne.jp$|softbank.ne.jp$|vodafone.ne.jp$)",$order_email[0]['order_email'])){
+              sfSendOrderMail($order_id, '1');
+        }else{
+              sfSendOrderMail($order_id, '0');
+        }
+    }
+	//¤½¤ÎÂ¾¾ðÊó¤Î¼èÆÀ
+	$other_data = $objQuery->get("dtb_order", "memo02", "order_id = ? ", array($order_id));
+	if($other_data != "") {
+		$arrOther = unserialize($other_data);
+		
+		// ¥Ç¡¼¥¿¤òÊÔ½¸
+		foreach($arrOther as $key => $val){
+			// URL¤Î¾ì¹ç¤Ë¤Ï¥ê¥ó¥¯¤Ä¤­¤ÇÉ½¼¨¤µ¤»¤ë
+			if (preg_match('/^(https?|ftp)(:\/\/[-_.!~*\'()a-zA-Z0-9;\/?:\@&=+\$,%#]+)$/', $val["value"])) {
+				$arrOther[$key]["value"] = "<a href='#' onClick=\"window.open('". $val["value"] . "'); \" >" . $val["value"] ."</a>";
+			}
+		}
+				
+		$objPage->arrOther = $arrOther;
+		
+	}
+	
+	// ¥¢¥Õ¥£¥ê¥¨¥¤¥ÈÍÑ¥³¥ó¥Ð¡¼¥¸¥ç¥ó¥¿¥°¤ÎÀßÄê
+	$objPage->tpl_conv_page = AFF_SHOPPING_COMPLETE;
+	$objPage->tpl_aff_option = "order_id=$order_id";
+	//¹ç·×²Á³Ê¤Î¼èÆÀ
+	$total = $objQuery->get("dtb_order", "total", "order_id = ? ", array($order_id));
+	if($total != "") {
+		$objPage->tpl_aff_option.= "|total=$total";
+	}
+}
+
+$objPage->arrInfo = $arrInfo;
+
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+//--------------------------------------------------------------------------------------------------------------------------
+// ¥¨¥Ó¥¹¥¿¥°°úÅÏ¤·ÍÑ¥Ç¡¼¥¿¤òÀ¸À®¤¹¤ë
+function lfGetEbisData($order_id) {
+	$objQuery = new SC_Query();
+	$col = "customer_id, total, order_sex, order_job, to_number(to_char(age(current_timestamp, order_birth), 'YYY'), 999) AS order_age";
+	$arrRet = $objQuery->select($col, "dtb_order", "order_id = ?", array($order_id));
+	
+	if($arrRet[0]['customer_id'] > 0) {
+		// ²ñ°÷ÈÖ¹æ
+		$arrEbis['m1id'] = $arrRet[0]['customer_id'];
+		// Èó²ñ°÷or²ñ°÷
+		$arrEbis['o5id'] = '1';
+	} else {
+		// ²ñ°÷ÈÖ¹æ
+		$arrEbis['m1id'] = '';
+		// Èó²ñ°÷or²ñ°÷
+		$arrEbis['o5id'] = '2';	
+	}
+	
+	// ¹ØÆþ¶â³Û
+	$arrEbis['a1id'] = $arrRet[0]['total'];
+	// À­ÊÌ
+	$arrEbis['o2id'] = $arrRet[0]['order_sex'];
+	// Ç¯Îð
+	$arrEbis['o3id'] = $arrRet[0]['order_age'];
+	// ¿¦¶È
+	$arrEbis['o4id'] = $arrRet[0]['order_job'];
+		
+	$objQuery->setgroupby("product_id");
+	$arrRet = $objQuery->select("product_id", "dtb_order_detail", "order_id = ?", array($order_id));
+	$arrProducts = sfSwapArray($arrRet);
+	
+	$line = "";
+	// ¾¦ÉÊID¤ò¥¢¥ó¥À¡¼¥Ð¡¼¤ÇÀÜÂ³¤¹¤ë¡£
+	foreach($arrProducts['product_id'] as $val) {
+		if($line != "") {
+			$line .= "_$val";		
+		} else {
+			$line .= "$val";
+		}
+	}
+	
+	// ¾¦ÉÊID	
+	$arrEbis['o1id'] = $line;
+	
+	return $arrEbis;
+}
+
+// ´°Î»½èÍý
+function lfDoComplete($objQuery, $uniqid) {
+	global $objCartSess;
+	global $objSiteSess;
+	global $objCustomer;
+	global $arrInfo;
+	
+	// °ì»þ¼õÃí¥Æ¡¼¥Ö¥ë¤ÎÆÉ¹þ
+	$arrData = sfGetOrderTemp($uniqid);
+	
+	// ²ñ°÷¾ðÊóÅÐÏ¿½èÍý
+	if ($objCustomer->isLoginSuccess()) {
+		// ¿·¤ªÆÏ¤±Àè¤ÎÅÐÏ¿
+		lfSetNewAddr($uniqid, $objCustomer->getValue('customer_id'));
+		// ¹ØÆþ½¸·×¤ò¸ÜµÒ¥Æ¡¼¥Ö¥ë¤ËÈ¿±Ç
+		lfSetCustomerPurchase($objCustomer->getValue('customer_id'), $arrData, $objQuery);
+	} else {
+		//¹ØÆþ»þ¶¯À©²ñ°÷ÅÐÏ¿
+		switch(PURCHASE_CUSTOMER_REGIST) {
+		//Ìµ¸ú
+		case '0':
+			// ¹ØÆþ»þ²ñ°÷ÅÐÏ¿
+			if($arrData['member_check'] == '1') {
+				// ²¾²ñ°÷ÅÐÏ¿
+				$customer_id = lfRegistPreCustomer($arrData, $arrInfo);
+				// ¹ØÆþ½¸·×¤ò¸ÜµÒ¥Æ¡¼¥Ö¥ë¤ËÈ¿±Ç
+				lfSetCustomerPurchase($customer_id, $arrData, $objQuery);
+			}
+			break;
+		//Í­¸ú
+		case '1':
+			// ²¾²ñ°÷ÅÐÏ¿
+			$customer_id = lfRegistPreCustomer($arrData, $arrInfo);
+			// ¹ØÆþ½¸·×¤ò¸ÜµÒ¥Æ¡¼¥Ö¥ë¤ËÈ¿±Ç
+			lfSetCustomerPurchase($customer_id, $arrData, $objQuery);
+			break;
+		}
+		
+	}
+	// °ì»þ¥Æ¡¼¥Ö¥ë¤ò¼õÃí¥Æ¡¼¥Ö¥ë¤Ë³ÊÇ¼¤¹¤ë
+	$order_id = lfRegistOrder($objQuery, $arrData);
+	// ¥«¡¼¥È¾¦ÉÊ¤ò¼õÃí¾ÜºÙ¥Æ¡¼¥Ö¥ë¤Ë³ÊÇ¼¤¹¤ë
+	lfRegistOrderDetail($objQuery, $order_id, $objCartSess);
+	// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Î¾ðÊó¤òºï½ü¤¹¤ë¡£
+	lfDeleteTempOrder($objQuery, $uniqid);
+	
+	// ¥»¥Ã¥·¥ç¥ó¥«¡¼¥ÈÆâ¤Î¾¦ÉÊ¤òºï½ü¤¹¤ë¡£
+	$objCartSess->delAllProducts();
+	// ÃíÊ¸°ì»þID¤ò²ò½ü¤¹¤ë¡£
+	$objSiteSess->unsetUniqId();
+	
+	return $order_id;
+}
+
+// ²ñ°÷ÅÐÏ¿¡Ê²¾ÅÐÏ¿¡Ë
+function lfRegistPreCustomer($arrData, $arrInfo) {
+	// ¹ØÆþ»þ¤Î²ñ°÷ÅÐÏ¿
+	$sqlval['name01'] = $arrData['order_name01'];
+	$sqlval['name02'] = $arrData['order_name02'];
+	$sqlval['kana01'] = $arrData['order_kana01'];
+	$sqlval['kana02'] = $arrData['order_kana02'];
+	$sqlval['zip01'] = $arrData['order_zip01'];
+	$sqlval['zip02'] = $arrData['order_zip02'];
+	$sqlval['pref'] = $arrData['order_pref'];
+	$sqlval['addr01'] = $arrData['order_addr01'];
+	$sqlval['addr02'] = $arrData['order_addr02'];
+	$sqlval['email'] = $arrData['order_email'];
+	$sqlval['tel01'] = $arrData['order_tel01'];
+	$sqlval['tel02'] = $arrData['order_tel02'];
+	$sqlval['tel03'] = $arrData['order_tel03'];
+	$sqlval['fax01'] = $arrData['order_fax01'];
+	$sqlval['fax02'] = $arrData['order_fax02'];
+	$sqlval['fax03'] = $arrData['order_fax03'];
+	$sqlval['sex'] = $arrData['order_sex'];
+	$sqlval['password'] = $arrData['password'];
+	$sqlval['reminder'] = $arrData['reminder'];
+	$sqlval['reminder_answer'] = $arrData['reminder_answer'];
+
+	// ¥á¥ë¥Þ¥¬ÇÛ¿®ÍÑ¥Õ¥é¥°¤ÎÈ½Äê
+	switch($arrData['mail_flag']) {
+	case '1':	// HTML¥á¡¼¥ë
+		$mail_flag = 4;
+		break;
+	case '2':	// TEXT¥á¡¼¥ë
+		$mail_flag = 5;
+		break;
+	case '3':	// ´õË¾¤Ê¤·
+		$mail_flag = 6;
+		break;
+	default:
+		$mail_flag = 6;
+		break;
+	}
+	$sqlval['mailmaga_flg'] = $mail_flag;
+		
+	// ²ñ°÷²¾ÅÐÏ¿
+	$sqlval['status'] = 1;
+	// URLÈ½ÄêÍÑ¥­¡¼
+	$sqlval['secret_key'] = sfGetUniqRandomId("t"); 
+	
+	$objQuery = new SC_Query();
+	$sqlval['create_date'] = "now()";
+	$sqlval['update_date'] = "now()";
+	$objQuery->insert("dtb_customer", $sqlval);
+	
+	// ¸ÜµÒID¤Î¼èÆÀ
+	$arrRet = $objQuery->select("customer_id", "dtb_customer", "secret_key = ?", array($sqlval['secret_key']));
+	$customer_id = $arrRet[0]['customer_id'];
+
+	//¡¡²¾ÅÐÏ¿´°Î»¥á¡¼¥ëÁ÷¿®
+	$objMailPage = new LC_Page();
+	$objMailPage->to_name01 = $arrData['order_name01'];
+	$objMailPage->to_name02 = $arrData['order_name02'];
+	$objMailPage->CONF = $arrInfo;
+	$objMailPage->uniqid = $sqlval['secret_key'];
+	$objMailView = new SC_SiteView();
+	$objMailView->assignobj($objMailPage);
+	$body = $objMailView->fetch("mail_templates/customer_mail.tpl");
+	
+	$objMail = new GC_SendMail();
+	$objMail->setItem(
+						''										//¡¡°¸Àè
+						, sfMakeSubject("²ñ°÷ÅÐÏ¿¤Î¤´³ÎÇ§")		//¡¡¥µ¥Ö¥¸¥§¥¯¥È
+						, $body									//¡¡ËÜÊ¸
+						, $arrInfo['email03']					//¡¡ÇÛÁ÷¸µ¥¢¥É¥ì¥¹
+						, $arrInfo['shop_name']					//¡¡ÇÛÁ÷¸µ¡¡Ì¾Á°
+						, $arrInfo["email03"]					//¡¡reply_to
+						, $arrInfo["email04"]					//¡¡return_path
+						, $arrInfo["email04"]					//  Errors_to
+						, $arrInfo["email01"]					//  Bcc
+														);
+	// °¸Àè¤ÎÀßÄê
+	$name = $arrData['order_name01'] . $arrData['order_name02'] ." ÍÍ";
+	$objMail->setTo($arrData['order_email'], $name);			
+	$objMail->sendMail();
+	
+	return $customer_id;
+}
+
+// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Î¤ªÆÏ¤±Àè¤ò¥³¥Ô¡¼¤¹¤ë
+function lfCopyDeliv($uniqid, $arrData) {
+	$objQuery = new SC_Query();
+	
+	// ÊÌ¤Î¤ªÆÏ¤±Àè¤ò»ØÄê¤·¤Æ¤¤¤Ê¤¤¾ì¹ç¡¢ÇÛÁ÷Àè¤ËÅÐÏ¿½»½ê¤ò¥³¥Ô¡¼¤¹¤ë¡£
+	if($arrData["deliv_check"] != "1") {
+		$sqlval['deliv_name01'] = $arrData['order_name01'];
+		$sqlval['deliv_name02'] = $arrData['order_name02'];
+		$sqlval['deliv_kana01'] = $arrData['order_kana01'];
+		$sqlval['deliv_kana02'] = $arrData['order_kana02'];
+		$sqlval['deliv_pref'] = $arrData['order_pref'];
+		$sqlval['deliv_zip01'] = $arrData['order_zip01'];
+		$sqlval['deliv_zip02'] = $arrData['order_zip02'];
+		$sqlval['deliv_addr01'] = $arrData['order_addr01'];
+		$sqlval['deliv_addr02'] = $arrData['order_addr02'];
+		$sqlval['deliv_tel01'] = $arrData['order_tel01'];
+		$sqlval['deliv_tel02'] = $arrData['order_tel02'];
+		$sqlval['deliv_tel03'] = $arrData['order_tel03'];
+		$where = "order_temp_id = ?";
+		$objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+	}
+}
+
+// ¼õÃí¥Æ¡¼¥Ö¥ë¤ØÅÐÏ¿
+function lfRegistOrder($objQuery, $arrData) {
+	$sqlval = $arrData;
+
+	// ¼õÃí¥Æ¡¼¥Ö¥ë¤Ë½ñ¤­¹þ¤Þ¤Ê¤¤Îó¤ò½üµî
+	unset($sqlval['mail_flag']);		// ¥á¥ë¥Þ¥¬¥Á¥§¥Ã¥¯
+	unset($sqlval['deliv_check']);		// ÊÌ¤Î¤ªÆÏ¤±Àè¥Á¥§¥Ã¥¯
+	unset($sqlval['point_check']);		// ¥Ý¥¤¥ó¥ÈÍøÍÑ¥Á¥§¥Ã¥¯
+	unset($sqlval['member_check']);		// ¹ØÆþ»þ²ñ°÷¥Á¥§¥Ã¥¯
+	unset($sqlval['password']);			// ¥í¥°¥¤¥ó¥Ñ¥¹¥ï¡¼¥É
+	unset($sqlval['reminder']);			// ¥ê¥Þ¥¤¥ó¥À¡¼¼ÁÌä
+	unset($sqlval['reminder_answer']);	// ¥ê¥Þ¥¤¥ó¥À¡¼Åú¤¨
+
+	// ÃíÊ¸¥¹¥Æ¡¼¥¿¥¹:»ØÄê¤¬Ìµ¤±¤ì¤Ð¿·µ¬¼õÉÕ¤ËÀßÄê
+	if($sqlval["status"] == ""){
+		$sqlval['status'] = '1';			
+	}
+	
+	// ÊÌ¤Î¤ªÆÏ¤±Àè¤ò»ØÄê¤·¤Æ¤¤¤Ê¤¤¾ì¹ç¡¢ÇÛÁ÷Àè¤ËÅÐÏ¿½»½ê¤ò¥³¥Ô¡¼¤¹¤ë¡£
+	if($arrData["deliv_check"] != "1") {
+		$sqlval['deliv_name01'] = $arrData['order_name01'];
+		$sqlval['deliv_name02'] = $arrData['order_name02'];
+		$sqlval['deliv_kana01'] = $arrData['order_kana01'];
+		$sqlval['deliv_kana02'] = $arrData['order_kana02'];
+		$sqlval['deliv_pref'] = $arrData['order_pref'];
+		$sqlval['deliv_zip01'] = $arrData['order_zip01'];
+		$sqlval['deliv_zip02'] = $arrData['order_zip02'];
+		$sqlval['deliv_addr01'] = $arrData['order_addr01'];
+		$sqlval['deliv_addr02'] = $arrData['order_addr02'];
+		$sqlval['deliv_tel01'] = $arrData['order_tel01'];
+		$sqlval['deliv_tel02'] = $arrData['order_tel02'];
+		$sqlval['deliv_tel03'] = $arrData['order_tel03'];
+	}
+	
+	$order_id = $arrData['order_id'];		// ¥ª¡¼¥À¡¼ID
+	$sqlval['create_date'] = 'now()';		// ¼õÃíÆü
+	
+	// ¥²¥Ã¥È¤ÎÃÍ¤ò¥¤¥ó¥µ¡¼¥È
+	//$sqlval = lfGetInsParam($sqlval);
+	
+	// INSERT¤Î¼Â¹Ô
+	$objQuery->insert("dtb_order", $sqlval);
+
+	return $order_id;
+}
+
+// ¼õÃí¾ÜºÙ¥Æ¡¼¥Ö¥ë¤ØÅÐÏ¿
+function lfRegistOrderDetail($objQuery, $order_id, $objCartSess) {
+	// ¥«¡¼¥ÈÆâ¾ðÊó¤Î¼èÆÀ
+	$arrCart = $objCartSess->getCartList();
+	$max = count($arrCart);
+	
+	// ´û¤ËÂ¸ºß¤¹¤ë¾ÜºÙ¥ì¥³¡¼¥É¤ò¾Ã¤·¤Æ¤ª¤¯¡£
+	$objQuery->delete("dtb_order_detail", "order_id = $order_id");
+
+	// µ¬³ÊÌ¾°ìÍ÷
+	$arrClassName = sfGetIDValueList("dtb_class", "class_id", "name");
+	// µ¬³ÊÊ¬ÎàÌ¾°ìÍ÷
+	$arrClassCatName = sfGetIDValueList("dtb_classcategory", "classcategory_id", "name");
+			
+	for ($i = 0; $i < $max; $i++) {
+		// ¾¦ÉÊµ¬³Ê¾ðÊó¤Î¼èÆÀ	
+		$arrData = sfGetProductsClass($arrCart[$i]['id']);
+		
+		// Â¸ºß¤¹¤ë¾¦ÉÊ¤Î¤ßÉ½¼¨¤¹¤ë¡£
+		if($arrData != "") {
+			$sqlval['order_id'] = $order_id;
+			$sqlval['product_id'] = $arrCart[$i]['id'][0];
+			$sqlval['classcategory_id1'] = $arrCart[$i]['id'][1];
+			$sqlval['classcategory_id2'] = $arrCart[$i]['id'][2];
+			$sqlval['product_name'] = $arrData['name'];
+			$sqlval['product_code'] = $arrData['product_code'];
+			$sqlval['classcategory_name1'] = $arrClassCatName[$arrData['classcategory_id1']];
+			$sqlval['classcategory_name2'] = $arrClassCatName[$arrData['classcategory_id2']];
+			$sqlval['point_rate'] = $arrCart[$i]['point_rate'];			
+			$sqlval['price'] = $arrCart[$i]['price'];
+			$sqlval['quantity'] = $arrCart[$i]['quantity'];
+			lfReduceStock($objQuery, $arrCart[$i]['id'], $arrCart[$i]['quantity']);
+			// INSERT¤Î¼Â¹Ô
+			$objQuery->insert("dtb_order_detail", $sqlval);
+		} else {
+			sfDispSiteError(CART_NOT_FOUND, "", false, "", true);
+		}
+	}
+}
+
+/* ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Îºï½ü */
+function lfDeleteTempOrder($objQuery, $uniqid) {
+	$where = "order_temp_id = ?";
+	$sqlval['del_flg'] = 1;
+	$objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+	// $objQuery->delete("dtb_order_temp", $where, array($uniqid));
+}
+
+// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Î½»½ê¤¬ÅÐÏ¿ºÑ¤ß¥Æ¡¼¥Ö¥ë¤È°Û¤Ê¤ë¾ì¹ç¤Ï¡¢ÊÌ¤Î¤ªÆÏ¤±Àè¤ËÄÉ²Ã¤¹¤ë
+function lfSetNewAddr($uniqid, $customer_id) {
+	$objQuery = new SC_Query();
+	$diff = false;
+	$find_same = false;
+	
+	$col = "deliv_name01,deliv_name02,deliv_kana01,deliv_kana02,deliv_tel01,deliv_tel02,deliv_tel03,deliv_zip01,deliv_zip02,deliv_pref,deliv_addr01,deliv_addr02";
+	$where = "order_temp_id = ?";
+	$arrRet = $objQuery->select($col, "dtb_order_temp", $where, array($uniqid));
+	
+	// Í×ÁÇÌ¾¤Îdeliv_¤òºï½ü¤¹¤ë¡£
+	foreach($arrRet[0] as $key => $val) {
+		$keyname = ereg_replace("^deliv_", "", $key);
+		$arrNew[$keyname] = $val;
+	}
+	
+	// ²ñ°÷¾ðÊó¥Æ¡¼¥Ö¥ë¤È¤ÎÈæ³Ó
+	$col = "name01,name02,kana01,kana02,tel01,tel02,tel03,zip01,zip02,pref,addr01,addr02";
+	$where = "customer_id = ?";
+	$arrCustomerAddr = $objQuery->select($col, "dtb_customer", $where, array($customer_id));
+	
+	// ²ñ°÷¾ðÊó¤Î½»½ê¤È°Û¤Ê¤ë¾ì¹ç
+	if($arrNew != $arrCustomerAddr[0]) {
+		// ÊÌ¤Î¤ªÆÏ¤±Àè¥Æ¡¼¥Ö¥ë¤Î½»½ê¤ÈÈæ³Ó¤¹¤ë
+		$col = "name01,name02,kana01,kana02,tel01,tel02,tel03,zip01,zip02,pref,addr01,addr02";
+		$where = "customer_id = ?";
+		$arrOtherAddr = $objQuery->select($col, "dtb_other_deliv", $where, array($customer_id));
+
+		foreach($arrOtherAddr as $arrval) {
+			if($arrNew == $arrval) {
+				// ¤¹¤Ç¤ËÆ±¤¸½»½ê¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë
+				$find_same = true;
+			}
+		}
+		
+		if(!$find_same) {
+			$diff = true;
+		}
+	}
+	
+	// ¿·¤·¤¤¤ªÆÏ¤±Àè¤¬ÅÐÏ¿ºÑ¤ß¤Î¤â¤Î¤È°Û¤Ê¤ë¾ì¹ç¤ÏÊÌ¤Î¤ªÆÏ¤±Àè¥Æ¡¼¥Ö¥ë¤ËÅÐÏ¿¤¹¤ë
+	if($diff) {
+		$sqlval = $arrNew;
+		$sqlval['customer_id'] = $customer_id;
+		$objQuery->insert("dtb_other_deliv", $sqlval);
+	}
+}
+
+/* ¹ØÆþ¾ðÊó¤ò²ñ°÷¥Æ¡¼¥Ö¥ë¤ËÅÐÏ¿¤¹¤ë */
+function lfSetCustomerPurchase($customer_id, $arrData, $objQuery) {
+	$col = "first_buy_date, last_buy_date, buy_times, buy_total, point";
+	$where = "customer_id = ?";
+	$arrRet = $objQuery->select($col, "dtb_customer", $where, array($customer_id));
+	$sqlval = $arrRet[0];
+	
+	if($sqlval['first_buy_date'] == "") {
+		$sqlval['first_buy_date'] = "Now()";
+	}
+	$sqlval['last_buy_date'] = "Now()";
+	$sqlval['buy_times']++;
+	$sqlval['buy_total']+= $arrData['total'];
+	$sqlval['point'] = ($sqlval['point'] + $arrData['add_point'] - $arrData['use_point']);
+	
+	// ¥Ý¥¤¥ó¥È¤¬ÉÔÂ­¤·¤Æ¤¤¤ë¾ì¹ç
+	if($sqlval['point'] < 0) {
+		$objQuery->rollback();
+		sfDispSiteError(LACK_POINT);
+	}
+	
+	$objQuery->update("dtb_customer", $sqlval, $where, array($customer_id));
+}
+
+// ºß¸Ë¤ò¸º¤é¤¹½èÍý
+function lfReduceStock($objQuery, $arrID, $quantity) {
+	$where = "product_id = ? AND classcategory_id1 = ? AND classcategory_id2 = ?";
+	$arrRet = $objQuery->select("stock, stock_unlimited", "dtb_products_class", $where, $arrID);
+	
+	// Çä¤êÀÚ¤ì¥¨¥é¡¼
+	if(($arrRet[0]['stock_unlimited'] != '1' && $arrRet[0]['stock'] < $quantity) || $quantity == 0) {
+		$objQuery->rollback();
+		sfDispSiteError(SOLD_OUT, "", true);
+	// ÌµÀ©¸Â¤Î¾ì¹ç¡¢ºß¸Ë¤ÏNULL
+	} elseif($arrRet[0]['stock_unlimited'] == '1') {
+		$sqlval['stock'] = null;
+		$objQuery->update("dtb_products_class", $sqlval, $where, $arrID);
+	// ºß¸Ë¤ò¸º¤é¤¹
+	} else {
+		$sqlval['stock'] = ($arrRet[0]['stock'] - $quantity);
+		if($sqlval['stock'] == "") {
+			$sqlval['stock'] = '0';
+		}		
+		$objQuery->update("dtb_products_class", $sqlval, $where, $arrID);
+	}
+}
+
+// GET¤ÎÃÍ¤ò¥¤¥ó¥µ¡¼¥ÈÍÑ¤ËÀ°¤¨¤ë
+function lfGetInsParam($sqlVal){
+	
+	foreach($_GET as $key => $val){
+		// ¥«¥é¥à¤ÎÂ¸ºß¥Á¥§¥Ã¥¯
+		if(sfColumnExists("dtb_order", $key)) $sqlVal[$key] = $val;
+	}
+	
+	return $sqlVal;
+}
+
+?>
Index: /branches/beta/html/mobile/mypage/index.php
===================================================================
--- /branches/beta/html/mobile/mypage/index.php	(revision 11889)
+++ /branches/beta/html/mobile/mypage/index.php	(revision 14676)
@@ -59,5 +59,5 @@
 
 			// ·ÈÂÓ¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤ò¥³¥Ô¡¼¤¹¤ë¡£
-			$objCustomer->updateEmailMobile();
+			// $objCustomer->updateEmailMobile();
 
 			// ·ÈÂÓ¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤Ê¤¤¾ì¹ç
Index: /branches/beta/html/mobile/shopping/confirm.php
===================================================================
--- /branches/beta/html/mobile/shopping/confirm.php	(revision 11893)
+++ /branches/beta/html/mobile/shopping/confirm.php	(revision 14676)
@@ -15,5 +15,5 @@
 	var $tpl_total_deliv_fee;
 	function LC_Page() {
-		$this->tpl_mainpage = 'shopping/confirm.tpl';
+		$this->tpl_mainpage = 'nonmember/confirm.tpl';
 		$this->tpl_css = '/css/layout/shopping/confirm.css';
 		$this->tpl_title = "¤´ÆþÎÏÆâÍÆ¤Î¤´³ÎÇ§";
@@ -70,9 +70,11 @@
 // ·èºÑ¶èÊ¬¤ò¼èÆÀ¤¹¤ë
 $payment_type = "";
+$module_id = "";
 if(sfColumnExists("dtb_payment", "memo01")){
 	// MEMO03¤ËÃÍ¤¬Æþ¤Ã¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢¥â¥¸¥å¡¼¥ëÄÉ²Ã¤µ¤ì¤¿¤â¤Î¤È¤ß¤Ê¤¹
-	$sql = "SELECT memo03 FROM dtb_payment WHERE payment_id = ?";
+	$sql = "SELECT module_id,memo03 FROM dtb_payment WHERE payment_id = ?";
 	$arrPayment = $objQuery->getall($sql, array($arrData['payment_id']));
 	$payment_type = $arrPayment[0]["memo03"];
+    $module_id =  $arrPayment[0]["module_id"];    
 }
 $objPage->payment_type = $payment_type;
@@ -103,5 +105,5 @@
 	
 	// ·èºÑÊýË¡¤Ë¤è¤ê²èÌÌÀÚÂØ
-	if($payment_type != "") {
+	if(!empty($module_id)) {
 		$_SESSION["payment_id"] = $arrData['payment_id'];
 		header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_MODULE));
Index: /branches/beta/html/mobile/shopping/payment.php
===================================================================
--- /branches/beta/html/mobile/shopping/payment.php	(revision 11908)
+++ /branches/beta/html/mobile/shopping/payment.php	(revision 14676)
@@ -47,9 +47,13 @@
 $objPage->tpl_uniqid = $uniqid;
 
-// ²ñ°÷¥í¥°¥¤¥ó¥Á¥§¥Ã¥¯
 if($objCustomer->isLoginSuccess()) {
-	$objPage->tpl_login = '1';
-	$objPage->tpl_user_point = $objCustomer->getValue('point');
-}
+    $objPage->tpl_login = '1';
+    $objPage->tpl_user_point = $objCustomer->getValue('point');
+    //Ìá¤êÀèURL
+    $objPage->tpl_back_url = URL_DELIV_TOP;
+} else {
+    $objPage->tpl_back_url = URL_SHOP_TOP . "?from=nonmember";
+}
+
 
 // ¶â³Û¤Î¼èÆÀ (¹ØÆþÅÓÃæ¤ÇÇä¤êÀÚ¤ì¤¿¾ì¹ç¤Ë¤Ï¤³¤Î´Ø¿ôÆâ¤Ë¤Æ¤½¤Î¾¦ÉÊ¤Î¸Ä¿ô¤¬£°¤Ë¤Ê¤ë)
@@ -57,5 +61,5 @@
 $objPage->arrData = sfTotalConfirm($arrData, $objPage, $objCartSess, $arrInfo);
 
-// ¥«¡¼ÅÔÆâ¤Î¾¦ÉÊ¤ÎÇä¤êÀÚ¤ì¥Á¥§¥Ã¥¯
+// ¥«¡¼¥ÈÆâ¤Î¾¦ÉÊ¤ÎÇä¤êÀÚ¤ì¥Á¥§¥Ã¥¯
 $objCartSess->chkSoldOut($objCartSess->getCartList(), true);
 
@@ -77,4 +81,5 @@
 // »ÙÊ§¤¤ÊýË¡»ØÄê ¢ª ÇÛÃ£Æü»þ»ØÄê
 case 'deliv_date':
+	
 	// ÆþÎÏÃÍ¤ÎÊÑ´¹
 	$objFormParam->convParam();
@@ -238,4 +243,5 @@
 /* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
 function lfRegistData($uniqid) {
+    
 	global $objFormParam;
 	$arrRet = $objFormParam->getHashArray();
@@ -266,4 +272,5 @@
 	
 	sfRegistTempOrder($uniqid, $sqlval);
+   
 }
 
Index: /branches/beta/html/mobile/shopping/nonmember_payment.php
===================================================================
--- /branches/beta/html/mobile/shopping/nonmember_payment.php	(revision 14676)
+++ /branches/beta/html/mobile/shopping/nonmember_payment.php	(revision 14676)
@@ -0,0 +1,380 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+	var $arrSession;
+	var $tpl_mode;
+	function LC_Page() {
+		$this->tpl_css = '/css/layout/shopping/pay.css';
+		$this->tpl_mainpage = 'shopping/payment.tpl';
+		$this->tpl_onload = 'fnCheckInputPoint();';
+		$this->tpl_title = "¤ª»ÙÊ§ÊýË¡¤Î»ØÄê";
+		/*
+		 session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+		 ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+		 private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+		*/
+		session_cache_limiter('private-no-expire');		
+	}
+}
+
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objSiteSess = new SC_SiteSession();
+$objCartSess = new SC_CartSession();
+$objCustomer = new SC_Customer();
+$objSiteInfo = $objView->objSiteInfo;
+$arrInfo = $objSiteInfo->data;
+
+// ¥Ñ¥é¥á¡¼¥¿´ÉÍý¥¯¥é¥¹
+$objFormParam = new SC_FormParam();
+// ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+lfInitParam();
+// POSTÃÍ¤Î¼èÆÀ
+print_r($_POST);
+$objFormParam->setParam($_POST);
+
+// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
+$uniqid = sfCheckNormalAccess($objSiteSess, $objCartSess);
+// ¥æ¥Ë¡¼¥¯ID¤ò°ú¤­·Ñ¤°
+$objPage->tpl_uniqid = $uniqid;
+
+if($objCustomer->isLoginSuccess()) {
+    $objPage->tpl_login = '1';
+    $objPage->tpl_user_point = $objCustomer->getValue('point');
+    //Ìá¤êÀèURL
+    $objPage->tpl_back_url = URL_DELIV_TOP;
+} else {
+    $objPage->tpl_back_url = URL_SHOP_TOP . "?from=nonmember";
+}
+
+
+// ¶â³Û¤Î¼èÆÀ (¹ØÆþÅÓÃæ¤ÇÇä¤êÀÚ¤ì¤¿¾ì¹ç¤Ë¤Ï¤³¤Î´Ø¿ôÆâ¤Ë¤Æ¤½¤Î¾¦ÉÊ¤Î¸Ä¿ô¤¬£°¤Ë¤Ê¤ë)
+$objPage = sfTotalCart($objPage, $objCartSess, $arrInfo);
+$objPage->arrData = sfTotalConfirm($arrData, $objPage, $objCartSess, $arrInfo);
+
+// ¥«¡¼¥ÈÆâ¤Î¾¦ÉÊ¤ÎÇä¤êÀÚ¤ì¥Á¥§¥Ã¥¯
+$objCartSess->chkSoldOut($objCartSess->getCartList(), true);
+
+// Ìá¤ë¥Ü¥¿¥ó¤Î½èÍý
+if (!empty($_POST['return'])) {
+	switch ($_POST['mode']) {
+	case 'confirm':
+		$_POST['mode'] = 'payment';
+		break;
+	default:
+		// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+		$objSiteSess->setRegistFlag();
+		header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_TOP));
+		exit;
+	}
+}
+
+switch($_POST['mode']) {
+// »ÙÊ§¤¤ÊýË¡»ØÄê ¢ª ÇÛÃ£Æü»þ»ØÄê
+case 'deliv_date':
+	$objFormParam->setParam($_POST);
+	
+	// ÆþÎÏÃÍ¤ÎÊÑ´¹
+	$objFormParam->convParam();
+	$objPage->arrErr = lfCheckError($objPage->arrData);
+	if (!isset($objPage->arrErr['payment_id'])) {
+		// »ÙÊ§¤¤ÊýË¡¤ÎÆþÎÏ¥¨¥é¡¼¤Ê¤·
+		$objPage->tpl_mainpage = 'shopping/deliv_date.tpl';
+		$objPage->tpl_title = "ÇÛÃ£Æü»þ»ØÄê";
+		break;
+	} else {
+		// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+		$uniqid = $objSiteSess->getUniqId();
+		// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+		lfSetOrderTempData($uniqid);
+	}
+	break;
+case 'confirm':
+	// ÆþÎÏÃÍ¤ÎÊÑ´¹
+	$objFormParam->convParam();
+	$objPage->arrErr = lfCheckError($objPage->arrData );
+	// ÆþÎÏ¥¨¥é¡¼¤Ê¤·
+	if(count($objPage->arrErr) == 0) {
+		// DB¤Ø¤Î¥Ç¡¼¥¿ÅÐÏ¿
+		lfRegistData($uniqid);
+		// Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+		$objSiteSess->setRegistFlag();
+		// ³ÎÇ§¥Ú¡¼¥¸¤Ø°ÜÆ°
+		header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_CONFIRM));
+		exit;
+	}else{
+		// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+		$uniqid = $objSiteSess->getUniqId();
+		// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+		lfSetOrderTempData($uniqid);
+		if (!isset($objPage->arrErr['payment_id'])) {
+			// »ÙÊ§¤¤ÊýË¡¤ÎÆþÎÏ¥¨¥é¡¼¤Ê¤·
+			$objPage->tpl_mainpage = 'shopping/deliv_date.tpl';
+			$objPage->tpl_title = "ÇÛÃ£Æü»þ»ØÄê";
+		}
+	}
+	break;
+// Á°¤Î¥Ú¡¼¥¸¤ËÌá¤ë
+case 'return':
+	// Èó²ñ°÷¤Î¾ì¹ç
+	// Àµ¾ï¤Ê¿ä°Ü¤Ç¤¢¤ë¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+	$objSiteSess->setRegistFlag();
+	header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_TOP));
+	exit;
+	break;
+// »ÙÊ§¤¤ÊýË¡¤¬ÊÑ¹¹¤µ¤ì¤¿¾ì¹ç
+case 'payment':
+	// ¤³¤³¤Îbreak¤Ï¡¢°ÕÌ£¤¬¤¢¤ë¤Î¤Ç³°¤µ¤Ê¤¤¤Ç²¼¤µ¤¤¡£
+	break;
+default:
+	// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼
+	lfSetOrderTempData($uniqid);
+	break;
+}
+
+// Å¹ÊÞ¾ðÊó¤Î¼èÆÀ
+$arrInfo = $objSiteInfo->data;
+// ¹ØÆþ¶â³Û¤Î¼èÆÀÆÀ
+$total_pretax = $objCartSess->getAllProductsTotal($arrInfo);
+// »ÙÊ§¤¤ÊýË¡¤Î¼èÆÀ
+$objPage->arrPayment = lfGetPayment($total_pretax);
+// ÇÛÁ÷»þ´Ö¤Î¼èÆÀ
+$arrRet = sfGetDelivTime($objFormParam->getValue('payment_id'));
+$objPage->arrDelivTime = sfArrKeyValue($arrRet, 'time_id', 'deliv_time');
+$objPage->objCustomer = $objCustomer;
+//¡¡ÇÛÁ÷Æü°ìÍ÷¤Î¼èÆÀ
+$objPage->arrDelivDate = lfGetDelivDate();
+
+$objPage->arrForm = $objFormParam->getFormParamList();
+
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+//--------------------------------------------------------------------------------------------------------------------------
+/* ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½ */
+function lfInitParam() {
+	global $objFormParam;
+	$objFormParam->addParam("¤ª»ÙÊ§¤¤ÊýË¡", "payment_id", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+	$objFormParam->addParam("¥Ý¥¤¥ó¥È", "use_point", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK", "ZERO_START"));
+	$objFormParam->addParam("ÇÛÃ£»þ´Ö", "deliv_time_id", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+	$objFormParam->addParam("¤´¼ÁÌä", "message", LTEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+	$objFormParam->addParam("¥Ý¥¤¥ó¥È¤ò»ÈÍÑ¤¹¤ë", "point_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), '2');
+	$objFormParam->addParam("ÇÛÃ£Æü", "deliv_date", STEXT_LEN, "KVa", array("MAX_LENGTH_CHECK"));
+}
+
+function lfGetPayment($total_pretax) {
+	$objQuery = new SC_Query();
+	$objQuery->setorder("rank DESC");
+	//ºï½ü¤µ¤ì¤Æ¤¤¤Ê¤¤»ÙÊ§ÊýË¡¤ò¼èÆÀ
+	$arrRet = $objQuery->select("payment_id, payment_method, rule, upper_rule, note, payment_image", "dtb_payment", "del_flg = 0 AND deliv_id IN (SELECT deliv_id FROM dtb_deliv WHERE del_flg = 0) ");
+	//ÍøÍÑ¾ò·ï¤«¤é»ÙÊ§²ÄÇ½ÊýË¡¤òÈ½Äê
+	foreach($arrRet as $data) {
+		//²¼¸Â¤È¾å¸Â¤¬ÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		if($data['rule'] > 0 && $data['upper_rule'] > 0) {
+			if($data['rule'] <= $total_pretax && $data['upper_rule'] >= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//²¼¸Â¤Î¤ßÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		} elseif($data['rule'] > 0) {	
+			if($data['rule'] <= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//¾å¸Â¤Î¤ßÀßÄê¤µ¤ì¤Æ¤¤¤ë
+		} elseif($data['upper_rule'] > 0) {
+			if($data['upper_rule'] >= $total_pretax) {
+				$arrPayment[] = $data;
+			}
+		//ÀßÄê¤Ê¤·
+		} else {
+			$arrPayment[] = $data;
+		}	
+	}
+	return $arrPayment;	
+}
+
+/* ÆþÎÏÆâÍÆ¤Î¥Á¥§¥Ã¥¯ */
+function lfCheckError($arrData) {
+	global $objFormParam;
+	global $objCustomer;
+	// ÆþÎÏ¥Ç¡¼¥¿¤òÅÏ¤¹¡£
+	$arrRet =  $objFormParam->getHashArray();
+	$objErr = new SC_CheckError($arrRet);
+	$objErr->arrErr = $objFormParam->checkError();
+	
+	if($_POST['point_check'] == '1') {
+		$objErr->doFunc(array("¥Ý¥¤¥ó¥È¤ò»ÈÍÑ¤¹¤ë", "point_check"), array("EXIST_CHECK"));
+		$objErr->doFunc(array("¥Ý¥¤¥ó¥È", "use_point"), array("EXIST_CHECK"));
+		$max_point = $objCustomer->getValue('point');
+		if($max_point == "") {
+			$max_point = 0;
+		}
+		if($arrRet['use_point'] > $max_point) {
+			$objErr->arrErr['use_point'] = "¢¨ ¤´ÍøÍÑ¥Ý¥¤¥ó¥È¤¬½ê»ý¥Ý¥¤¥ó¥È¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£<br>";
+		}
+		if(($arrRet['use_point'] * POINT_VALUE) > $arrData['subtotal']) {
+			$objErr->arrErr['use_point'] = "¢¨ ¤´ÍøÍÑ¥Ý¥¤¥ó¥È¤¬¤´¹ØÆþ¶â³Û¤òÄ¶¤¨¤Æ¤¤¤Þ¤¹¡£<br>";
+		}
+	}
+	return $objErr->arrErr;
+}
+
+/* »ÙÊ§¤¤ÊýË¡Ê¸»úÎó¤Î¼èÆÀ */
+function lfGetPaymentInfo($payment_id) {
+	$objQuery = new SC_Query();
+	$where = "payment_id = ?";
+	$arrRet = $objQuery->select("payment_method, charge", "dtb_payment", $where, array($payment_id));
+	return (array($arrRet[0]['payment_method'], $arrRet[0]['charge']));
+}
+
+/* ÇÛÁ÷»þ´ÖÊ¸»úÎó¤Î¼èÆÀ */
+function lfGetDelivTimeInfo($time_id) {
+	$objQuery = new SC_Query();
+	$where = "time_id = ?";
+	$arrRet = $objQuery->select("deliv_id, deliv_time", "dtb_delivtime", $where, array($time_id));
+	return (array($arrRet[0]['deliv_id'], $arrRet[0]['deliv_time']));
+}
+
+/* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
+function lfRegistData($uniqid) {
+    
+	global $objFormParam;
+	$arrRet = $objFormParam->getHashArray();
+	$sqlval = $objFormParam->getDbArray();
+	// ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+	$sqlval['order_temp_id'] = $uniqid;
+	$sqlval['update_date'] = 'Now()';
+	
+	if($sqlval['payment_id'] != "") {
+		list($sqlval['payment_method'], $sqlval['charge']) = lfGetPaymentInfo($sqlval['payment_id']);
+	} else {
+		$sqlval['payment_id'] = '0';
+		$sqlval['payment_method'] = "";
+	}
+	
+	if($sqlval['deliv_time_id'] != "") {
+		list($sqlval['deliv_id'], $sqlval['deliv_time']) = lfGetDelivTimeInfo($sqlval['deliv_time_id']);
+	} else {
+		$sqlval['deliv_time_id'] = '0';
+		$sqlval['deliv_id'] = '0';
+		$sqlval['deliv_time'] = "";
+	}
+	
+	// »ÈÍÑ¥Ý¥¤¥ó¥È¤ÎÀßÄê
+	if($sqlval['point_check'] != '1') {
+		$sqlval['use_point'] = 0;
+	}
+	print_r($_POST);
+	sfRegistTempOrder($uniqid, $sqlval);
+   
+}
+
+/* ÇÛÃ£Æü°ìÍ÷¤ò¼èÆÀ¤¹¤ë */
+function lfGetDelivDate() {
+	$objCartSess = new SC_CartSession();
+	$objQuery = new SC_Query();
+	// ¾¦ÉÊID¤Î¼èÆÀ
+	$max = $objCartSess->getMax();
+	for($i = 1; $i <= $max; $i++) {
+		if($_SESSION[$objCartSess->key][$i]['id'][0] != "") {
+			$arrID['product_id'][$i] = $_SESSION[$objCartSess->key][$i]['id'][0];
+		}
+	}
+	if(count($arrID['product_id']) > 0) {
+		$id = implode(",", $arrID['product_id']);
+		//¾¦ÉÊ¤«¤éÈ¯Á÷ÌÜ°Â¤Î¼èÆÀ
+		$deliv_date = $objQuery->get("dtb_products", "MAX(deliv_date_id)", "product_id IN (".$id.")");
+		//È¯Á÷ÌÜ°Â
+		switch($deliv_date) {
+		//Â¨ÆüÈ¯Á÷
+		case '1':
+			$start_day = 1;
+			break;
+		//1-2Æü¸å
+		case '2':
+			$start_day = 3;
+			break;
+		//3-4Æü¸å
+		case '3':
+			$start_day = 5;
+			break;
+		//1½µ´Ö°ÊÆâ
+		case '4':
+			$start_day = 8;
+			break;
+		//2½µ´Ö°ÊÆâ
+		case '5':
+			$start_day = 15;
+			break;
+		//3½µ´Ö°ÊÆâ
+		case '6':
+			$start_day = 22;
+			break;
+		//1¥ö·î°ÊÆâ
+		case '7':
+			$start_day = 32;
+			break;
+		//2¥ö·î°Ê¹ß
+		case '8':
+			$start_day = 62;			
+			break;
+		//¤ª¼è¤ê´ó¤»(¾¦ÉÊÆþ²Ù¸å)
+		case '9':
+			$start_day = "";
+			break;
+		default:
+			//¤ªÆÏ¤±Æü¤¬ÀßÄê¤µ¤ì¤Æ¤¤¤Ê¤¤¾ì¹ç
+			$start_day = "";
+			break;
+		}
+		//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤«¤é¡¢ÇÛÃ£Æü¤ÎÇÛÎó¤ò¼èÆÀ¤¹¤ë
+		$arrDelivDate = lfGetDateArray($start_day, DELIV_DATE_END_MAX);
+	}
+	return $arrDelivDate;
+}
+
+//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤«¤é¡¢ÇÛÃ£Æü¤ÎÇÛÎó¤ò¼èÆÀ¤¹¤ë
+function lfGetDateArray($start_day, $end_day) {
+	global $arrWDAY;
+	//ÇÛÃ£²ÄÇ½Æü¤Î¥¹¥¿¡¼¥ÈÃÍ¤¬¥»¥Ã¥È¤µ¤ì¤Æ¤¤¤ì¤Ð
+	if($start_day >= 1) {
+		$now_time = time();
+		$max_day = $start_day + $end_day;
+		// ½¸·×
+		for ($i = $start_day; $i < $max_day; $i++) {
+			// ´ðËÜ»þ´Ö¤«¤éÆü¿ô¤òÄÉ²Ã¤·¤Æ¤¤¤¯
+			$tmp_time = $now_time + ($i * 24 * 3600);
+			list($y, $m, $d, $w) = split(" ", date("y m d w", $tmp_time));	
+			$val = sprintf("%02d/%02d/%02d(%s)", $y, $m, $d, $arrWDAY[$w]);
+			$arrDate[$val] = $val;
+		}
+	} else {
+		$arrDate = false;
+	}
+	return $arrDate;
+}
+
+//°ì»þ¼õÃí¥Æ¡¼¥Ö¥ë¤«¤é¤Î¾ðÊó¤ò³ÊÇ¼¤¹¤ë
+function lfSetOrderTempData($uniqid) {
+	global $objQuery;
+	global $objFormParam;
+	
+	$objQuery = new SC_Query();
+	$col = "payment_id, use_point, deliv_time_id, message, point_check, deliv_date";
+	$from = "dtb_order_temp";
+	$where = "order_temp_id = ?";
+	$arrRet = $objQuery->select($col, $from, $where, array($uniqid));
+	// DBÃÍ¤Î¼èÆÀ
+	$objFormParam->setParam($arrRet[0]);
+	return $objFormParam;
+}
+
+
+?>
Index: /branches/beta/html/mobile/shopping/nonmember.php
===================================================================
--- /branches/beta/html/mobile/shopping/nonmember.php	(revision 14676)
+++ /branches/beta/html/mobile/shopping/nonmember.php	(revision 14676)
@@ -0,0 +1,400 @@
+<?php
+/*
+ * Copyright(c) 2000-2006 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+    function LC_Page() {
+        $this->tpl_mainpage = 'shopping/nonmember.tpl';        // ¥á¥¤¥ó¥Æ¥ó¥×¥ì¡¼¥È
+        $this->tpl_title .= '¤ªµÒÍÍ¾ðÊóÆþÎÏ(1/3)';            //¡¡¥Ú¡¼¥¸¥¿¥¤¥È¥ë
+    }
+}
+
+//---- ¥Ú¡¼¥¸½é´üÀßÄê
+$CONF = sf_getBasisData();                  // Å¹ÊÞ´ðËÜ¾ðÊó
+$objConn = new SC_DbConn();
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objDate = new SC_Date(START_BIRTH_YEAR, date("Y",strtotime("now")));
+$objPage->arrPref = $arrPref;
+$objPage->arrJob = $arrJob;
+$objPage->arrReminder = $arrReminder;
+$objPage->arrYear = $objDate->getYear('', 1950);    //¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
+$objPage->arrMonth = $objDate->getMonth();
+$objPage->arrDay = $objDate->getDay();
+
+//SSLURLÈ½Äê
+if (SSLURL_CHECK == 1){
+    $ssl_url= sfRmDupSlash(MOBILE_SSL_URL.$_SERVER['REQUEST_URI']);
+    if (!ereg("^https://", $non_ssl_url)){
+        sfDispSiteError(URL_ERROR, "", false, "", true);
+    }
+}
+
+// ¥ì¥¤¥¢¥¦¥È¥Ç¥¶¥¤¥ó¤ò¼èÆÀ
+$objPage = sfGetPageLayout($objPage, false, DEF_LAYOUT);
+
+//---- ÅÐÏ¿ÍÑ¥«¥é¥àÇÛÎó
+$arrRegistColumn = array(
+                             array(  "column" => "name01", "convert" => "aKV" ),
+                             array(  "column" => "name02", "convert" => "aKV" ),
+                             array(  "column" => "kana01", "convert" => "CKV" ),
+                             array(  "column" => "kana02", "convert" => "CKV" ),
+                             array(  "column" => "zip01", "convert" => "n" ),
+                             array(  "column" => "zip02", "convert" => "n" ),
+                             array(  "column" => "pref", "convert" => "n" ),
+                             array(  "column" => "addr01", "convert" => "aKV" ),
+                             array(  "column" => "addr02", "convert" => "aKV" ),
+                             array(  "column" => "email", "convert" => "a" ),
+                             array(  "column" => "email2", "convert" => "a" ),
+                             array(  "column" => "email_mobile", "convert" => "a" ),
+                             array(  "column" => "email_mobile2", "convert" => "a" ),
+                             array(  "column" => "tel01", "convert" => "n" ),
+                             array(  "column" => "tel02", "convert" => "n" ),
+                             array(  "column" => "tel03", "convert" => "n" ),
+                             array(  "column" => "fax01", "convert" => "n" ),
+                             array(  "column" => "fax02", "convert" => "n" ),
+                             array(  "column" => "fax03", "convert" => "n" ),
+                             array(  "column" => "sex", "convert" => "n" ),
+                             array(  "column" => "job", "convert" => "n" ),
+                             array(  "column" => "birth", "convert" => "n" ),
+                             array(  "column" => "reminder", "convert" => "n" ),
+                             array(  "column" => "reminder_answer", "convert" => "aKV"),
+                             array(  "column" => "password", "convert" => "a" ),
+                             array(  "column" => "password02", "convert" => "a" ),
+                             array(  "column" => "mailmaga_flg", "convert" => "n" ),
+                         );
+
+//---- ÅÐÏ¿½ü³°ÍÑ¥«¥é¥àÇÛÎó
+//$arrRejectRegistColumn = array("year", "month", "day", "email02", "email_mobile02","password","password02","reminder","reminder_answer");
+$arrRejectRegistColumn = array("year", "month", "day");
+
+if ($_SERVER["REQUEST_METHOD"] == "POST") {
+    //-- POST¥Ç¡¼¥¿¤Î°ú¤­·Ñ¤®
+    $objPage->arrForm = $_POST;
+    
+    if($objPage->arrForm['year'] == '----') {
+        $objPage->arrForm['year'] = '';
+    }
+    
+    //$objPage->arrForm['email'] = strtolower($objPage->arrForm['email']);        // email¤Ï¤¹¤Ù¤Æ¾®Ê¸»ú¤Ç½èÍý
+    
+    //-- ÆþÎÏ¥Ç¡¼¥¿¤ÎÊÑ´¹
+    $objPage->arrForm = lfConvertParam($objPage->arrForm, $arrRegistColumn);
+
+    // Ìá¤ë¥Ü¥¿¥óÍÑ½èÍý
+    if (!empty($_POST["return"])) {
+        switch ($_POST["mode"]) {
+        case "complete":
+            $_POST["mode"] = "set3";
+            break;
+        case "confirm":
+            $_POST["mode"] = "set2";
+            break;
+        default:
+            $_POST["mode"] = "set1";
+            break;
+        }
+    }
+
+    //--¡¡ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+    if (!empty($_POST["mode"])) {
+            if ($_POST["mode"] == "set1") {
+            $objPage->arrErr = lfErrorCheck1($objPage->arrForm);
+            $objPage->tpl_mainpage = 'shopping/nonmember.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(1/3)';
+        } elseif ($_POST["mode"] == "set2") {
+            $objPage->arrErr = lfErrorCheck2($objPage->arrForm);
+            $objPage->tpl_mainpage = 'shopping/nonmember_set1.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(2/3)';
+        } elseif ($_POST["mode"] == "deliv"){
+            $objPage->arrErr = lfErrorCheck3($objPage->arrForm);
+            $objPage->tpl_mainpage = 'shopping/nonmember_set2.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(3/3)';
+        }
+    
+   foreach($objPage->arrForm as $key => $val) {
+        $objPage->$key = $val;
+        }
+ 
+    }
+
+
+    if ($objPage->arrErr || !empty($_POST["return"])) {     // ÆþÎÏ¥¨¥é¡¼¤Î¥Á¥§¥Ã¥¯
+
+        //-- ¥Ç¡¼¥¿¤ÎÀßÄê
+        if ($_POST["mode"] == "set1") {
+            $checkVal = array("email", "name01", "name02", "kana01", "kana02");
+        } elseif ($_POST["mode"] == "set2") {
+            $checkVal = array("sex", "year", "month", "day", "zip01", "zip02");
+        } else {
+            $checkVal = array("pref", "addr01", "addr02", "tel01", "tel02", "tel03", "mail_flag");
+        }
+
+        foreach($objPage->arrForm as $key => $val) {
+            if ($key != "mode" && $key != "submit" && $key != "return" && $key != session_name() && !in_array($key, $checkVal))
+                $objPage->list_data[ $key ] = $val;
+        }
+
+
+
+    } else {
+
+        //--¡¡¥Æ¥ó¥×¥ì¡¼¥ÈÀßÄê
+        if ($_POST["mode"] == "set1") {
+            $objPage->tpl_mainpage = 'shopping/nonmember_set1.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(2/3)';
+        } elseif ($_POST["mode"] == "set2") {
+            $objPage->tpl_mainpage = 'shopping/nonmember_set2.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(3/3)';
+
+            if (@$objPage->arrForm['pref'] == "" && @$objPage->arrForm['addr01'] == "" && @$objPage->arrForm['addr02'] == "") {
+                $address = lfGetAddress($_REQUEST['zip01'].$_REQUEST['zip02']);
+                $objPage->pref = @$address[0]['state'];
+                $objPage->addr01 = @$address[0]['city'] . @$address[0]['town'];
+            }
+        } /*elseif ($_POST["mode"] == "deliv") {
+            //¥Ñ¥¹¥ï¡¼¥ÉÉ½¼¨
+            
+            //¥á¡¼¥ë¼õ¤±¼è¤ê
+            if (strtolower($objPage->arrForm['mail_flag']) == "on") {
+                $objPage->arrForm['mail_flag']  = "2";
+            } else {
+                $objPage->arrForm['mail_flag']  = "3";
+            }
+
+            $objPage->tpl_mainpage = 'shopping/deliv.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊó(³ÎÇ§¥Ú¡¼¥¸)';
+
+        }*/
+
+        //-- ¥Ç¡¼¥¿ÀßÄê
+        unset($objPage->list_data);
+        if ($_POST["mode"] == "set1") {
+            $checkVal = array("sex", "year", "month", "day", "zip01", "zip02");
+        } elseif ($_POST["mode"] == "set2") {
+            $checkVal = array("pref", "addr01", "addr02", "tel01", "tel02", "tel03", "mail_flag");
+        } else {
+            $checkVal = array();
+        }
+
+        foreach($objPage->arrForm as $key => $val) {
+            if ($key != "mode" && $key != "submit" && $key != "confirm" && $key != "return" && $key != session_name() && !in_array($key, $checkVal)) {
+                $objPage->list_data[ $key ] = $val;
+            }
+        }
+
+//        if ($_POST["mode"] == "deliv") {
+//            
+//            $objFormParam = new SC_FormParam();
+//            // ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+//           
+//            // POSTÃÍ¤Î¼èÆÀ
+//            $objFormParam->setParam($_POST);
+//            
+//            // ÆþÎÏÃÍ¤Î¼èÆÀ
+//            $objPage->arrForm = $objFormParam->getFormParamList();
+//            $objPage->arrErr = $arrErr;
+//            
+////            $cnt = 1;
+////            foreach($objOtherAddr as $val) {
+////                $objPage->arrAddr[$cnt] = $val;
+////                $cnt++;
+////            }
+//            
+//           $objPage->arrAddr[0]['zip01'] = $objPage->zip01;
+//           $objPage->arrAddr[0]['zip02'] = $objPage->zip02;
+//           $objPage->arrAddr[0]['pref'] = $objPage->pref;
+//           $objPage->arrAddr[0]['addr01'] = $objPage->addr01;
+//           $objPage->arrAddr[0]['addr02'] = $objPage->addr02;
+//           
+//            $objPage->tpl_mainpage = 'shopping/deliv.tpl';
+//            $objPage->tpl_title = '¤ªÆÏ¤±Àè¾ðÊó';
+//        }
+        
+         if ($_POST["mode"] == "customer_addr") {
+           lfRegistData ($uniqid); 
+           header("Location:" . gfAddSessionId("./payment.php"));
+        print($_POST);
+        }
+        
+        //--¡¡²¾ÅÐÏ¿¤È´°Î»²èÌÌ
+        if ($_POST["mode"] == "complete") {
+            $objPage->uniqid = lfRegistData ($objPage->arrForm, $arrRegistColumn, $arrRejectRegistColumn);
+
+            // ¶õ¥á¡¼¥ë¤ò¼õ¿®ºÑ¤ß¤Î¾ì¹ç¤Ï¤¹¤°¤ËËÜÅÐÏ¿´°Î»¤Ë¤¹¤ë¡£
+//            if (isset($_SESSION['mobile']['kara_mail_from'])) {
+//                header("Location:" . gfAddSessionId(MOBILE_URL_DIR . "regist/index.php?mode=regist&id=" . $objPage->uniqid));
+//                exit;
+//            }
+
+            $objPage->tpl_mainpage = 'shopping/complete.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(´°Î»¥Ú¡¼¥¸)';
+
+            /*sfMobileSetExtSessionId('id', $objPage->uniqid, 'regist/index.php');
+
+            //¡¡²¾ÅÐÏ¿´°Î»¥á¡¼¥ëÁ÷¿®
+            $objPage->CONF = $CONF;
+            $objPage->to_name01 = $_POST['name01'];
+            $objPage->to_name02 = $_POST['name02'];
+            $objMailText = new SC_MobileView();
+            $objMailText->assignobj($objPage);
+            $subject = sfMakesubject('¤ªµÒÍÍ¾ðÊó¤Î¤´³ÎÇ§');
+            $toCustomerMail = $objMailText->fetch("mail_templates/customer_mail.tpl");
+            $objMail = new GC_SendMail();
+            $objMail->setItem(
+                                ''                                  //¡¡°¸Àè
+                                , $subject                          //¡¡¥µ¥Ö¥¸¥§¥¯¥È
+                                , $toCustomerMail                   //¡¡ËÜÊ¸
+                                , $CONF["email03"]                  //¡¡ÇÛÁ÷¸µ¥¢¥É¥ì¥¹
+                                , $CONF["shop_name"]                //¡¡ÇÛÁ÷¸µ¡¡Ì¾Á°
+                                , $CONF["email03"]                  //¡¡reply_to
+                                , $CONF["email04"]                  //¡¡return_path
+                                , $CONF["email04"]                  //  Errors_to
+                                , $CONF["email01"]                  //  Bcc
+                                                                );
+            // °¸Àè¤ÎÀßÄê
+            $name = $_POST["name01"] . $_POST["name02"] ." ÍÍ";
+            $objMail->setTo($_POST["email"], $name);
+            $objMail->sendMail();
+*/
+            // ´°Î»¥Ú¡¼¥¸¤Ë°ÜÆ°¤µ¤»¤ë¡£
+            header("Location:" . gfAddSessionId("./complete.php"));
+            exit;
+        }
+    }
+}
+
+//----¡¡¥Ú¡¼¥¸É½¼¨
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+
+//----------------------------------------------------------------------------------------------------------------------
+
+//---- function·²
+function lfRegistData($uniqid) {
+    global $objFormParam;
+    $arrRet = $objFormParam->getHashArray();
+    $sqlval = $objFormParam->getDbArray();
+    // ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+    $sqlval['order_temp_id'] = $uniqid;
+    $sqlval['order_birth'] = sfGetTimestamp($arrRet['year'], $arrRet['month'], $arrRet['day']);
+    $sqlval['update_date'] = 'Now()';
+    $sqlval['customer_id'] = '0';
+    
+    // ´ûÂ¸¥Ç¡¼¥¿¤Î¥Á¥§¥Ã¥¯
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $cnt = $objQuery->count("dtb_order_temp", $where, array($uniqid));
+    // ´ûÂ¸¥Ç¡¼¥¿¤¬¤Ê¤¤¾ì¹ç
+    if ($cnt == 0) {
+        $sqlval['create_date'] = 'Now()';
+        $objQuery->insert("dtb_order_temp", $sqlval);
+    } else {
+        $objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+    }
+}
+
+//----¡¡¼èÆÀÊ¸»úÎó¤ÎÊÑ´¹
+function lfConvertParam($array, $arrRegistColumn) {
+    /*
+     *  Ê¸»úÎó¤ÎÊÑ´¹
+     *  K :  ¡ÖÈ¾³Ñ(ÊÝ¶¸)ÊÒ²¾Ì¾¡×¤ò¡ÖÁ´³ÑÊÒ²¾Ì¾¡×¤ËÊÑ´¹
+     *  C :  ¡ÖÁ´³Ñ¤Ò¤é²¾Ì¾¡×¤ò¡ÖÁ´³Ñ¤«¤¿²¾Ì¾¡×¤ËÊÑ´¹
+     *  V :  ÂùÅÀÉÕ¤­¤ÎÊ¸»ú¤ò°ìÊ¸»ú¤ËÊÑ´¹¡£"K","H"¤È¶¦¤Ë»ÈÍÑ¤·¤Þ¤¹ 
+     *  n :  ¡ÖÁ´³Ñ¡×¿ô»ú¤ò¡ÖÈ¾³Ñ(ÊÝ¶¸)¡×¤ËÊÑ´¹
+     *  a :  Á´³Ñ±Ñ¿ô»ú¤òÈ¾³Ñ±Ñ¿ô»ú¤ËÊÑ´¹¤¹¤ë
+     */
+    // ¥«¥é¥àÌ¾¤È¥³¥ó¥Ð¡¼¥È¾ðÊó
+    foreach ($arrRegistColumn as $data) {
+        $arrConvList[ $data["column"] ] = $data["convert"];
+    }
+    // Ê¸»úÊÑ´¹
+    foreach ($arrConvList as $key => $val) {
+        // POST¤µ¤ì¤Æ¤­¤¿ÃÍ¤Î¤ßÊÑ´¹¤¹¤ë¡£
+        if(strlen(($array[$key])) > 0) {
+            $array[$key] = mb_convert_kana($array[$key] ,$val);
+        }
+    }
+    return $array;
+}
+
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck2($array) {
+
+    global $objConn, $objDate;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "zip01", ZIP01_LEN ) ,array("EXIST_CHECK", "SPTAB_CHECK" ,"NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "zip02", ZIP02_LEN ) ,array("EXIST_CHECK", "SPTAB_CHECK" ,"NUM_CHECK", "NUM_COUNT_CHECK")); 
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "zip01", "zip02"), array("ALL_EXIST_CHECK"));
+
+    $objErr->doFunc(array("À­ÊÌ", "sex") ,array("SELECT_CHECK", "NUM_CHECK")); 
+    $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", 4), array("EXIST_CHECK", "SPTAB_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    if (!isset($objErr->arrErr['year'])) {
+        $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", $objDate->getStartYear()), array("MIN_CHECK"));
+        $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", $objDate->getEndYear()), array("MAX_CHECK"));
+    }
+    $objErr->doFunc(array("À¸Ç¯·îÆü (·îÆü)", "month", "day"), array("SELECT_CHECK"));
+    if (!isset($objErr->arrErr['year']) && !isset($objErr->arrErr['month']) && !isset($objErr->arrErr['day'])) {
+        $objErr->doFunc(array("À¸Ç¯·îÆü", "year", "month", "day"), array("CHECK_DATE"));
+    }
+    
+    return $objErr->arrErr;
+}
+
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck3($array) {
+
+    global $objConn;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", 'pref'), array("SELECT_CHECK","NUM_CHECK"));
+    $objErr->doFunc(array("»Ô¶èÄ®Â¼", "addr01", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("ÈÖÃÏ", "addr02", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", 'tel01'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", 'tel02'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", 'tel03'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ", "tel01", "tel02", "tel03",TEL_ITEM_LEN) ,array("TEL_CHECK"));
+    
+    return $objErr->arrErr;
+}
+
+// Í¹ÊØÈÖ¹æ¤«¤é½»½ê¤Î¼èÆÀ
+function lfGetAddress($zipcode) {
+    global $arrPref;
+
+    $conn = new SC_DBconn(ZIP_DSN);
+
+    // Í¹ÊØÈÖ¹æ¸¡º÷Ê¸ºîÀ®
+    $zipcode = mb_convert_kana($zipcode ,"n");
+    $sqlse = "SELECT state, city, town FROM mtb_zip WHERE zipcode = ?";
+
+    $data_list = $conn->getAll($sqlse, array($zipcode));
+
+    // ¥¤¥ó¥Ç¥Ã¥¯¥¹¤ÈÃÍ¤òÈ¿Å¾¤µ¤»¤ë¡£
+    $arrREV_PREF = array_flip($arrPref);
+
+    /*
+        ÁíÌ³¾Ê¤«¤é¥À¥¦¥ó¥í¡¼¥É¤·¤¿¥Ç¡¼¥¿¤ò¤½¤Î¤Þ¤Þ¥¤¥ó¥Ý¡¼¥È¤¹¤ë¤È
+        °Ê²¼¤Î¤è¤¦¤ÊÊ¸»úÎó¤¬Æþ¤Ã¤Æ¤¤¤ë¤Î¤Ç   ÂÐºö¤¹¤ë¡£
+        ¡¦¡Ê£±¡¦£±£¹ÃúÌÜ¡Ë
+        ¡¦°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç
+    */
+    $town =  $data_list[0]['town'];
+    $town = ereg_replace("¡Ê.*¡Ë$","",$town);
+    $town = ereg_replace("°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç","",$town);
+    $data_list[0]['town'] = $town;
+    $data_list[0]['state'] = $arrREV_PREF[$data_list[0]['state']];
+
+    return $data_list;
+}
+
+//-----------------------------------------------------------------------------------------------------------------------------------
+?>
Index: /branches/beta/html/mobile/shopping/deliv.php
===================================================================
--- /branches/beta/html/mobile/shopping/deliv.php	(revision 11894)
+++ /branches/beta/html/mobile/shopping/deliv.php	(revision 14676)
@@ -96,5 +96,5 @@
 
 	// ·ÈÂÓ¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤ò¥³¥Ô¡¼¤¹¤ë¡£
-	$objCustomer->updateEmailMobile();
+	// $objCustomer->updateEmailMobile();
 
 	// ·ÈÂÓ¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤Ê¤¤¾ì¹ç
@@ -189,4 +189,5 @@
 $objQuery = new SC_Query();
 $arrCustomerAddr = $objQuery->select($col, "dtb_customer", $where, array($_SESSION['customer']['customer_id']));
+
 // ÊÌ¤Î¤ªÆÏ¤±Àè½»½ê¤Î¼èÆÀ
 $col = "other_deliv_id, name01, name02, pref, addr01, addr02, zip01, zip02";
Index: /branches/beta/html/mobile/shopping/index.php
===================================================================
--- /branches/beta/html/mobile/shopping/index.php	(revision 11851)
+++ /branches/beta/html/mobile/shopping/index.php	(revision 14676)
@@ -11,24 +11,24 @@
 
 class LC_Page {
-	var $arrSession;
-	var $tpl_mode;
-	var $tpl_login_email;
-	function LC_Page() {
-		$this->tpl_mainpage = 'shopping/index.tpl';
-		global $arrPref;
-		$this->arrPref = $arrPref;
-		global $arrSex;
-		$this->arrSex = $arrSex;
-		global $arrJob;
-		$this->arrJob = $arrJob;
-		$this->tpl_onload = 'fnCheckInputDeliv();';
-		
-		/*
-		 session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
-		 ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
-		 private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
-		*/
-		session_cache_limiter('private-no-expire');				
-	}
+    var $arrSession;
+    var $tpl_mode;
+    var $tpl_login_email;
+    function LC_Page() {
+        $this->tpl_mainpage = 'shopping/index.tpl';
+        global $arrPref;
+        $this->arrPref = $arrPref;
+        global $arrSex;
+        $this->arrSex = $arrSex;
+        global $arrJob;
+        $this->arrJob = $arrJob;
+        $this->tpl_onload = 'fnCheckInputDeliv();';
+        
+        /*
+         session_start»þ¤Îno-cache¥Ø¥Ã¥À¡¼¤òÍÞÀ©¤¹¤ë¤³¤È¤Ç
+         ¡ÖÌá¤ë¡×¥Ü¥¿¥ó»ÈÍÑ»þ¤ÎÍ­¸ú´ü¸ÂÀÚ¤ìÉ½¼¨¤òÍÞÀ©¤¹¤ë¡£
+         private-no-expire:¥¯¥é¥¤¥¢¥ó¥È¤Î¥­¥ã¥Ã¥·¥å¤òµö²Ä¤¹¤ë¡£
+        */
+        session_cache_limiter('private-no-expire');             
+    }
 }
 
@@ -40,7 +40,32 @@
 $objCustomer = new SC_Customer();
 $objCookie = new SC_Cookie();
-$objFormParam = new SC_FormParam();			// ¥Õ¥©¡¼¥àÍÑ
-lfInitParam();								// ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
-$objFormParam->setParam($_POST);			// POSTÃÍ¤Î¼èÆÀ
+$objFormParam = new SC_FormParam();         // ¥Õ¥©¡¼¥àÍÑ
+lfInitParam();                              // ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+$objFormParam->setParam($_POST);            // POSTÃÍ¤Î¼èÆÀ
+
+
+//-------------------------------------¢§NONMEMBER----------------------------------------------
+//---- ¥Ú¡¼¥¸½é´üÀßÄê
+
+$CONF = sf_getBasisData();                  // Å¹ÊÞ´ðËÜ¾ðÊó
+$objView = new SC_MobileView();
+$objDate = new SC_Date(START_BIRTH_YEAR, date("Y",strtotime("now")));
+$objPage->arrPref = $arrPref;
+$objPage->arrJob = $arrJob;
+$objPage->arrReminder = $arrReminder;
+$objPage->arrYear = $objDate->getYear('', 1950);    //¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
+$objPage->arrMonth = $objDate->getMonth();
+$objPage->arrDay = $objDate->getDay();
+
+//SSLURLÈ½Äê
+if (SSLURL_CHECK == 1){
+    $ssl_url= sfRmDupSlash(MOBILE_SSL_URL.$_SERVER['REQUEST_URI']);
+    if (!ereg("^https://", $non_ssl_url)){
+        sfDispSiteError(URL_ERROR, "", false, "", true);
+    }
+}
+
+// ¥ì¥¤¥¢¥¦¥È¥Ç¥¶¥¤¥ó¤ò¼èÆÀ
+$objPage = sfGetPageLayout($objPage, false, DEF_LAYOUT);
 
 // ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ¤È¹ØÆþ¾õÂÖ¤ÎÀµÅöÀ­¤ò¥Á¥§¥Ã¥¯
@@ -51,8 +76,9 @@
 // ¥í¥°¥¤¥ó¥Á¥§¥Ã¥¯
 if($objCustomer->isLoginSuccess()) {
-	// ¤¹¤Ç¤Ë¥í¥°¥¤¥ó¤µ¤ì¤Æ¤¤¤ë¾ì¹ç¤Ï¡¢¤ªÆÏ¤±ÀèÀßÄê²èÌÌ¤ËÅ¾Á÷
-	header("Location: " . gfAddSessionId('deliv.php'));
-	exit;
-}
+    // ¤¹¤Ç¤Ë¥í¥°¥¤¥ó¤µ¤ì¤Æ¤¤¤ë¾ì¹ç¤Ï¡¢¤ªÆÏ¤±ÀèÀßÄê²èÌÌ¤ËÅ¾Á÷
+    header("Location: " . gfAddSessionId('deliv.php'));
+    exit;
+}
+
 
 // ·ÈÂÓÃ¼ËöID¤¬°ìÃ×¤¹¤ë²ñ°÷¤¬Â¸ºß¤¹¤ë¤«¤É¤¦¤«¤ò¥Á¥§¥Ã¥¯¤¹¤ë¡£
@@ -61,49 +87,49 @@
 switch($_POST['mode']) {
 case 'nonmember_confirm':
-	$objPage = lfSetNonMember($objPage);
-	// ¢¨break¤Ê¤·
+    $objPage = lfSetNonMember($objPage);
+    // ¢¨break¤Ê¤·
 case 'confirm':
-	// ÆþÎÏÃÍ¤ÎÊÑ´¹
-	$objFormParam->convParam();
-	$objFormParam->toLower('order_mail');
-	$objFormParam->toLower('order_mail_check');
-	
-	$objPage->arrErr = lfCheckError();
-
-	// ÆþÎÏ¥¨¥é¡¼¤Ê¤·
-	if(count($objPage->arrErr) == 0) {
-		// DB¤Ø¤Î¥Ç¡¼¥¿ÅÐÏ¿
-		lfRegistData($uniqid);
-		// Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
-		$objSiteSess->setRegistFlag();
-		// ¤ª»ÙÊ§¤¤ÊýË¡ÁªÂò¥Ú¡¼¥¸¤Ø°ÜÆ°
-		header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_PAYMENT));
-		exit;		
-	}
-	
-	break;
+    // ÆþÎÏÃÍ¤ÎÊÑ´¹
+    $objFormParam->convParam();
+    $objFormParam->toLower('order_mail');
+    $objFormParam->toLower('order_mail_check');
+    
+    $objPage->arrErr = lfCheckError();
+
+    // ÆþÎÏ¥¨¥é¡¼¤Ê¤·
+    if(count($objPage->arrErr) == 0) {
+        // DB¤Ø¤Î¥Ç¡¼¥¿ÅÐÏ¿
+        lfRegistData($uniqid);
+        // Àµ¾ï¤ËÅÐÏ¿¤µ¤ì¤¿¤³¤È¤òµ­Ï¿¤·¤Æ¤ª¤¯
+        $objSiteSess->setRegistFlag();
+        // ¤ª»ÙÊ§¤¤ÊýË¡ÁªÂò¥Ú¡¼¥¸¤Ø°ÜÆ°
+        header("Location: " . gfAddSessionId(MOBILE_URL_SHOP_PAYMENT));
+        exit;       
+    }
+    
+    break;
 // Á°¤Î¥Ú¡¼¥¸¤ËÌá¤ë
 case 'return':
-	// ³ÎÇ§¥Ú¡¼¥¸¤Ø°ÜÆ°
-	header("Location: " . gfAddSessionId(MOBILE_URL_CART_TOP));
-	exit;
-	break;
+    // ³ÎÇ§¥Ú¡¼¥¸¤Ø°ÜÆ°
+    header("Location: " . gfAddSessionId(MOBILE_URL_CART_TOP));
+    exit;
+    break;
 case 'nonmember':
-	$objPage = lfSetNonMember($objPage);
-	// ¢¨break¤Ê¤·
+    $objPage = lfSetNonMember($objPage);
+    // ¢¨break¤Ê¤·
 default:
-	if($_GET['from'] == 'nonmember') {
-		$objPage = lfSetNonMember($objPage);
-	}
-	// ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
-	$uniqid = $objSiteSess->getUniqId();
-	$objQuery = new SC_Query();
-	$where = "order_temp_id = ?";
-	$arrRet = $objQuery->select("*", "dtb_order_temp", $where, array($uniqid));
-	// DBÃÍ¤Î¼èÆÀ
-	$objFormParam->setParam($arrRet[0]);
-	$objFormParam->setValue('order_email_check', $arrRet[0]['order_email']);
-	$objFormParam->setDBDate($arrRet[0]['order_birth']);
-	break;
+    if($_GET['from'] == 'nonmember') {
+        $objPage = lfSetNonMember($objPage);
+    }
+    // ¥æ¡¼¥¶¥æ¥Ë¡¼¥¯ID¤Î¼èÆÀ
+    $uniqid = $objSiteSess->getUniqId();
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $arrRet = $objQuery->select("*", "dtb_order_temp", $where, array($uniqid));
+    // DBÃÍ¤Î¼èÆÀ
+    $objFormParam->setParam($arrRet[0]);
+    $objFormParam->setValue('order_email_check', $arrRet[0]['order_email']);
+    $objFormParam->setDBDate($arrRet[0]['order_birth']);
+    break;
 }
 
@@ -111,15 +137,15 @@
 $objPage->tpl_login_email = $objCookie->getCookie('login_email');
 if($objPage->tpl_login_email != "") {
-	$objPage->tpl_login_memory = "1";
+    $objPage->tpl_login_memory = "1";
 }
 
 // ÁªÂòÍÑÆüÉÕ¤Î¼èÆÀ
 $objDate = new SC_Date(START_BIRTH_YEAR);
-$objPage->arrYear = $objDate->getYear('', 1950);	//¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
+$objPage->arrYear = $objDate->getYear('', 1950);    //¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
 $objPage->arrMonth = $objDate->getMonth();
 $objPage->arrDay = $objDate->getDay();
 
 if($objPage->year == '') {
-	$objPage->year = '----';
+    $objPage->year = '----';
 }
 
@@ -128,123 +154,151 @@
 
 if($objPage->arrForm['year']['value'] == ""){
-	$objPage->arrForm['year']['value'] = '----';	
+    $objPage->arrForm['year']['value'] = '----';    
 }
 
 $objView->assignobj($objPage);
 $objView->display(SITE_FRAME);
+
 //--------------------------------------------------------------------------------------------------------------------------
 /* Èó²ñ°÷ÆþÎÏ¥Ú¡¼¥¸¤Î¥»¥Ã¥È */
 function lfSetNonMember($objPage) {
-	$objPage->tpl_mainpage = 'shopping/nonmember_input.tpl';
-	$objPage->tpl_css = array();
-	$objPage->tpl_css[] = '/css/layout/login/nonmember.css';
-	return $objPage;
+        
+    $objPage->tpl_mainpage = 'nonmember/nonmember_set1.tpl';
+    $objPage->tpl_css = array();
+    $objPage->tpl_css[] = '/css/layout/login/nonmember.css';
+    return $objPage;
+}
+
+
+function lfRegistData($uniqid) {
+    global $objFormParam;
+    $arrRet = $objFormParam->getHashArray();
+    $sqlval = $objFormParam->getDbArray();
+    // ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
+    $sqlval['order_temp_id'] = $uniqid;
+    $sqlval['order_birth'] = sfGetTimestamp($arrRet['year'], $arrRet['month'], $arrRet['day']);
+    $sqlval['update_date'] = 'Now()';
+    $sqlval['customer_id'] = '0';
+    
+    // ´ûÂ¸¥Ç¡¼¥¿¤Î¥Á¥§¥Ã¥¯
+    $objQuery = new SC_Query();
+    $where = "order_temp_id = ?";
+    $cnt = $objQuery->count("dtb_order_temp", $where, array($uniqid));
+    // ´ûÂ¸¥Ç¡¼¥¿¤¬¤Ê¤¤¾ì¹ç
+    if ($cnt == 0) {
+        $sqlval['create_date'] = 'Now()';
+        $objQuery->insert("dtb_order_temp", $sqlval);
+    } else {
+        $objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+    }
 }
 
 /* ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½ */
 function lfInitParam() {
-	global $objFormParam;
-	$objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "order_name01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "order_name02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "order_kana01", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "order_kana02", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "order_zip01", ZIP01_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
-	$objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "order_zip02", ZIP02_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
-	$objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "order_pref", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
-	$objFormParam->addParam("½»½ê1", "order_addr01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("½»½ê2", "order_addr02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "order_tel01", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "order_tel02", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "order_tel03", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("FAXÈÖ¹æ1", "order_fax01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("FAXÈÖ¹æ2", "order_fax02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("FAXÈÖ¹æ3", "order_fax03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹", "order_email", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"));
-	$objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email_check", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"), "", false);
-	$objFormParam->addParam("Ç¯", "year", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
-	$objFormParam->addParam("·î", "month", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
-	$objFormParam->addParam("Æü", "day", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
-	$objFormParam->addParam("À­ÊÌ", "order_sex", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
-	$objFormParam->addParam("¿¦¶È", "order_job", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
-	$objFormParam->addParam("ÊÌ¤Î¤ªÆÏ¤±Àè", "deliv_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
-	$objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "deliv_zip01", ZIP01_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
-	$objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "deliv_zip02", ZIP02_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
-	$objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "deliv_pref", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
-	$objFormParam->addParam("½»½ê1", "deliv_addr01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("½»½ê2", "deliv_addr02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "deliv_tel01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "deliv_tel02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "deliv_tel03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
-	$objFormParam->addParam("¥á¡¼¥ë¥Þ¥¬¥¸¥ó", "mail_flag", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), 1);
+    global $objFormParam;
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "order_name01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "order_name02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "order_kana01", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "order_kana02", STEXT_LEN, "KVCa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "order_zip01", ZIP01_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "order_zip02", ZIP02_LEN, "n", array("EXIST_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "order_pref", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("½»½ê1", "order_addr01", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("½»½ê2", "order_addr02", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "order_tel01", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "order_tel02", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "order_tel03", TEL_ITEM_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ1", "order_fax01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ2", "order_fax02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("FAXÈÖ¹æ3", "order_fax03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹", "order_email", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email_check", STEXT_LEN, "KVa", array("EXIST_CHECK", "SPTAB_CHECK", "NO_SPTAB", "MAX_LENGTH_CHECK", "EMAIL_CHECK", "EMAIL_CHAR_CHECK"), "", false);
+    $objFormParam->addParam("Ç¯", "year", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("·î", "month", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("Æü", "day", INT_LEN, "n", array("MAX_LENGTH_CHECK"), "", false);
+    $objFormParam->addParam("À­ÊÌ", "order_sex", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("¿¦¶È", "order_job", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("ÊÌ¤Î¤ªÆÏ¤±Àè", "deliv_check", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02", STEXT_LEN, "KVCa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ1", "deliv_zip01", ZIP01_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("Í¹ÊØÈÖ¹æ2", "deliv_zip02", ZIP02_LEN, "n", array("NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objFormParam->addParam("ÅÔÆ»ÉÜ¸©", "deliv_pref", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"));
+    $objFormParam->addParam("½»½ê1", "deliv_addr01", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("½»½ê2", "deliv_addr02", STEXT_LEN, "KVa", array("SPTAB_CHECK", "MAX_LENGTH_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ1", "deliv_tel01", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ2", "deliv_tel02", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("ÅÅÏÃÈÖ¹æ3", "deliv_tel03", TEL_ITEM_LEN, "n", array("MAX_LENGTH_CHECK" ,"NUM_CHECK"));
+    $objFormParam->addParam("¥á¡¼¥ë¥Þ¥¬¥¸¥ó", "mail_flag", INT_LEN, "n", array("MAX_LENGTH_CHECK", "NUM_CHECK"), 1);
 }
 
 /* DB¤Ø¥Ç¡¼¥¿¤ÎÅÐÏ¿ */
-function lfRegistData($uniqid) {
-	global $objFormParam;
-	$arrRet = $objFormParam->getHashArray();
-	$sqlval = $objFormParam->getDbArray();
-	// ÅÐÏ¿¥Ç¡¼¥¿¤ÎºîÀ®
-	$sqlval['order_temp_id'] = $uniqid;
-	$sqlval['order_birth'] = sfGetTimestamp($arrRet['year'], $arrRet['month'], $arrRet['day']);
-	$sqlval['update_date'] = 'Now()';
-	$sqlval['customer_id'] = '0';
-	
-	// ´ûÂ¸¥Ç¡¼¥¿¤Î¥Á¥§¥Ã¥¯
-	$objQuery = new SC_Query();
-	$where = "order_temp_id = ?";
-	$cnt = $objQuery->count("dtb_order_temp", $where, array($uniqid));
-	// ´ûÂ¸¥Ç¡¼¥¿¤¬¤Ê¤¤¾ì¹ç
-	if ($cnt == 0) {
-		$sqlval['create_date'] = 'Now()';
-		$objQuery->insert("dtb_order_temp", $sqlval);
-	} else {
-		$objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
-	}
-}
+
 
 /* ÆþÎÏÆâÍÆ¤Î¥Á¥§¥Ã¥¯ */
 function lfCheckError() {
-	global $objFormParam;
-	// ÆþÎÏ¥Ç¡¼¥¿¤òÅÏ¤¹¡£
-	$arrRet =  $objFormParam->getHashArray();
-	$objErr = new SC_CheckError($arrRet);
-	$objErr->arrErr = $objFormParam->checkError();
-		
-	// ÊÌ¤Î¤ªÆÏ¤±Àè¥Á¥§¥Ã¥¯
-	if($_POST['deliv_check'] == "1") { 
-		$objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "deliv_zip01"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "deliv_zip02"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", "deliv_pref"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("½»½ê1", "deliv_addr01"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("½»½ê2", "deliv_addr02"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", "deliv_tel01"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", "deliv_tel02"), array("EXIST_CHECK"));
-		$objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", "deliv_tel03"), array("EXIST_CHECK"));
-	}
-	
-	// Ê£¿ô¹àÌÜ¥Á¥§¥Ã¥¯
-	$objErr->doFunc(array("TEL", "order_tel01", "order_tel02", "order_tel03", TEL_ITEM_LEN), array("TEL_CHECK"));
-	$objErr->doFunc(array("FAX", "order_fax01", "order_fax02", "order_fax03", TEL_ITEM_LEN), array("TEL_CHECK"));
-	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "order_zip01", "order_zip02"), array("ALL_EXIST_CHECK"));
-	$objErr->doFunc(array("TEL", "deliv_tel01", "deliv_tel02", "deliv_tel03", TEL_ITEM_LEN), array("TEL_CHECK"));
-	$objErr->doFunc(array("FAX", "deliv_fax01", "deliv_fax02", "deliv_fax03", TEL_ITEM_LEN), array("TEL_CHECK"));
-	$objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "deliv_zip01", "deliv_zip02"), array("ALL_EXIST_CHECK"));
-	$objErr->doFunc(array("À¸Ç¯·îÆü", "year", "month", "day"), array("CHECK_DATE"));
-	$objErr->doFunc(array("¥á¡¼¥ë¥¢¥É¥ì¥¹", "¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email", "order_email_check"), array("EQUAL_CHECK"));
-	
-	// ¤¹¤Ç¤Ë¥á¥ë¥Þ¥¬¥Æ¡¼¥Ö¥ë¤Ë²ñ°÷¤È¤·¤Æ¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¾ì¹ç
-	if(sfCheckCustomerMailMaga($arrRet['order_email'])) {
-		$objErr->arrErr['order_email'] = "¤³¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤Ï¤¹¤Ç¤ËÅÐÏ¿¤µ¤ì¤Æ¤¤¤Þ¤¹¡£<br>";
-	}
-		
-	return $objErr->arrErr;
+    global $objFormParam;
+    // ÆþÎÏ¥Ç¡¼¥¿¤òÅÏ¤¹¡£
+    $arrRet =  $objFormParam->getHashArray();
+    $objErr = new SC_CheckError($arrRet);
+    $objErr->arrErr = $objFormParam->checkError();
+        
+    // ÊÌ¤Î¤ªÆÏ¤±Àè¥Á¥§¥Ã¥¯
+    if($_POST['deliv_check'] == "1") { 
+        $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", "deliv_name01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", "deliv_name02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("¥Õ¥ê¥¬¥Ê¡Ê¥»¥¤¡Ë", "deliv_kana01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("¥Õ¥ê¥¬¥Ê¡Ê¥á¥¤¡Ë", "deliv_kana02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "deliv_zip01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "deliv_zip02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", "deliv_pref"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("½»½ê1", "deliv_addr01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("½»½ê2", "deliv_addr02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", "deliv_tel01"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", "deliv_tel02"), array("EXIST_CHECK"));
+        $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", "deliv_tel03"), array("EXIST_CHECK"));
+    }
+    
+    // Ê£¿ô¹àÌÜ¥Á¥§¥Ã¥¯
+    $objErr->doFunc(array("TEL", "order_tel01", "order_tel02", "order_tel03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("FAX", "order_fax01", "order_fax02", "order_fax03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "order_zip01", "order_zip02"), array("ALL_EXIST_CHECK"));
+    $objErr->doFunc(array("TEL", "deliv_tel01", "deliv_tel02", "deliv_tel03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("FAX", "deliv_fax01", "deliv_fax02", "deliv_fax03", TEL_ITEM_LEN), array("TEL_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "deliv_zip01", "deliv_zip02"), array("ALL_EXIST_CHECK"));
+    $objErr->doFunc(array("À¸Ç¯·îÆü", "year", "month", "day"), array("CHECK_DATE"));
+    $objErr->doFunc(array("¥á¡¼¥ë¥¢¥É¥ì¥¹", "¥á¡¼¥ë¥¢¥É¥ì¥¹¡Ê³ÎÇ§¡Ë", "order_email", "order_email_check"), array("EQUAL_CHECK"));
+    
+    // ¤¹¤Ç¤Ë¥á¥ë¥Þ¥¬¥Æ¡¼¥Ö¥ë¤Ë²ñ°÷¤È¤·¤Æ¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¾ì¹ç
+    if(sfCheckCustomerMailMaga($arrRet['order_email'])) {
+        $objErr->arrErr['order_email'] = "¤³¤Î¥á¡¼¥ë¥¢¥É¥ì¥¹¤Ï¤¹¤Ç¤ËÅÐÏ¿¤µ¤ì¤Æ¤¤¤Þ¤¹¡£<br>";
+    }
+        
+    return $objErr->arrErr;
+}
+
+// ¼õÃí°ì»þ¥Æ¡¼¥Ö¥ë¤Î¤ªÆÏ¤±Àè¤ò¥³¥Ô¡¼¤¹¤ë
+function lfCopyDeliv($uniqid, $arrData) {
+    $objQuery = new SC_Query();
+    
+    // ÊÌ¤Î¤ªÆÏ¤±Àè¤ò»ØÄê¤·¤Æ¤¤¤Ê¤¤¾ì¹ç¡¢ÇÛÁ÷Àè¤ËÅÐÏ¿½»½ê¤ò¥³¥Ô¡¼¤¹¤ë¡£
+    if($arrData["deliv_check"] != "1") {
+        $sqlval['deliv_name01'] = $arrData['order_name01'];
+        $sqlval['deliv_name02'] = $arrData['order_name02'];
+        $sqlval['deliv_kana01'] = $arrData['order_kana01'];
+        $sqlval['deliv_kana02'] = $arrData['order_kana02'];
+        $sqlval['deliv_pref'] = $arrData['order_pref'];
+        $sqlval['deliv_zip01'] = $arrData['order_zip01'];
+        $sqlval['deliv_zip02'] = $arrData['order_zip02'];
+        $sqlval['deliv_addr01'] = $arrData['order_addr01'];
+        $sqlval['deliv_addr02'] = $arrData['order_addr02'];
+        $sqlval['deliv_tel01'] = $arrData['order_tel01'];
+        $sqlval['deliv_tel02'] = $arrData['order_tel02'];
+        $sqlval['deliv_tel03'] = $arrData['order_tel03'];
+        $where = "order_temp_id = ?";
+        $objQuery->update("dtb_order_temp", $sqlval, $where, array($uniqid));
+    }
 }
 ?>
Index: /branches/beta/html/mobile/shopping/complete.php
===================================================================
--- /branches/beta/html/mobile/shopping/complete.php	(revision 11894)
+++ /branches/beta/html/mobile/shopping/complete.php	(revision 14676)
@@ -56,7 +56,14 @@
 	$objCustomer->updateSession();
 
-	// ´°Î»¥á¡¼¥ëÁ÷¿®
+	// ´°Î»¥á¡¼¥ëÁ÷¿® 4¤Ï·ÈÂÓÈÇ
 	if($order_id != "") {
-		sfSendOrderMail($order_id, '1');
+		$order_email = $objQuery->select("order_email", "dtb_order", "order_id = ?", array($order_id));
+    
+    //ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬·ÈÂÓ¤«PC¤«¤Ë±þ¤¸¤ÆÃíÊ¸´°Î»¥á¡¼¥ë¤Î¥Æ¥ó¥×¥ì¡¼¥È¤òÊÑ¤¨¤ë
+    if(ereg("(ezweb.ne.jp$|docomo.ne.jp$|softbank.ne.jp$|vodafone.ne.jp$)",$order_email[0]['order_email'])){
+              sfSendOrderMail($order_id, '1', '', '');
+        }else{
+              sfSendOrderMail($order_id, '0', '', '');
+        }
 	}
 
@@ -257,5 +264,5 @@
 	$objMailView = new SC_SiteView();
 	$objMailView->assignobj($objMailPage);
-	$body = $objMailView->fetch("mail_templates/customer_mail.tpl");
+	$body = $objMailView->fetch("/mail_templates/customer_mail.tpl");
 	
 	$objMail = new GC_SendMail();
@@ -273,4 +280,5 @@
 	// °¸Àè¤ÎÀßÄê
 	$name = $arrData['order_name01'] . $arrData['order_name02'] ." ÍÍ";
+	$arrData['order_email'] = $objQuery->select("email_mobile", "dtb_customer", "secret_key = ?", array($sqlval['secret_key']));
 	$objMail->setTo($arrData['order_email'], $name);			
 	$objMail->sendMail();
Index: /branches/beta/html/mobile/shopping/nonmember_index.php
===================================================================
--- /branches/beta/html/mobile/shopping/nonmember_index.php	(revision 14676)
+++ /branches/beta/html/mobile/shopping/nonmember_index.php	(revision 14676)
@@ -0,0 +1,456 @@
+<?php
+/*
+ * Copyright(c) 2000-2006 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+
+require_once("../require.php");
+
+class LC_Page {
+    function LC_Page() {
+        $this->tpl_mainpage = 'nonmember/index.tpl';        // ¥á¥¤¥ó¥Æ¥ó¥×¥ì¡¼¥È
+        $this->tpl_title .= '¤ªµÒÍÍ¾ðÊóÆþÎÏ(1/3)';            //¡¡¥Ú¡¼¥¸¥¿¥¤¥È¥ë
+    }
+}
+
+//---- ¥Ú¡¼¥¸½é´üÀßÄê
+$CONF = sf_getBasisData();                  // Å¹ÊÞ´ðËÜ¾ðÊó
+$objConn = new SC_DbConn();
+$objPage = new LC_Page();
+$objView = new SC_MobileView();
+$objDate = new SC_Date(START_BIRTH_YEAR, date("Y",strtotime("now")));
+$objPage->arrPref = $arrPref;
+$objPage->arrJob = $arrJob;
+$objPage->arrReminder = $arrReminder;
+$objPage->arrYear = $objDate->getYear('', 1950);    //¡¡ÆüÉÕ¥×¥ë¥À¥¦¥óÀßÄê
+$objPage->arrMonth = $objDate->getMonth();
+$objPage->arrDay = $objDate->getDay();
+
+//SSLURLÈ½Äê
+if (SSLURL_CHECK == 1){
+    $ssl_url= sfRmDupSlash(MOBILE_SSL_URL.$_SERVER['REQUEST_URI']);
+    if (!ereg("^https://", $non_ssl_url)){
+        sfDispSiteError(URL_ERROR, "", false, "", true);
+    }
+}
+
+// ¥ì¥¤¥¢¥¦¥È¥Ç¥¶¥¤¥ó¤ò¼èÆÀ
+$objPage = sfGetPageLayout($objPage, false, DEF_LAYOUT);
+
+//---- ÅÐÏ¿ÍÑ¥«¥é¥àÇÛÎó
+$arrRegistColumn = array(
+                             array(  "column" => "name01", "convert" => "aKV" ),
+                             array(  "column" => "name02", "convert" => "aKV" ),
+                             array(  "column" => "kana01", "convert" => "CKV" ),
+                             array(  "column" => "kana02", "convert" => "CKV" ),
+                             array(  "column" => "zip01", "convert" => "n" ),
+                             array(  "column" => "zip02", "convert" => "n" ),
+                             array(  "column" => "pref", "convert" => "n" ),
+                             array(  "column" => "addr01", "convert" => "aKV" ),
+                             array(  "column" => "addr02", "convert" => "aKV" ),
+                             array(  "column" => "email", "convert" => "a" ),
+                             array(  "column" => "email2", "convert" => "a" ),
+                             array(  "column" => "email_mobile", "convert" => "a" ),
+                             array(  "column" => "email_mobile2", "convert" => "a" ),
+                             array(  "column" => "tel01", "convert" => "n" ),
+                             array(  "column" => "tel02", "convert" => "n" ),
+                             array(  "column" => "tel03", "convert" => "n" ),
+                             array(  "column" => "fax01", "convert" => "n" ),
+                             array(  "column" => "fax02", "convert" => "n" ),
+                             array(  "column" => "fax03", "convert" => "n" ),
+                             array(  "column" => "sex", "convert" => "n" ),
+                             array(  "column" => "job", "convert" => "n" ),
+                             array(  "column" => "birth", "convert" => "n" ),
+                             array(  "column" => "reminder", "convert" => "n" ),
+                             array(  "column" => "reminder_answer", "convert" => "aKV"),
+                             array(  "column" => "password", "convert" => "a" ),
+                             array(  "column" => "password02", "convert" => "a" ),
+                             array(  "column" => "mailmaga_flg", "convert" => "n" ),
+                         );
+
+//---- ÅÐÏ¿½ü³°ÍÑ¥«¥é¥àÇÛÎó
+$arrRejectRegistColumn = array("year", "month", "day", "email02", "email_mobile02","password","password02","reminder","reminder_answer");
+
+if ($_SERVER["REQUEST_METHOD"] == "POST") {
+
+    //-- POST¥Ç¡¼¥¿¤Î°ú¤­·Ñ¤®
+    $objPage->arrForm = $_POST;
+    
+    if($objPage->arrForm['year'] == '----') {
+        $objPage->arrForm['year'] = '';
+    }
+    
+    $objPage->arrForm['email'] = strtolower($objPage->arrForm['email']);        // email¤Ï¤¹¤Ù¤Æ¾®Ê¸»ú¤Ç½èÍý
+    
+    //-- ÆþÎÏ¥Ç¡¼¥¿¤ÎÊÑ´¹
+    $objPage->arrForm = lfConvertParam($objPage->arrForm, $arrRegistColumn);
+
+    // Ìá¤ë¥Ü¥¿¥óÍÑ½èÍý
+    if (!empty($_POST["return"])) {
+        switch ($_POST["mode"]) {
+        case "complete":
+            $_POST["mode"] = "set3";
+            break;
+        case "confirm":
+            $_POST["mode"] = "set2";
+            break;
+        default:
+            $_POST["mode"] = "set1";
+            break;
+        }
+    }
+
+    //--¡¡ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+    if (!empty($_POST["mode"])) {
+            if ($_POST["mode"] == "set1") {
+            $objPage->arrErr = lfErrorCheck1($objPage->arrForm);
+            $objPage->tpl_mainpage = 'nonmember/index.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(1/3)';
+        } elseif ($_POST["mode"] == "set2") {
+            $objPage->arrErr = lfErrorCheck2($objPage->arrForm);
+            $objPage->tpl_mainpage = 'nonmember/set1.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(2/3)';
+        } else {
+            $objPage->arrErr = lfErrorCheck3($objPage->arrForm);
+            $objPage->tpl_mainpage = 'nonmember/set2.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(3/3)';
+        }
+    
+
+    foreach($objPage->arrForm as $key => $val) {
+        $objPage->$key = $val;
+        }
+    }
+
+
+    if ($objPage->arrErr || !empty($_POST["return"])) {     // ÆþÎÏ¥¨¥é¡¼¤Î¥Á¥§¥Ã¥¯
+
+        //-- ¥Ç¡¼¥¿¤ÎÀßÄê
+        if ($_POST["mode"] == "set1") {
+            $checkVal = array("email", "name01", "name02", "kana01", "kana02");
+        } elseif ($_POST["mode"] == "set2") {
+            $checkVal = array("sex", "year", "month", "day", "zip01", "zip02");
+        } else {
+            $checkVal = array("pref", "addr01", "addr02", "tel01", "tel02", "tel03", "mail_flag");
+        }
+
+        foreach($objPage->arrForm as $key => $val) {
+            if ($key != "mode" && $key != "submit" && $key != "return" && $key != session_name() && !in_array($key, $checkVal))
+                $objPage->list_data[ $key ] = $val;
+        }
+
+
+
+    } else {
+
+        //--¡¡¥Æ¥ó¥×¥ì¡¼¥ÈÀßÄê
+        if ($_POST["mode"] == "set1") {
+            $objPage->tpl_mainpage = 'nonmember/set1.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(2/3)';
+        } elseif ($_POST["mode"] == "set2") {
+            $objPage->tpl_mainpage = 'nonmember/set2.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(3/3)';
+
+            if (@$objPage->arrForm['pref'] == "" && @$objPage->arrForm['addr01'] == "" && @$objPage->arrForm['addr02'] == "") {
+                $address = lfGetAddress($_REQUEST['zip01'].$_REQUEST['zip02']);
+                $objPage->pref = @$address[0]['state'];
+                $objPage->addr01 = @$address[0]['city'] . @$address[0]['town'];
+            }
+        } elseif ($_POST["mode"] == "confirm") {
+            //¥Ñ¥¹¥ï¡¼¥ÉÉ½¼¨
+            
+            //¥á¡¼¥ë¼õ¤±¼è¤ê
+            if (strtolower($objPage->arrForm['mail_flag']) == "on") {
+                $objPage->arrForm['mail_flag']  = "2";
+            } else {
+                $objPage->arrForm['mail_flag']  = "3";
+            }
+
+            $objPage->tpl_mainpage = 'nonmember/confirm.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊó(³ÎÇ§¥Ú¡¼¥¸)';
+
+        }
+
+        //-- ¥Ç¡¼¥¿ÀßÄê
+        unset($objPage->list_data);
+        if ($_POST["mode"] == "set1") {
+            $checkVal = array("sex", "year", "month", "day", "zip01", "zip02");
+        } elseif ($_POST["mode"] == "set2") {
+            $checkVal = array("pref", "addr01", "addr02", "tel01", "tel02", "tel03", "mail_flag");
+        } else {
+            $checkVal = array();
+        }
+
+        foreach($objPage->arrForm as $key => $val) {
+            if ($key != "mode" && $key != "submit" && $key != "confirm" && $key != "return" && $key != session_name() && !in_array($key, $checkVal)) {
+                $objPage->list_data[ $key ] = $val;
+            }
+        }
+
+        if ($_POST["mode"] == "deliv") {
+            
+            
+            $objPage->tpl_mainpage = 'nonmember/deliv.tpl';
+            $objPage->tpl_title = '¤ªÆÏ¤±Àè¾ðÊó';
+        }
+        
+        //--¡¡²¾ÅÐÏ¿¤È´°Î»²èÌÌ
+        if ($_POST["mode"] == "complete") {
+            //$objPage->uniqid = lfRegistData ($objPage->arrForm, $arrRegistColumn, $arrRejectRegistColumn);
+
+            // ¶õ¥á¡¼¥ë¤ò¼õ¿®ºÑ¤ß¤Î¾ì¹ç¤Ï¤¹¤°¤ËËÜÅÐÏ¿´°Î»¤Ë¤¹¤ë¡£
+            if (isset($_SESSION['mobile']['kara_mail_from'])) {
+                header("Location:" . gfAddSessionId(MOBILE_URL_DIR . "regist/index.php?mode=regist&id=" . $objPage->uniqid));
+                exit;
+            }
+
+            $objPage->tpl_mainpage = 'nonmember/complete.tpl';
+            $objPage->tpl_title = '¤ªµÒÍÍ¾ðÊóÆþÎÏ(´°Î»¥Ú¡¼¥¸)';
+
+            /*sfMobileSetExtSessionId('id', $objPage->uniqid, 'regist/index.php');
+
+            //¡¡²¾ÅÐÏ¿´°Î»¥á¡¼¥ëÁ÷¿®
+            $objPage->CONF = $CONF;
+            $objPage->to_name01 = $_POST['name01'];
+            $objPage->to_name02 = $_POST['name02'];
+            $objMailText = new SC_MobileView();
+            $objMailText->assignobj($objPage);
+            $subject = sfMakesubject('¤ªµÒÍÍ¾ðÊó¤Î¤´³ÎÇ§');
+            $toCustomerMail = $objMailText->fetch("mail_templates/customer_mail.tpl");
+            $objMail = new GC_SendMail();
+            $objMail->setItem(
+                                ''                                  //¡¡°¸Àè
+                                , $subject                          //¡¡¥µ¥Ö¥¸¥§¥¯¥È
+                                , $toCustomerMail                   //¡¡ËÜÊ¸
+                                , $CONF["email03"]                  //¡¡ÇÛÁ÷¸µ¥¢¥É¥ì¥¹
+                                , $CONF["shop_name"]                //¡¡ÇÛÁ÷¸µ¡¡Ì¾Á°
+                                , $CONF["email03"]                  //¡¡reply_to
+                                , $CONF["email04"]                  //¡¡return_path
+                                , $CONF["email04"]                  //  Errors_to
+                                , $CONF["email01"]                  //  Bcc
+                                                                );
+            // °¸Àè¤ÎÀßÄê
+            $name = $_POST["name01"] . $_POST["name02"] ." ÍÍ";
+            $objMail->setTo($_POST["email"], $name);
+            $objMail->sendMail();
+*/
+            // ´°Î»¥Ú¡¼¥¸¤Ë°ÜÆ°¤µ¤»¤ë¡£
+            header("Location:" . gfAddSessionId("./complete.php"));
+            exit;
+        }
+    }
+}
+
+//----¡¡¥Ú¡¼¥¸É½¼¨
+$objView->assignobj($objPage);
+$objView->display(SITE_FRAME);
+
+//----------------------------------------------------------------------------------------------------------------------
+
+//---- function·²
+function lfRegistData ($array, $arrRegistColumn, $arrRejectRegistColumn) {
+    global $objConn;
+
+    // ²¾ÅÐÏ¿
+    foreach ($arrRegistColumn as $data) {
+        if (strlen($array[ $data["column"] ]) > 0 && ! in_array($data["column"], $arrRejectRegistColumn)) {
+            $arrRegist[ $data["column"] ] = $array[ $data["column"] ];
+        }
+    }
+        
+    // ÃÂÀ¸Æü¤¬ÆþÎÏ¤µ¤ì¤Æ¤¤¤ë¾ì¹ç
+    if (strlen($array["year"]) > 0 ) {
+        $arrRegist["birth"] = $array["year"] ."/". $array["month"] ."/". $array["day"] ." 00:00:00";
+    }
+    
+    // ¥Ñ¥¹¥ï¡¼¥É¤Î°Å¹æ²½
+    $arrRegist["password"] = sha1($arrRegist["password"] . ":" . AUTH_MAGIC);
+    
+    $count = 1;
+    while ($count != 0) {
+        $uniqid = sfGetUniqRandomId("t");
+        $count = $objConn->getOne("SELECT COUNT(*) FROM dtb_customer WHERE secret_key = ?", array($uniqid));
+    }
+
+    switch($array["mailmaga_flg"]) {
+        case 1:
+            $arrRegist["mailmaga_flg"] = 4; 
+            break;
+        case 2:
+            $arrRegist["mailmaga_flg"] = 5; 
+            break;
+        default:
+            $arrRegist["mailmaga_flg"] = 6;
+            break;
+    }
+        
+    $arrRegist["secret_key"] = $uniqid;     // ²¾ÅÐÏ¿IDÈ¯¹Ô
+    $arrRegist["create_date"] = "now()";    // ºîÀ®Æü
+    $arrRegist["update_date"] = "now()";    // ¹¹¿·Æü
+    $arrRegist["first_buy_date"] = "";      // ºÇ½é¤Î¹ØÆþÆü
+    
+    // ·ÈÂÓ¥á¡¼¥ë¥¢¥É¥ì¥¹
+    $arrRegist['email_mobile'] = $arrRegist['email'];
+
+    //-- ²¾ÅÐÏ¿¼Â¹Ô
+    $objConn->query("BEGIN");
+
+    $objQuery = new SC_Query();
+    $objQuery->insert("dtb_customer", $arrRegist);
+
+/* ¥á¥ë¥Þ¥¬²ñ°÷µ¡Ç½¤Ï¸½ºßÄä»ßÃæ¡¡2007/03/07
+    //--¡¡Èó²ñ°÷¤Ç¥á¥ë¥Þ¥¬ÅÐÏ¿¤·¤Æ¤¤¤ë¤«¤ÎÈ½Äê
+    $sql = "SELECT count(*) FROM dtb_customer_mail WHERE email = ?";
+    $mailResult = $objConn->getOne($sql, array($arrRegist["email"]));
+
+    //--¡¡¥á¥ë¥Þ¥¬²¾ÅÐÏ¿¼Â¹Ô
+    $arrRegistMail["email"] = $arrRegist["email"];  
+    if ($array["mailmaga_flg"] == 1) {
+        $arrRegistMail["mailmaga_flg"] = 4; 
+    } elseif ($array["mailmaga_flg"] == 2) {
+        $arrRegistMail["mailmaga_flg"] = 5; 
+    } else {
+        $arrRegistMail["mailmaga_flg"] = 6; 
+    }
+    $arrRegistMail["update_date"] = "now()";
+    
+    // Èó²ñ°÷¤Ç¥á¥ë¥Þ¥¬ÅÐÏ¿¤·¤Æ¤¤¤ë¾ì¹ç
+    if ($mailResult == 1) {     
+        $objQuery->update("dtb_customer_mail", $arrRegistMail, "email = '" .addslashes($arrRegistMail["email"]). "'");          
+    } else {                //¡¡¿·µ¬ÅÐÏ¿¤Î¾ì¹ç
+        $arrRegistMail["create_date"] = "now()";
+        $objQuery->insert("dtb_customer_mail", $arrRegistMail);     
+    }
+*/
+    $objConn->query("COMMIT");
+
+    return $uniqid;
+}
+
+//----¡¡¼èÆÀÊ¸»úÎó¤ÎÊÑ´¹
+function lfConvertParam($array, $arrRegistColumn) {
+    /*
+     *  Ê¸»úÎó¤ÎÊÑ´¹
+     *  K :  ¡ÖÈ¾³Ñ(ÊÝ¶¸)ÊÒ²¾Ì¾¡×¤ò¡ÖÁ´³ÑÊÒ²¾Ì¾¡×¤ËÊÑ´¹
+     *  C :  ¡ÖÁ´³Ñ¤Ò¤é²¾Ì¾¡×¤ò¡ÖÁ´³Ñ¤«¤¿²¾Ì¾¡×¤ËÊÑ´¹
+     *  V :  ÂùÅÀÉÕ¤­¤ÎÊ¸»ú¤ò°ìÊ¸»ú¤ËÊÑ´¹¡£"K","H"¤È¶¦¤Ë»ÈÍÑ¤·¤Þ¤¹ 
+     *  n :  ¡ÖÁ´³Ñ¡×¿ô»ú¤ò¡ÖÈ¾³Ñ(ÊÝ¶¸)¡×¤ËÊÑ´¹
+     *  a :  Á´³Ñ±Ñ¿ô»ú¤òÈ¾³Ñ±Ñ¿ô»ú¤ËÊÑ´¹¤¹¤ë
+     */
+    // ¥«¥é¥àÌ¾¤È¥³¥ó¥Ð¡¼¥È¾ðÊó
+    foreach ($arrRegistColumn as $data) {
+        $arrConvList[ $data["column"] ] = $data["convert"];
+    }
+    // Ê¸»úÊÑ´¹
+    foreach ($arrConvList as $key => $val) {
+        // POST¤µ¤ì¤Æ¤­¤¿ÃÍ¤Î¤ßÊÑ´¹¤¹¤ë¡£
+        if(strlen(($array[$key])) > 0) {
+            $array[$key] = mb_convert_kana($array[$key] ,$val);
+        }
+    }
+    return $array;
+}
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck1($array) {
+
+    global $objConn;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÀ«¡Ë", 'name01', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("¤ªÌ¾Á°¡ÊÌ¾¡Ë", 'name02', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" , "MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/À«¡Ë", 'kana01', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK", "KANA_CHECK"));
+    $objErr->doFunc(array("¤ªÌ¾Á°¡Ê¥«¥Ê/Ì¾¡Ë", 'kana02', STEXT_LEN), array("EXIST_CHECK", "NO_SPTAB", "SPTAB_CHECK" ,"MAX_LENGTH_CHECK", "KANA_CHECK"));
+    $objErr->doFunc(array('¥á¡¼¥ë¥¢¥É¥ì¥¹', "email", MTEXT_LEN) ,array("NO_SPTAB", "EXIST_CHECK", "EMAIL_CHECK", "SPTAB_CHECK" ,"EMAIL_CHAR_CHECK", "MAX_LENGTH_CHECK", "MOBILE_EMAIL_CHECK"));
+
+    //¸½²ñ°÷¤ÎÈ½Äê ¢ª¡¡¸½²ñ°÷¤â¤·¤¯¤Ï²¾ÅÐÏ¿Ãæ¤Ï¡¢¥á¥¢¥É°ì°Õ¤¬Á°Äó¤Ë¤Ê¤Ã¤Æ¤ë¤Î¤ÇÆ±¤¸¥á¥¢¥É¤ÇÅÐÏ¿ÉÔ²Ä
+
+    return $objErr->arrErr;
+}
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck2($array) {
+
+    global $objConn, $objDate;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ1", "zip01", ZIP01_LEN ) ,array("EXIST_CHECK", "SPTAB_CHECK" ,"NUM_CHECK", "NUM_COUNT_CHECK"));
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ2", "zip02", ZIP02_LEN ) ,array("EXIST_CHECK", "SPTAB_CHECK" ,"NUM_CHECK", "NUM_COUNT_CHECK")); 
+    $objErr->doFunc(array("Í¹ÊØÈÖ¹æ", "zip01", "zip02"), array("ALL_EXIST_CHECK"));
+
+    $objErr->doFunc(array("À­ÊÌ", "sex") ,array("SELECT_CHECK", "NUM_CHECK")); 
+    $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", 4), array("EXIST_CHECK", "SPTAB_CHECK", "NUM_CHECK", "NUM_COUNT_CHECK"));
+    if (!isset($objErr->arrErr['year'])) {
+        $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", $objDate->getStartYear()), array("MIN_CHECK"));
+        $objErr->doFunc(array("À¸Ç¯·îÆü (Ç¯)", "year", $objDate->getEndYear()), array("MAX_CHECK"));
+    }
+    $objErr->doFunc(array("À¸Ç¯·îÆü (·îÆü)", "month", "day"), array("SELECT_CHECK"));
+    if (!isset($objErr->arrErr['year']) && !isset($objErr->arrErr['month']) && !isset($objErr->arrErr['day'])) {
+        $objErr->doFunc(array("À¸Ç¯·îÆü", "year", "month", "day"), array("CHECK_DATE"));
+    }
+    
+    return $objErr->arrErr;
+}
+
+//---- ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck3($array) {
+
+    global $objConn;
+    $objErr = new SC_CheckError($array);
+    
+    $objErr->doFunc(array("ÅÔÆ»ÉÜ¸©", 'pref'), array("SELECT_CHECK","NUM_CHECK"));
+    $objErr->doFunc(array("»Ô¶èÄ®Â¼", "addr01", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("ÈÖÃÏ", "addr02", MTEXT_LEN), array("EXIST_CHECK","SPTAB_CHECK" ,"MAX_LENGTH_CHECK"));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ1", 'tel01'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ2", 'tel02'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ3", 'tel03'), array("EXIST_CHECK","SPTAB_CHECK" ));
+    $objErr->doFunc(array("ÅÅÏÃÈÖ¹æ", "tel01", "tel02", "tel03",TEL_ITEM_LEN) ,array("TEL_CHECK"));
+    
+    return $objErr->arrErr;
+}
+
+//³ÎÇ§¥Ú¡¼¥¸ÍÑ¥Ñ¥¹¥ï¡¼¥ÉÉ½¼¨ÍÑ
+
+function lfPassLen($passlen){
+    $ret = "";
+    for ($i=0;$i<$passlen;true){
+    $ret.="*";
+    $i++;
+    }
+    return $ret;
+}
+
+
+// Í¹ÊØÈÖ¹æ¤«¤é½»½ê¤Î¼èÆÀ
+function lfGetAddress($zipcode) {
+    global $arrPref;
+
+    $conn = new SC_DBconn(ZIP_DSN);
+
+    // Í¹ÊØÈÖ¹æ¸¡º÷Ê¸ºîÀ®
+    $zipcode = mb_convert_kana($zipcode ,"n");
+    $sqlse = "SELECT state, city, town FROM mtb_zip WHERE zipcode = ?";
+
+    $data_list = $conn->getAll($sqlse, array($zipcode));
+
+    // ¥¤¥ó¥Ç¥Ã¥¯¥¹¤ÈÃÍ¤òÈ¿Å¾¤µ¤»¤ë¡£
+    $arrREV_PREF = array_flip($arrPref);
+
+    /*
+        ÁíÌ³¾Ê¤«¤é¥À¥¦¥ó¥í¡¼¥É¤·¤¿¥Ç¡¼¥¿¤ò¤½¤Î¤Þ¤Þ¥¤¥ó¥Ý¡¼¥È¤¹¤ë¤È
+        °Ê²¼¤Î¤è¤¦¤ÊÊ¸»úÎó¤¬Æþ¤Ã¤Æ¤¤¤ë¤Î¤Ç   ÂÐºö¤¹¤ë¡£
+        ¡¦¡Ê£±¡¦£±£¹ÃúÌÜ¡Ë
+        ¡¦°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç
+    */
+    $town =  $data_list[0]['town'];
+    $town = ereg_replace("¡Ê.*¡Ë$","",$town);
+    $town = ereg_replace("°Ê²¼¤Ë·ÇºÜ¤¬¤Ê¤¤¾ì¹ç","",$town);
+    $data_list[0]['town'] = $town;
+    $data_list[0]['state'] = $arrREV_PREF[$data_list[0]['state']];
+
+    return $data_list;
+}
+
+//-----------------------------------------------------------------------------------------------------------------------------------
+?>
Index: /branches/beta/html/js/json.js
===================================================================
--- /branches/beta/html/js/json.js	(revision 14676)
+++ /branches/beta/html/js/json.js	(revision 14676)
@@ -0,0 +1,206 @@
+//==============================================================================
+//  SYSTEM      :  »ÃÄêÈÇ¥¯¥í¥¹¥Ö¥é¥¦¥¶AjaxÍÑ¥é¥¤¥Ö¥é¥ê
+//  PROGRAM     :  XMLHttpRequest¤Ë¤è¤ëÁ÷¼õ¿®¤ò¹Ô¤¤¤Þ¤¹
+//  AUTHER      :  Toshirou Takahashi http://jsgt.org/mt/01/
+
+
+	////
+	// Æ°ºî²ÄÇ½¤Ê¥Ö¥é¥¦¥¶È½Äê
+	//
+	// @sample        if(chkAjaBrowser()){ location.href='nonajax.htm' }
+	// @sample        oj = new chkAjaBrowser();if(oj.bw.safari){ /* Safari code */ }
+	// @return        ¥é¥¤¥Ö¥é¥ê¤¬Æ°ºî²ÄÇ½¤Ê¥Ö¥é¥¦¥¶¤À¤±true  true|false
+	//
+	//  Enable list (v038¸½ºß)
+	//   WinIE 5.5+ 
+	//   Konqueror 3.3+
+	//   AppleWebKit·Ï(Safari,OmniWeb,Shiira) 124+ 
+	//   Mozilla·Ï(Firefox,Netscape,Galeon,Epiphany,K-Meleon,Sylera) 20011128+ 
+	//   Opera 8+ 
+	//
+	
+	function chkAjaBrowser()
+	{
+		var a,ua = navigator.userAgent;
+		this.bw= { 
+		  safari    : ((a=ua.split('AppleWebKit/')[1])?a.split('(')[0].split('.')[0]:0)>=124 ,
+		  konqueror : ((a=ua.split('Konqueror/')[1])?a.split(';')[0]:0)>=3.3 ,
+		  mozes     : ((a=ua.split('Gecko/')[1])?a.split(' ')[0]:0) >= 20011128 ,
+		  opera     : (!!window.opera) && ((typeof XMLHttpRequest)=='function') ,
+		  msie      : (!!window.ActiveXObject)?(!!createHttpRequest()):false 
+		}
+		return (this.bw.safari||this.bw.konqueror||this.bw.mozes||this.bw.opera||this.bw.msie)
+	}
+
+	////
+	// XMLHttpRequest¥ª¥Ö¥¸¥§¥¯¥ÈÀ¸À®
+	//
+	// @sample        oj = createHttpRequest()
+	// @return        XMLHttpRequest¥ª¥Ö¥¸¥§¥¯¥È(¥¤¥ó¥¹¥¿¥ó¥¹)
+	//
+	function createHttpRequest()
+	{
+		if(window.XMLHttpRequest){
+			 //Win Mac Linux m1,f1,o8 Mac s1 Linux k3 & Win e7ÍÑ
+			return new XMLHttpRequest() ;
+		} else if(window.ActiveXObject){
+			 //Win e4,e5,e6ÍÑ
+			try {
+				return new ActiveXObject('Msxml2.XMLHTTP') ;
+			} catch (e) {
+				try {
+					return new ActiveXObject('Microsoft.XMLHTTP') ;
+				} catch (e2) {
+					return null ;
+	 			}
+	 		}
+		} else  {
+			return null ;
+		}
+	}
+	
+	////
+	// Á÷¼õ¿®´Ø¿ô
+	//
+	// @sample         sendRequest(onloaded,'&prog=1','POST','./about2.php',true,true)
+	// @sample         sendRequest(onloaded,{name:taro,id:123,sel:1},','POST','./about3.php',true,true)
+	// @sample         sendRequest({onload:loaded,onbeforsetheader:sethead},'',','POST','./about3.php',true,true)
+	// @param {string} callback ¼õ¿®»þ¤Ëµ¯Æ°¤¹¤ë´Ø¿ôÌ¾ 
+	// @param {object} callback ¼õ¿®»þ¤Ëµ¯Æ°¤¹¤ë´Ø¿ôÌ¾¤È¥Ø¥Ã¥À»ØÄê´Ø¿ôÌ¾{onload:´Ø¿ôÌ¾,onbeforsetheader:´Ø¿ôÌ¾} 
+	// @param {array}  callback ¼õ¿®»þ¤Ëµ¯Æ°¤¹¤ë´Ø¿ôÌ¾¤È¥Ø¥Ã¥À»ØÄê ary['onload']=´Ø¿ôÌ¾;ary['onbeforsetheader']=´Ø¿ôÌ¾ 
+	// @see                    http://jsgt.org/ajax/ref/head_test/header/Range/004/sample.htm
+	// @param {string} data	   Á÷¿®¤¹¤ë¥Ç¡¼¥¿ string¤Î¾ì¹ç(&Ì¾Á°1=ÃÍ1&Ì¾Á°2=ÃÍ2...)
+	// @param {object} data	   Á÷¿®¤¹¤ë¥Ç¡¼¥¿ object¤Î¾ì¹ç{Ì¾Á°1:ÃÍ1,Ì¾Á°2:ÃÍ2,...}
+	// @param {array}  data	   Á÷¿®¤¹¤ë¥Ç¡¼¥¿ array¤Î¾ì¹ç¤ÏÏ¢ÁÛÇÛÎó ary['Ì¾Á°1']=ÃÍ1;ary['Ì¾Á°2']=ÃÍ2
+	// @param {string}method   'POST' or 'GET'
+	// @param {string}url      ¥ê¥¯¥¨¥¹¥È¤¹¤ë¥Õ¥¡¥¤¥ë¤ÎURL
+	// @param {string}async	   ÈóÆ±´ü¤Ê¤étrue Æ±´ü¤Ê¤éfalse
+	// @param {string}sload	   ¥¹¡¼¥Ñ¡¼¥í¡¼¥É true¤Ç¶¯À©¡¢¾ÊÎ¬¤Þ¤¿¤Ïfalse¤Ç¥Ç¥Õ¥©¥ë¥È
+	// @param {string}user	   Ç§¾Ú¥Ú¡¼¥¸ÍÑ¥æ¡¼¥¶¡¼Ì¾
+	// @param {string}password Ç§¾Ú¥Ú¡¼¥¸ÍÑ¥Ñ¥¹¥ï¡¼¥É
+	//
+	sendRequest.README	 = {
+		url		: 'http://jsgt.org/ajax/ref/lib/ref.htm',
+		name	: 'sendRequest', 
+		version	: 0.51, 
+		license	: 'Public Domain',
+		author	: 'Toshiro Takahashi http://jsgt.org/mt/01/',memo:''
+	};
+	function sendRequest(callback,data,method,url,async,sload,user,password)
+	{
+		//XMLHttpRequest¥ª¥Ö¥¸¥§¥¯¥ÈÀ¸À®
+		var oj = createHttpRequest();
+		if( oj == null ) return null;
+		
+		//¶¯À©¥í¡¼¥É¤ÎÀßÄê
+		var sload = (!!sendRequest.arguments[5])?sload:false;
+		if(sload || method.toUpperCase() == 'GET')url += '?';
+		if(sload)url=url+'t='+(new Date()).getTime();
+		
+		//¥Ö¥é¥¦¥¶È½Äê
+		var bwoj = new chkAjaBrowser();
+		var opera	  = bwoj.bw.opera;
+		var safari	  = bwoj.bw.safari;
+		var konqueror = bwoj.bw.konqueror;
+		var mozes	  = bwoj.bw.mozes ;
+				
+		//callback¤òÊ¬²ò
+		//{onload:xxxx,onbeforsetheader:xxx}
+		if(typeof callback=='object'){
+			var callback_onload = callback.onload;
+			var callback_onbeforsetheader = callback.onbeforsetheader;
+		} else {
+			var callback_onload = callback;
+			var callback_onbeforsetheader = null;
+		}
+
+		//¼õ¿®½èÍý
+		//opera¤Ïonreadystatechange¤ËÂ¿½Å¥ì¥¹¥Ð¥°¤¬¤¢¤ë¤Î¤Çonload¤¬°ÂÁ´
+		//Moz,FireFox¤Ïoj.readyState==3¤Ç¤â¼õ¿®¤¹¤ë¤Î¤ÇÄÌ¾ï¤Ïonload¤¬°ÂÁ´
+		//Win ie¤Ç¤Ïonload¤ÏÆ°ºî¤·¤Ê¤¤
+		//Konqueror¤Ïonload¤¬ÉÔ°ÂÄê
+		//»²¹Íhttp://jsgt.org/ajax/ref/test/response/responsetext/try1.php
+		if(opera || safari || mozes){
+			oj.onload = function () { callback_onload(oj); }
+		} else {
+		
+			oj.onreadystatechange =function () 
+			{
+				if ( oj.readyState == 4 ){
+					//alert(oj.status+'--'+oj.getAllResponseHeaders());
+					callback_onload(oj);
+				}
+			}
+		}
+
+		//URL¥¨¥ó¥³¡¼¥É
+		data = uriEncode(data,url);
+		if(method.toUpperCase() == 'GET') {
+			url += data
+		}
+		
+		//open ¥á¥½¥Ã¥É
+		oj.open(method,url,async,user,password);
+
+		
+		//¥ê¥¯¥¨¥¹¥È¥Ø¥Ã¥À¥«¥¹¥¿¥Þ¥¤¥ºÍÑ¥³¡¼¥ë¥Ð¥Ã¥¯
+		//»È¤¦¾ì¹ç¤Ï¡¢¸Æ¤Ó½Ð¤·HTMLÂ¦¤ÎwindowÄ¾²¼¤Ø¥°¥í¡¼¥Ð¥ë¤Ê´Ø¿ôsetHeaders¤ò
+		//µ­½Ò¤·¡¢¤½¤ÎÃæ¤ÇsetRequestHeader()¤ò¥»¥Ã¥È¤·¤Æ¤¯¤À¤µ¤¤
+		//@sample function setHeaders(oj){oj.setRequestHeader('Content-Type',contentTypeUrlenc)}
+		//
+		if(!!callback_onbeforsetheader)callback_onbeforsetheader(oj);
+
+		//¥Ç¥Õ¥©¥ë¥È¥Ø¥Ã¥Àapplication/x-www-form-urlencoded¥»¥Ã¥È
+		setEncHeader(oj);
+		
+		
+		//¥Ç¥Ð¥Ã¥¯
+		//alert('////jslb_ajaxxx.js//// \n data:'+data+' \n method:'+method+' \n url:'+url+' \n async:'+async);
+		
+		//send ¥á¥½¥Ã¥É
+		oj.send(data);
+
+		//URI¥¨¥ó¥³¡¼¥É¥Ø¥Ã¥À¥»¥Ã¥È
+		function setEncHeader(oj){
+	
+			//¥Ø¥Ã¥Àapplication/x-www-form-urlencoded¥»¥Ã¥È
+			// @see  http://www.asahi-net.or.jp/~sd5a-ucd/rec-html401j/interact/forms.html#h-17.13.3
+			// @see  #h-17.3
+			//   ( enctype ¤Î¥Ç¥Õ¥©¥ë¥ÈÃÍ¤Ï 'application/x-www-form-urlencoded')
+			//   h-17.3¤Ë¤è¤ê¡¢POST/GETÌä¤ï¤ºÀßÄê
+			//   POST¤Ç'multipart/form-data'¤ò»ØÄê¤¹¤ëÉ¬Í×¤¬¤¢¤ë¾ì¹ç¤Ï¥«¥¹¥¿¥Þ¥¤¥º¤·¤Æ¤¯¤À¤µ¤¤¡£
+			//
+			//  ¤³¤Î¥á¥½¥Ã¥É¤¬Win Opera8.0¤Ç¥¨¥é¡¼¤Ë¤Ê¤Ã¤¿¤Î¤ÇÊ¬´ô(8.01¤ÏOK)
+			var contentTypeUrlenc = 'application/x-www-form-urlencoded; charset=UTF-8';
+			if(!window.opera){
+				oj.setRequestHeader('Content-Type',contentTypeUrlenc);
+			} else {
+				if((typeof oj.setRequestHeader) == 'function')
+					oj.setRequestHeader('Content-Type',contentTypeUrlenc);
+			}	
+			return oj
+		}
+
+		//URL¥¨¥ó¥³¡¼¥É
+		//°ú¿ôdata¤Ï¡¢string¤«object¤ÇÅÏ¤»¤Þ¤¹
+		function uriEncode(data,url){
+			var encdata =(url.indexOf('?')==-1)?'?dmy':'';
+			if(typeof data=='object'){
+				for(var i in data)
+					encdata+='&'+encodeURIComponent(i)+'='+encodeURIComponent(data[i]);
+			} else if(typeof data=='string'){
+				if(data=='')return '';
+				//&¤È=¤Ç°ìÃ¶Ê¬²ò¤·encode
+				var encdata = '';
+				var datas = data.split('&');
+				for(var i=1;i<datas.length;i++)
+				{
+					var dataq = datas[i].split('=');
+					encdata += '&'+encodeURIComponent(dataq[0])+'='+encodeURIComponent(dataq[1]);
+				}
+			} 
+			return encdata;
+		}
+
+		return oj
+	}
Index: /branches/beta/html/js/site.js
===================================================================
--- /branches/beta/html/js/site.js	(revision 11481)
+++ /branches/beta/html/js/site.js	(revision 14676)
@@ -359,2 +359,27 @@
 }
 
+//Í¹ÊØÈÖ¹æ¤«¤é½»½ê¤ò¸¡º÷¤¹¤ë¤¿¤á¾ðÊó¤òÈóÆ±´üÅª¤Ë¥Õ¥©¡¼¥à¤«¤é¥Ç¡¼¥¿¥Ù¡¼¥¹¤ËÁ÷¿®¤¹¤ë¡£
+function fnSendZipcode(){
+	
+	var zip01 = document.getElementsByName("order_zip01").item(0).value;
+	var zip02 = document.getElementsByName("order_zip02").item(0).value;
+	var checkNum = new RegExp("[^0-9]","g");
+	
+	if(checkNum.test(zip01 + zip02)){
+		alert("¿ô»ú¤òÆþÎÏ¤·¤Æ¤¯¤À¤µ¤¤¡£");
+		document.getElementsByName("order_zip01").item(0).value = "";
+		document.getElementsByName("order_zip02").item(0).value = "";
+	}else if(zip01.length >= 3 && zip02.length >= 4){
+		//input_zip_json.php¤ËÍ¹ÊØÈÖ¹æ¤òÁ÷¿®¤·¤ÆÌá¤Ã¤Æ¤­¤¿¥Ç¡¼¥¿¤òfnReturnAddress¤ËÅÏ¤¹
+		sendRequest(fnReturnAddress,'&zip01='+zip01+'&zip02='+zip02,'GET','../input_zip_json.php',true,true);
+	}
+}
+
+function fnReturnAddress(val){
+	
+	eval("var log ="  + val.responseText);
+	if(log.flag ==1){
+	document.getElementsByName("order_pref").item(0).value = log.pref;
+	document.getElementsByName("order_addr01").item(0).value =log.city + log.town;
+	}
+}
Index: /branches/beta/html/test/matsumoto/test.php
===================================================================
--- /branches/beta/html/test/matsumoto/test.php	(revision 14676)
+++ /branches/beta/html/test/matsumoto/test.php	(revision 14676)
@@ -0,0 +1,4 @@
+<?php
+$a = "²¤ÊÆ¤«";
+echo $a;
+?>
Index: /branches/beta/html/test/adachi/test.php
===================================================================
--- /branches/beta/html/test/adachi/test.php	(revision 14676)
+++ /branches/beta/html/test/adachi/test.php	(revision 14676)
@@ -0,0 +1,115 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+require_once("../require.php");
+
+// Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
+$objSess = new SC_Session();
+sfIsSuccess($objSess);
+
+// Smarty¤Ø¤ÎassignÍÑÏ¢ÁÛÇÛÎó
+$arrAssignVars = array(
+    'tpl_mainpage' => 'basis/kiyaku.tpl',
+    'tpl_subnavi'  => 'basis/subnavi.tpl',
+    'tpl_subno'    => 'kiyaku',
+    'tpl_subtitle' => '²ñ°÷µ¬ÌóÅÐÏ¿',
+    'tpl_mainno'   => 'basis'
+);
+
+/** MODE¤ÎÈ½Äê **/
+switch(SC_Form::getMode()) {
+/** DBÅÐÏ¿½èÍý **/
+case 'register':
+    $objForm = lfInitRegisterMode();
+    $objForm->convert();
+    
+    if ($objForm->validate()->is_ok() === true) {
+        $arrAddInsertData = array(
+            'create_date' => 'NOW()',
+            'update_date' => 'NOW()',
+            'del_flg' => '0'
+        );
+        $objForm->insert('dtb_baseinfo', $arrAddInsertData);
+    } else {
+        $arrAssignVars['arrErr']  = $objForm->getEM();
+        $arrAssignVars['arrForm'] = $objForm->getParams(); 
+    }
+    
+    break:
+/** ºï½ü **/
+case 'delete':
+    
+    $objForm = lfInitDeleteMode();
+    
+    if ($objForm->validate()->is_ok === true) {
+        sfDeleteRankRecord('dtb_kiyaku', 'kiyaku_id', $objForm->getParams(), '', true);
+        sfReload();
+    } else {
+        sfDispError('PAGE_ERROR');
+    }
+    
+    break;
+/** ÊÔ½¸Á°½èÍý **/
+case 'pre_edit':
+    $objForm = lfInitPreEditMode();
+    
+    if ($objForm->validate()->is_ok === true) {
+        // ÊÔ½¸¹àÌÜ¤òDB¤è¤ê¼èÆÀ¤¹¤ë¡£
+        $where = "kiyaku_id = ?";
+        $objQuery = new SC_Query();
+        $arrKiyakuInfo = $objQuery->select("kiyaku_text, kiyaku_title", "dtb_kiyaku", $where, array($_POST['kiyaku_id']));
+        
+        // ÆþÎÏ¹àÌÜ¤Ë¥«¥Æ¥´¥êÌ¾¤òÆþÎÏ¤¹¤ë¡£
+        $arrAssignVars['kiyaku_title'] = $arrKiyakuInfo[0]['kiyaku_title'];
+        $arrAssignVars['kiyaku?text']  = $arrKiyakuInfo[0]['kiyaku_text'];
+        $arrAssignVars['tpl_kiyaku_id'] = $objForm->getParams();
+    } else {
+        sfDispPage();
+    }
+    
+    break;
+case 'down':
+	sfRankDown("dtb_kiyaku", "kiyaku_id", $_POST['kiyaku_id']);
+	// ºÆÉ½¼¨
+	sfReload();
+	break;
+case 'up':
+	sfRankUp("dtb_kiyaku", "kiyaku_id", $_POST['kiyaku_id']);
+	// ºÆÉ½¼¨
+	sfReload();
+	break;
+default:
+	break;
+}
+
+// µ¬³Ê¤ÎÆÉ¹þ
+$where = "del_flg <> 1";
+$objQuery->setOrder("rank DESC");
+$arrAssignVars['arrKiyaku'] = $objQuery->select("kiyaku_title, kiyaku_text, kiyaku_id", "dtb_kiyaku", $where);
+
+$objView = new SC_AdminView();
+$objView->assignArray($arrAssignVars);
+$objView->display(MAIN_FRAME);
+
+function lfInitEditMode(){
+    $arrParamsInfo = array(
+        'kiyaku_text' => array(
+            'dispName'     => 'ËÜÊ¸',
+            'convertType'  => 'KVa',
+            'validateType' => array(
+                '' => true,
+                'min'     => 1,
+                'max'     => 5,
+                'type'    => 'alnum',
+                'htmlTag' => array(),
+                
+            )
+        )
+    );
+    
+    $objForm = new SC_Form($_POST, $arrParamsInfo);
+    return $objForm;
+}
Index: /branches/beta/html/test/adachi/test2.php
===================================================================
--- /branches/beta/html/test/adachi/test2.php	(revision 14676)
+++ /branches/beta/html/test/adachi/test2.php	(revision 14676)
@@ -0,0 +1,24 @@
+<?php
+
+require_once("../../require.php");
+require_once("SC_FormParamsManager.php");
+
+error_reporting(E_ALL);
+
+// Smarty¤Ø¤ÎassignÍÑÏ¢ÁÛÇÛÎó
+$arrAssignVars = array(
+    'tpl_mainpage' => 'basis/kiyaku.tpl',
+    'tpl_subnavi'  => 'basis/subnavi.tpl',
+    'tpl_subno'    => 'kiyaku',
+    'tpl_subtitle' => '²ñ°÷µ¬ÌóÅÐÏ¿',
+    'tpl_mainno'   => 'basis'
+);
+
+
+
+$objView = new SC_View();
+$objView->_smarty->template_dir = '/home/web/dev.ec-cube.net/html/test/adachi/templates/';
+$objView->_smarty->compile_dir  = '/home/web/dev.ec-cube.net/html/test/adachi/templates/';
+$objView->assignArray($arrAssignVars);
+$objView->display('/home/web/dev.ec-cube.net/html/test/adachi/templates/test2.tpl');
+?>
Index: /branches/beta/html/test/adachi/test3.php
===================================================================
--- /branches/beta/html/test/adachi/test3.php	(revision 14676)
+++ /branches/beta/html/test/adachi/test3.php	(revision 14676)
@@ -0,0 +1,18 @@
+<?php
+
+require_once("../../require.php");
+
+$objView = new SC_View();
+$arrAssignVars = array(
+    'test1' => '<script>alert("hello")</script>',
+    'test2' => 'test2<br>',
+    'arr'   => array('1','2','3')
+);
+
+//$objView->_smarty->template_dir = '/home/web/dev.ec-cube.net/html/test/adachi/templates/';
+//$objView->_smarty->compile_dir  = '/home/web/dev.ec-cube.net/html/test/adachi/templates_c/';
+
+$objView->_smarty->template_dir = 'C:\Eclipse322\workspace\dev.ec-cube.net\html\test\adachi\templates';
+$objView->_smarty->compile_dir  = 'C:\Eclipse322\workspace\dev.ec-cube.net\html\test\adachi\template_c';
+$objView->assignArray($arrAssignVars);
+$objView->display('C:\Eclipse322\workspace\dev.ec-cube.net\html\test\adachi\\templates/test3.tpl');
Index: /branches/beta/html/test/adachi/test4.php
===================================================================
--- /branches/beta/html/test/adachi/test4.php	(revision 14676)
+++ /branches/beta/html/test/adachi/test4.php	(revision 14676)
@@ -0,0 +1,19 @@
+<?php
+
+require_once('DB.php');
+
+$db_type     = 'mysql';
+$db_user     = 'user_name';
+$db_password = 'password';
+$db_server   = '127.0.0.1';
+$db_name     = 'db_name';
+
+$dsn = "$db_type://$db_user:$db_password@$db_server/$db_name";
+
+$db = DB::connect($dsn);
+
+if (PEAR::isError($db)) {
+    die($db->getMessage());
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser.php	(revision 14676)
@@ -0,0 +1,351 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * Key gateway class for XML_Feed_Parser package
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL
+ * @version    CVS: $Id: Parser.php,v 1.24 2006/08/15 13:04:00 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * XML_Feed_Parser_Type is an abstract class required by all of our
+ * feed types. It makes sense to load it here to keep the other files
+ * clean.
+ */
+require_once 'XML/Feed/Parser/Type.php';
+
+/**
+ * We will throw exceptions when errors occur.
+ */
+require_once 'XML/Feed/Parser/Exception.php';
+
+/**
+ * This is the core of the XML_Feed_Parser package. It identifies feed types 
+ * and abstracts access to them. It is an iterator, allowing for easy access 
+ * to the entire feed.
+ *
+ * @author  James Stewart <james@jystewart.net>
+ * @version Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser implements Iterator
+{
+    /**
+     * This is where we hold the feed object 
+     * @var Object
+     */
+    private $feed;
+
+    /**
+     * To allow for extensions, we make a public reference to the feed model 
+     * @var DOMDocument
+     */
+    public $model;
+    
+    /**
+     * A map between entry ID and offset
+     * @var array
+     */
+    protected $idMappings = array();
+
+    /**
+     * A storage space for Namespace URIs.
+     * @var array
+     */
+    private $feedNamespaces = array(
+        'rss2' => array(
+            'http://backend.userland.com/rss',
+            'http://backend.userland.com/rss2',
+            'http://blogs.law.harvard.edu/tech/rss'));
+    /**
+     * Detects feed types and instantiate appropriate objects.
+     *
+     * Our constructor takes care of detecting feed types and instantiating
+     * appropriate classes. For now we're going to treat Atom 0.3 as Atom 1.0
+     * but raise a warning. I do not intend to introduce full support for 
+     * Atom 0.3 as it has been deprecated, but others are welcome to.
+     *
+     * @param    string    $feed    XML serialization of the feed
+     * @param    bool    $strict    Whether or not to validate the feed
+     * @param    bool    $suppressWarnings Trigger errors for deprecated feed types?
+     * @param    bool    $tidy    Whether or not to try and use the tidy library on input
+     */
+    function __construct($feed, $strict = false, $suppressWarnings = false, $tidy = false)
+    {
+        $this->model = new DOMDocument;
+        if (! $this->model->loadXML($feed)) {
+            if (extension_loaded('tidy') && $tidy) {
+                $tidy = new tidy;
+                $tidy->parseString($feed, 
+                    array('input-xml' => true, 'output-xml' => true));
+                $tidy->cleanRepair();
+                if (! $this->model->loadXML((string) $tidy)) {
+                    throw new XML_Feed_Parser_Exception('Invalid input: this is not ' .
+                        'valid XML');
+                }
+            } else {
+                throw new XML_Feed_Parser_Exception('Invalid input: this is not valid XML');
+            }
+
+        }
+
+        /* detect feed type */
+        $doc_element = $this->model->documentElement;
+        $error = false;
+
+        switch (true) {
+            case ($doc_element->namespaceURI == 'http://www.w3.org/2005/Atom'):
+                require_once 'XML/Feed/Parser/Atom.php';
+                require_once 'XML/Feed/Parser/AtomElement.php';
+                $class = 'XML_Feed_Parser_Atom';
+                break;
+            case ($doc_element->namespaceURI == 'http://purl.org/atom/ns#'):
+                require_once 'XML/Feed/Parser/Atom.php';
+                require_once 'XML/Feed/Parser/AtomElement.php';
+                $class = 'XML_Feed_Parser_Atom';
+                $error = 'Atom 0.3 deprecated, using 1.0 parser which won\'t provide ' .
+                    'all options';
+                break;
+            case ($doc_element->namespaceURI == 'http://purl.org/rss/1.0/' || 
+                ($doc_element->hasChildNodes() && $doc_element->childNodes->length > 1 
+                && $doc_element->childNodes->item(1)->namespaceURI == 
+                'http://purl.org/rss/1.0/')):
+                require_once 'XML/Feed/Parser/RSS1.php';
+                require_once 'XML/Feed/Parser/RSS1Element.php';
+                $class = 'XML_Feed_Parser_RSS1';
+                break;
+            case ($doc_element->namespaceURI == 'http://purl.org/rss/1.1/' || 
+                ($doc_element->hasChildNodes() && $doc_element->childNodes->length > 1 
+                && $doc_element->childNodes->item(1)->namespaceURI == 
+                'http://purl.org/rss/1.1/')):
+                require_once 'XML/Feed/Parser/RSS11.php';
+                require_once 'XML/Feed/Parser/RSS11Element.php';
+                $class = 'XML_Feed_Parser_RSS11';
+                break;
+            case (($doc_element->hasChildNodes() && $doc_element->childNodes->length > 1
+                && $doc_element->childNodes->item(1)->namespaceURI == 
+                'http://my.netscape.com/rdf/simple/0.9/') || 
+                $doc_element->namespaceURI == 'http://my.netscape.com/rdf/simple/0.9/'):
+                require_once 'XML/Feed/Parser/RSS09.php';
+                require_once 'XML/Feed/Parser/RSS09Element.php';
+                $class = 'XML_Feed_Parser_RSS09';
+                break;
+            case ($doc_element->tagName == 'rss' and
+                $doc_element->hasAttribute('version') && 
+                $doc_element->getAttribute('version') == 0.91):
+                $error = 'RSS 0.91 has been superceded by RSS2.0. Using RSS2.0 parser.';
+                require_once 'XML/Feed/Parser/RSS2.php';
+                require_once 'XML/Feed/Parser/RSS2Element.php';
+                $class = 'XML_Feed_Parser_RSS2';
+                break;
+            case ($doc_element->tagName == 'rss' and
+                $doc_element->hasAttribute('version') && 
+                $doc_element->getAttribute('version') == 0.92):
+                $error = 'RSS 0.92 has been superceded by RSS2.0. Using RSS2.0 parser.';
+                require_once 'XML/Feed/Parser/RSS2.php';
+                require_once 'XML/Feed/Parser/RSS2Element.php';
+                $class = 'XML_Feed_Parser_RSS2';
+                break;
+            case (in_array($doc_element->namespaceURI, $this->feedNamespaces['rss2'])
+                || $doc_element->tagName == 'rss'):
+                if (! $doc_element->hasAttribute('version') || 
+                    $doc_element->getAttribute('version') != 2) {
+                    $error = 'RSS version not specified. Parsing as RSS2.0';
+                }
+                require_once 'XML/Feed/Parser/RSS2.php';
+                require_once 'XML/Feed/Parser/RSS2Element.php';
+                $class = 'XML_Feed_Parser_RSS2';
+                break;
+            default:
+                throw new XML_Feed_Parser_Exception('Feed type unknown');
+                break;
+        }
+
+        if (! $suppressWarnings && ! empty($error)) {
+            trigger_error($error, E_USER_WARNING);
+        }
+
+        /* Instantiate feed object */
+        $this->feed = new $class($this->model, $strict);
+    }
+
+    /**
+     * Proxy to allow feed element names to be used as method names
+     *
+     * For top-level feed elements we will provide access using methods or 
+     * attributes. This function simply passes on a request to the appropriate 
+     * feed type object.
+     *
+     * @param   string  $call - the method being called
+     * @param   array   $attributes
+     */
+    function __call($call, $attributes)
+    {
+        $attributes = array_pad($attributes, 5, false);
+        list($a, $b, $c, $d, $e) = $attributes;
+        return $this->feed->$call($a, $b, $c, $d, $e);
+    }
+
+    /**
+     * Proxy to allow feed element names to be used as attribute names
+     *
+     * To allow variable-like access to feed-level data we use this
+     * method. It simply passes along to __call() which in turn passes
+     * along to the relevant object.
+     *
+     * @param   string  $val - the name of the variable required
+     */
+    function __get($val)
+    {
+        return $this->feed->$val;
+    }
+
+    /**
+     * Provides iteration functionality.
+     *
+     * Of course we must be able to iterate... This function simply increases
+     * our internal counter.
+     */
+    function next()
+    {
+        if (isset($this->current_item) && 
+            $this->current_item <= $this->feed->numberEntries - 1) {
+            ++$this->current_item;
+        } else if (! isset($this->current_item)) {
+            $this->current_item = 0;
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * Return XML_Feed_Type object for current element
+     *
+     * @return    XML_Feed_Parser_Type Object
+     */
+    function current()
+    {
+        return $this->getEntryByOffset($this->current_item);
+    }
+
+    /**
+     * For iteration -- returns the key for the current stage in the array.
+     *
+     * @return    int
+     */    
+    function key()
+    {
+        return $this->current_item;
+    }
+
+    /**
+     * For iteration -- tells whether we have reached the 
+     * end.
+     *
+     * @return    bool
+     */
+    function valid()
+    {
+        return $this->current_item < $this->feed->numberEntries;
+    }
+
+    /**
+     * For iteration -- resets the internal counter to the beginning.
+     */
+    function rewind()
+    {
+        $this->current_item = 0;
+    }
+
+    /**
+     * Provides access to entries by ID if one is specified in the source feed.
+     *
+     * As well as allowing the items to be iterated over we want to allow
+     * users to be able to access a specific entry. This is one of two ways of
+     * doing that, the other being by offset. This method can be quite slow
+     * if dealing with a large feed that hasn't yet been processed as it
+     * instantiates objects for every entry until it finds the one needed.
+     *
+     * @param    string    $id  Valid ID for the given feed format
+     * @return    XML_Feed_Parser_Type|false
+     */            
+    function getEntryById($id)
+    {
+        if (isset($this->idMappings[$id])) {
+            return $this->getEntryByOffset($this->idMappings[$id]);
+        }
+
+        /* 
+         * Since we have not yet encountered that ID, let's go through all the
+         * remaining entries in order till we find it.
+         * This is a fairly slow implementation, but it should work.
+         */
+        return $this->feed->getEntryById($id);
+    }
+
+    /**
+     * Retrieve entry by numeric offset, starting from zero.
+     *
+     * As well as allowing the items to be iterated over we want to allow
+     * users to be able to access a specific entry. This is one of two ways of
+     * doing that, the other being by ID.
+     *
+     * @param    int    $offset The position of the entry within the feed, starting from 0
+     * @return    XML_Feed_Parser_Type|false
+     */
+    function getEntryByOffset($offset)
+    {
+        if ($offset < $this->feed->numberEntries) {
+            if (isset($this->feed->entries[$offset])) {
+                return $this->feed->entries[$offset];
+            } else {
+                try {
+                    $this->feed->getEntryByOffset($offset);
+                } catch (Exception $e) {
+                    return false;
+                }
+                $id = $this->feed->entries[$offset]->getID();
+                $this->idMappings[$id] = $offset;
+                return $this->feed->entries[$offset];
+            }
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * Retrieve version details from feed type class.
+     *
+     * @return void
+     * @author James Stewart
+     */
+    function version()
+    {
+        return $this->feed->version;
+    }
+    
+    /**
+     * Returns a string representation of the feed.
+     * 
+     * @return String
+     **/
+    function __toString()
+    {
+        return $this->feed->__toString();
+    }
+}
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss091Values.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss091Values.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss091Values.php	(revision 14676)
@@ -0,0 +1,149 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_RSS091_valueValidity_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . "rss091-complete.xml");
+        $this->feed = new XML_Feed_Parser($this->file, false, true);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function test_feedRights()
+    {
+        $value = "Copyright 1997-1999 UserLand Software, Inc.";
+        $this->assertEquals($value, $this->feed->rights);
+        $this->assertEquals($value, $this->feed->copyright);
+    }
+
+    function test_feedNumberItems()
+    {
+        $value = 1;
+        $this->assertEquals($value, $this->feed->numberEntries);
+    }
+
+    function test_feedTitle()
+    {
+        $value = "Scripting News";
+        $this->assertEquals($value, $this->feed->title);
+    }
+    
+    function test_feedLink()
+    {
+        $value = "http://www.scripting.com/";
+        $this->assertEquals($value, $this->feed->link);
+    }
+    
+    function test_feedImage()
+    {
+        $value = array(
+            "title" => "Scripting News",
+            "link" => "http://www.scripting.com/",
+            "url" => "http://www.scripting.com/gifs/tinyScriptingNews.gif",
+            "description" => "What is this used for?",
+            'height' => "40",
+            'width' => "78");
+        $this->assertEquals($value, $this->feed->image);
+    }
+
+    function test_feedDescription()
+    {
+        $value = "News and commentary from the cross-platform scripting community.";
+        $this->assertEquals($value, $this->feed->description);
+    }
+    
+    function test_feedSubtitleEquivalence()
+    {
+        $value = "News and commentary from the cross-platform scripting community.";
+        $this->assertEquals($value, $this->feed->subtitle);
+    }
+    
+    function test_feedDate()
+    {
+        $value = strtotime("Thu, 08 Jul 1999 07:00:00 GMT");
+        $this->assertEquals($value, $this->feed->date);
+    }
+    
+    function test_feedLastBuildDate()
+    {
+        $value = strtotime("Thu, 08 Jul 1999 16:20:26 GMT");
+        $this->assertEquals($value, $this->feed->lastBuildDate);
+    }
+    
+    function test_feedUpdatedEquivalence()
+    {
+        $value = strtotime("Thu, 08 Jul 1999 16:20:26 GMT");
+        $this->assertEquals($value, $this->feed->updated);
+    }
+    
+    function test_feedLanguage()
+    {
+        $value = "en-us";
+        $this->assertEquals($value, $this->feed->language);
+    }
+    
+    function test_feedSkipHours()
+    {
+        $value = array("6", "7", "8", "9", "10", "11");
+        $this->assertEquals($value, $this->feed->skipHours);
+    }
+
+    function test_feedSkipDays()
+    {
+        $value = array("Sunday");
+        $this->assertEquals($value, $this->feed->skipDays);
+    }
+
+    function test_feedDocs()
+    {
+        $value = "http://my.userland.com/stories/storyReader$11";
+        $this->assertEquals($value, $this->feed->docs);
+    }
+    
+    function test_feedManagingEditor()
+    {
+        $value = "dave@userland.com (Dave Winer)";
+        $this->assertEquals($value, $this->feed->managingEditor);
+    }
+    
+    function test_feedAuthorEquivalence()
+    {
+        $value = "dave@userland.com (Dave Winer)";
+        $this->assertEquals($value, $this->feed->author);
+    }
+    
+    function test_feedWebmaster()
+    {
+        $value = "dave@userland.com (Dave Winer)";
+        $this->assertEquals($value, $this->feed->webMaster);
+    }
+    
+    function test_entryTitle()
+    {
+        $value = "stuff";
+        $this->assertEquals($value, $this->entry->title);
+    }
+    
+    function test_entryLink()
+    {
+        $value = "http://bar";
+        $this->assertEquals($value, $this->entry->link);
+    }
+    
+    function test_entryDescription()
+    {
+        $value = "This is an article about some stuff";
+        $this->assertEquals($value, $this->entry->description);
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_RSS091_valueValidity_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss092Values.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss092Values.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss092Values.php	(revision 14676)
@@ -0,0 +1,103 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_RSS092_valueValidity_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . "rss092-sample.xml");
+        $this->feed = new XML_Feed_Parser($this->file, false, true);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function test_feedNumberItems()
+    {
+        $value = 22;
+        $this->assertEquals($value, $this->feed->numberEntries);
+    }
+
+    function test_feedTitle()
+    {
+        $value = "Dave Winer: Grateful Dead";
+        $this->assertEquals($value, $this->feed->title);
+    }
+    
+    function test_feedLink()
+    {
+        $value = "http://www.scripting.com/blog/categories/gratefulDead.html";
+        $this->assertEquals($value, $this->feed->link);
+    }
+
+    function test_feedDescription()
+    {
+        $value = "A high-fidelity Grateful Dead song every day. This is where we're experimenting with enclosures on RSS news items that download when you're not using your computer. If it works (it will) it will be the end of the Click-And-Wait multimedia experience on the Internet. ";
+        $this->assertEquals($value, $this->feed->description);
+    }
+    
+    function test_feedSubtitleEquivalence()
+    {
+        $value = "A high-fidelity Grateful Dead song every day. This is where we're experimenting with enclosures on RSS news items that download when you're not using your computer. If it works (it will) it will be the end of the Click-And-Wait multimedia experience on the Internet. ";
+        $this->assertEquals($value, $this->feed->subtitle);
+    }
+    
+    function test_feedLastBuildDate()
+    {
+        $value = strtotime("Fri, 13 Apr 2001 19:23:02 GMT");
+        $this->assertEquals($value, $this->feed->lastBuildDate);
+    }
+    
+    function test_feedUpdatedEquivalence()
+    {
+        $value = strtotime("Fri, 13 Apr 2001 19:23:02 GMT");
+        $this->assertEquals($value, $this->feed->updated);
+    }
+    
+    function test_feedDocs()
+    {
+        $value = "http://backend.userland.com/rss092";
+        $this->assertEquals($value, $this->feed->docs);
+    }
+    
+    function test_feedManagingEditor()
+    {
+        $value = "dave@userland.com (Dave Winer)";
+        $this->assertEquals($value, $this->feed->managingEditor);
+    }
+    
+    function test_feedAuthorEquivalence()
+    {
+        $value = "dave@userland.com (Dave Winer)";
+        $this->assertEquals($value, $this->feed->author);
+    }
+    
+    function test_feedWebmaster()
+    {
+        $value = "dave@userland.com (Dave Winer)";
+        $this->assertEquals($value, $this->feed->webMaster);
+    }
+    
+    function test_entryDescription()
+    {
+        $value = "It's been a few days since I added a song to the Grateful Dead channel. Now that there are all these new Radio users, many of whom are tuned into this channel (it's #16 on the hotlist of upstreaming Radio users, there's no way of knowing how many non-upstreaming users are subscribing, have to do something about this..). Anyway, tonight's song is a live version of Weather Report Suite from Dick's Picks Volume 7. It's wistful music. Of course a beautiful song, oft-quoted here on Scripting News. <i>A little change, the wind and rain.</i>";
+        $this->assertEquals($value, trim($this->entry->description));
+    }
+    
+    function test_entryEnclosure()
+    {
+        $value = array(
+            'url' =>  'http://www.scripting.com/mp3s/weatherReportDicksPicsVol7.mp3',
+            'length' => '6182912',
+            'type' => 'audio/mpeg');
+        $this->assertEquals($value, $this->entry->enclosure);
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_RSS092_valueValidity_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomEntryOnly.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomEntryOnly.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomEntryOnly.php	(revision 14676)
@@ -0,0 +1,93 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_AtomEntryOnly_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->feed = new XML_Feed_Parser(file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'atom10-entryonly.xml'));
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function test_Title()
+    {
+        $value = 'Atom draft-07 snapshot';
+        $this->assertEquals($this->entry->title, $value);
+    }
+
+    function test_Id()
+    {
+        $value = 'tag:example.org,2003:3.2397';
+        $this->assertEquals($this->entry->id, $value);
+    }
+
+    function test_Updated()
+    {
+        $value = strtotime('2005-07-10T12:29:29Z');
+        $this->assertEquals($this->entry->updated, $value);
+    }
+
+    function test_Published()
+    {
+        $value = strtotime('2003-12-13T08:29:29-04:00');
+        $this->assertEquals($this->entry->published, $value);
+    }
+    
+    function test_AuthorURI()
+    {
+        $value = 'http://example.org/';
+        $this->assertEquals($value, $this->entry->author(null, array('param' => 'uri')));
+    }
+
+    function test_Contributor()
+    {
+        $value = 'Sam Ruby';
+        $this->assertEquals($this->entry->contributor, $value);
+    }
+
+    function test_Contributor2()
+    {
+        $value = 'Joe Gregorio';
+        $this->assertEquals($this->entry->contributor(1), $value);
+    }
+
+    function test_Content()
+    {
+        $value = '<p><i>[Update: The Atom draft is finished.]</i></p>';
+        $content = trim(preg_replace('/\t/', ' ', $this->entry->content));
+        $content = preg_replace('/(\s\s)+/', ' ', $content);
+        $this->assertEquals($value, $content);
+    }
+
+    function test_Link()
+    {
+        $value = 'http://example.org/2005/04/02/atom';
+        $this->assertEquals($this->entry->link, $value);
+    }
+    
+    function test_Enclosure()
+    {
+        $value = array (
+           'url' => 'http://example.org/audio/ph34r_my_podcast.mp3',
+           'type' => 'audio/mpeg',
+           'length' => '1337');
+        $this->assertEquals($this->entry->enclosure, $value);
+    }
+    
+    
+    function test_entryXPath()
+    {
+        $this->assertEquals('http://example.org/2005/04/02/atom', 
+            $this->entry->link(0, 'href', array('rel'=>'alternate')));
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite('XML_Feed_Parser_AtomEntryOnly_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/accessTypes.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/accessTypes.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/accessTypes.php	(revision 14676)
@@ -0,0 +1,189 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+/**
+ * This test is to make sure that we get sane values back for all
+ * elements specified by the atom specification. It is okay for a feed
+ * to not have some of these, but if they're not present we should
+ * get a null or false return rather than an error. This test begins
+ * to ensure consistency of our API.
+ */
+class XML_Feed_Parser_AccessTypes1_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'atom10-example1.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+    
+    function setUp() {
+    }
+    
+    function tearDown() {
+    }
+
+    function test_feedAuthor() {
+        $this->assertEquals($this->feed->author, $this->feed->author());
+    }
+    
+    function test_feedIcon() {
+        $this->assertEquals($this->feed->icon, $this->feed->icon());
+    }
+    
+    function test_feedId() {
+        $this->assertEquals($this->feed->id, $this->feed->id());
+    }
+    
+    function test_feedRights() {
+        $this->assertEquals($this->feed->rights, $this->feed->rights());
+    }
+    
+    function test_feedTitle() {
+        $this->assertEquals($this->feed->title, $this->feed->title());
+    }
+    
+    function test_feedSubtitle() {
+        $this->assertEquals($this->feed->subtitle, $this->feed->subtitle());
+    }
+    
+    function test_feedUpdated() {
+        $this->assertEquals($this->feed->updated, $this->feed->updated());
+    }
+    
+    function test_feedLink() {
+        $this->assertEquals($this->feed->link, $this->feed->link());
+    }
+    
+    function test_entryAuthor() {
+        $this->assertEquals($this->entry->author, $this->entry->author());
+    }
+    
+    function test_entryId() {
+        $this->assertEquals($this->entry->id, $this->entry->id());
+    }
+    
+    function test_entryPublished() {
+        $this->assertEquals($this->entry->published, $this->entry->published());
+    }
+    
+    function testEntryTitle() {
+        $this->assertEquals($this->entry->title, $this->entry->title());
+    }
+    
+    function testEntryRights() {
+        $this->assertEquals($this->entry->rights, $this->entry->rights());
+    }
+    
+    function testEntrySummary() {
+        $this->assertEquals($this->entry->summary, $this->entry->summary());
+    }
+    
+    function testEntryContent() {
+        $this->assertEquals($this->entry->content, $this->entry->content());
+    }
+    
+    function testEntryLink() {
+        $this->assertEquals($this->entry->link, $this->entry->link());
+    }
+}
+
+class XML_Feed_Parser_AccessTypes2_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'atom10-example2.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AccessTypes3_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'rss10-example1.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AccessTypes4_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'rss10-example2.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AccessTypes5_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'rss2sample.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AccessTypes6_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'delicious.feed');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AccessTypes7_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'technorati.feed');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AccessTypes8_TestCase extends XML_Feed_Parser_AccessTypes1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'grwifi-atom.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes1_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes2_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes3_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes4_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes5_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes6_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes7_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AccessTypes8_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/atom.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/atom.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/atom.php	(revision 14676)
@@ -0,0 +1,1552 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class atom_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_atom_namespace_1_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/atom_namespace_1.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_atom_namespace_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/atom_namespace_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_atom_namespace_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/atom_namespace_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_atom_namespace_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/atom_namespace_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_atom_namespace_5_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/atom_namespace_5.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_entry_author_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->author(0, 'email'));
+    }
+
+    function test_entry_author_homepage_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_homepage.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_entry_author_map_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_map_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author (me@example.com)', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_entry_author_map_author_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_map_author_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_entry_author_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->getEntryByOffset(0)->author(0, 'name'));
+    }
+
+    function test_entry_author_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_entry_author_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_author_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_entry_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_entry_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_entry_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_entry_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_entry_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_contributor_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_contributor_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->contributors(0, 'email'));
+    }
+
+    function test_entry_contributor_homepage_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_contributor_homepage.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_entry_contributor_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_contributor_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('name' => 'Contributor 1', 'email' => 'me@example.com', 'href' => 'http://example.com/'), array('name' => 'Contributor 2', 'email' => 'you@example.com', 'href' => 'http://two.example.com/')), $feed->getEntryByOffset(0)->contributors);
+    }
+
+    function test_entry_contributor_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_contributor_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->getEntryByOffset(0)->contributors(0, 'name'));
+    }
+
+    function test_entry_contributor_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_contributor_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_entry_contributor_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_contributor_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_entry_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_map_guid_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_id_map_guid.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->guid);
+    }
+
+    function test_entry_link_alternate_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_alternate_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_entry_link_alternate_map_link_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_alternate_map_link_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_entry_link_href_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_href.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->links(0, 'href'));
+    }
+
+    function test_entry_link_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('rel' => 'alternate', 'type' => 'application/xhtml+xml', 'href' => 'http://www.example.com/'), array('rel' => 'service.post', 'type' => 'application/atom+xml', 'href' => 'http://www.example.com/post')), $feed->getEntryByOffset(0)->links);
+    }
+
+    function test_entry_link_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->getEntryByOffset(0)->links(0, 'title'));
+    }
+
+    function test_entry_link_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_link_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->getEntryByOffset(0)->links(0, 'type'));
+    }
+
+    function test_entry_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_entry_summary_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_entry_summary_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->summary(0, 'type'));
+    }
+
+    function test_entry_summary_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->summary(0, 'type'));
+    }
+
+    function test_entry_summary_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_summary_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_entry_title_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_entry_title_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->title(0, 'type'));
+    }
+
+    function test_entry_title_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->title(0, 'type'));
+    }
+
+    function test_entry_title_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_text_plain_brackets_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/entry_title_text_plain_brackets.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('History of the <blink> tag', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_feed_author_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_feed_author_homepage_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_homepage.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->author(0, 'url'));
+    }
+
+    function test_feed_author_map_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_map_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author (me@example.com)', $feed->author);
+    }
+
+    function test_feed_author_map_author_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_map_author_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->author);
+    }
+
+    function test_feed_author_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->author(0, 'name'));
+    }
+
+    function test_feed_author_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->author(0, 'url'));
+    }
+
+    function test_feed_author_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_author_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->author(0, 'url'));
+    }
+
+    function test_feed_contributor_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_contributor_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->contributors(0, 'email'));
+    }
+
+    function test_feed_contributor_homepage_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_contributor_homepage.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->contributors(0, 'url'));
+    }
+
+    function test_feed_contributor_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_contributor_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('name' => 'Contributor 1', 'email' => 'me@example.com', 'href' => 'http://example.com/'), array('name' => 'Contributor 2', 'email' => 'you@example.com', 'href' => 'http://two.example.com/')), $feed->contributors);
+    }
+
+    function test_feed_contributor_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_contributor_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->contributors(0, 'name'));
+    }
+
+    function test_feed_contributor_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_contributor_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->contributors(0, 'url'));
+    }
+
+    function test_feed_contributor_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_contributor_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->contributors(0, 'url'));
+    }
+
+    function test_feed_copyright_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->copyright);
+    }
+
+    function test_feed_copyright_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->copyright);
+    }
+
+    function test_feed_copyright_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->copyright);
+    }
+
+    function test_feed_copyright_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_copyright_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_copyright_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->copyright(0, 'type'));
+    }
+
+    function test_feed_copyright_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->copyright(0, 'type'));
+    }
+
+    function test_feed_copyright_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->copyright);
+    }
+
+    function test_feed_copyright_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->copyright);
+    }
+
+    function test_feed_copyright_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->copyright);
+    }
+
+    function test_feed_copyright_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->copyright);
+    }
+
+    function test_feed_copyright_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->copyright);
+    }
+
+    function test_feed_copyright_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_copyright_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->copyright);
+    }
+
+    function test_feed_generator_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_generator.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->generator);
+    }
+
+    function test_feed_generator_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_generator_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->generator(0, 'name'));
+    }
+
+    function test_feed_generator_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_generator_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->generator(0, 'url'));
+    }
+
+    function test_feed_generator_version_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_generator_version.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2.65', $feed->generator(0, 'version'));
+    }
+
+    function test_feed_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->id);
+    }
+
+    function test_feed_id_map_guid_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_id_map_guid.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->guid);
+    }
+
+    function test_feed_info_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->info);
+    }
+
+    function test_feed_info_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->info);
+    }
+
+    function test_feed_info_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->info);
+    }
+
+    function test_feed_info_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_info_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_info_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->info(0, 'type'));
+    }
+
+    function test_feed_info_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->info(0, 'type'));
+    }
+
+    function test_feed_info_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->info);
+    }
+
+    function test_feed_info_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->info);
+    }
+
+    function test_feed_info_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->info);
+    }
+
+    function test_feed_info_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->info);
+    }
+
+    function test_feed_info_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->info);
+    }
+
+    function test_feed_info_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_info_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->info);
+    }
+
+    function test_feed_link_alternate_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_alternate_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->link);
+    }
+
+    function test_feed_link_alternate_map_link_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_alternate_map_link_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->link);
+    }
+
+    function test_feed_link_href_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_href.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->links(0, 'href'));
+    }
+
+    function test_feed_link_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('rel' => 'alternate', 'type' => 'application/xhtml+xml', 'href' => 'http://www.example.com/'), array('rel' => 'service.post', 'type' => 'application/atom+xml', 'href' => 'http://www.example.com/post')), $feed->links);
+    }
+
+    function test_feed_link_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->links(0, 'title'));
+    }
+
+    function test_feed_link_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_link_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->links(0, 'type'));
+    }
+
+    function test_feed_tagline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->tagline);
+    }
+
+    function test_feed_tagline_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->tagline);
+    }
+
+    function test_feed_tagline_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->tagline);
+    }
+
+    function test_feed_tagline_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_tagline_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_tagline_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->tagline(0, 'type'));
+    }
+
+    function test_feed_tagline_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->tagline(0, 'type'));
+    }
+
+    function test_feed_tagline_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->tagline);
+    }
+
+    function test_feed_tagline_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->tagline);
+    }
+
+    function test_feed_tagline_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->tagline);
+    }
+
+    function test_feed_tagline_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->tagline);
+    }
+
+    function test_feed_tagline_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->tagline);
+    }
+
+    function test_feed_tagline_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_tagline_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->tagline);
+    }
+
+    function test_feed_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_feed_title_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->title);
+    }
+
+    function test_feed_title_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->title);
+    }
+
+    function test_feed_title_content_mode_base64_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_content_mode_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_title_content_mode_escaped_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_content_mode_escaped.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_feed_title_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->title(0, 'type'));
+    }
+
+    function test_feed_title_content_type_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_content_type_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->title(0, 'type'));
+    }
+
+    function test_feed_title_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_feed_title_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->title);
+    }
+
+    function test_feed_title_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->title);
+    }
+
+    function test_feed_title_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->title);
+    }
+
+    function test_feed_title_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->title);
+    }
+
+    function test_feed_title_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/feed_title_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_relative_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/relative_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <a href="http://example.com/test/test.html">test</a></div>', $feed->title);
+    }
+
+    function test_relative_uri_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/relative_uri_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <a href="http://example.com/test/test.html">test</a></div>', $feed->title);
+    }
+
+    function test_relative_uri_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom/relative_uri_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <a href="http://example.com/test/test.html">test</a></div>', $feed->title);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('atom_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/atom10.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/atom10.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/atom10.php	(revision 14676)
@@ -0,0 +1,2377 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class atom10_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_atom10_namespace_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/atom10_namespace.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_atom10_version_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/atom10_version.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('atom10', $feed->version());
+    }
+
+    function test_entry_author_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_author_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->author(0, 'email'));
+    }
+
+    function test_entry_author_map_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_author_map_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author (me@example.com)', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_entry_author_map_author_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_author_map_author_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_entry_author_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_author_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->getEntryByOffset(0)->author(0, 'name'));
+    }
+
+    function test_entry_author_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_author_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_entry_author_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_author_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_entry_category_label_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_category_label.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Atom 1.0 tests', $feed->getEntryByOffset(0)->tags(0, 'label'));
+    }
+
+    function test_entry_category_scheme_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_category_scheme.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://feedparser.org/tests/', $feed->getEntryByOffset(0)->tags(0, 'scheme'));
+    }
+
+    function test_entry_category_term_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_category_term.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('atom10', $feed->getEntryByOffset(0)->tags(0, 'term'));
+    }
+
+    function test_entry_content_application_xml_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_application_xml.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_src_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_src.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/movie.mp4', $feed->getEntryByOffset(0)->content(0, 'src'));
+    }
+
+    function test_entry_content_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_text_plain_brackets_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_text_plain_brackets.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('History of the <blink> tag', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_entry_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_entry_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_contributor_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_contributor_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->contributors(0, 'email'));
+    }
+
+    function test_entry_contributor_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_contributor_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('name' => 'Contributor 1', 'email' => 'me@example.com', 'href' => 'http://example.com/'), array('name' => 'Contributor 2', 'email' => 'you@example.com', 'href' => 'http://two.example.com/')), $feed->getEntryByOffset(0)->contributors);
+    }
+
+    function test_entry_contributor_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_contributor_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->getEntryByOffset(0)->contributors(0, 'name'));
+    }
+
+    function test_entry_contributor_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_contributor_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_entry_contributor_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_contributor_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_entry_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_map_guid_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_map_guid.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->guid);
+    }
+
+    function test_entry_id_no_normalization_1_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_1.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.org/thing', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_no_normalization_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.org/Thing', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_no_normalization_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.EXAMPLE.org/thing', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_no_normalization_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('HTTP://www.example.org/thing', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_no_normalization_5_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_5.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/~bob', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_no_normalization_6_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_6.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/%7ebob', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_id_no_normalization_7_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_id_no_normalization_7.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/%7Ebob', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_entry_link_alternate_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_alternate_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_entry_link_alternate_map_link_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_alternate_map_link_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_entry_link_alternate_map_link_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_alternate_map_link_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/alternate', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_entry_link_href_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_href.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->links(0, 'href'));
+    }
+
+    function test_entry_link_hreflang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_hreflang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->links(0, 'hreflang'));
+    }
+
+    function test_entry_link_length_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_length.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('42301', $feed->getEntryByOffset(0)->links(0, 'length'));
+    }
+
+    function test_entry_link_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('rel' => 'alternate', 'type' => 'application/xhtml+xml', 'href' => 'http://www.example.com/'), array('rel' => 'service.post', 'type' => 'application/atom+xml', 'href' => 'http://www.example.com/post')), $feed->getEntryByOffset(0)->links);
+    }
+
+    function test_entry_link_no_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_no_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_rel_enclosure_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_enclosure.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('enclosure', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_rel_enclosure_map_enclosure_length_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_enclosure_map_enclosure_length.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('42301', $feed->getEntryByOffset(0)->enclosures(0, 'length'));
+    }
+
+    function test_entry_link_rel_enclosure_map_enclosure_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_enclosure_map_enclosure_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('video/mpeg4', $feed->getEntryByOffset(0)->enclosures(0, 'type'));
+    }
+
+    function test_entry_link_rel_enclosure_map_enclosure_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_enclosure_map_enclosure_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/movie.mp4', $feed->getEntryByOffset(0)->enclosures(0, 'href'));
+    }
+
+    function test_entry_link_rel_other_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_other.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://feedparser.org/rel/test', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_rel_related_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_related.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('related', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_rel_self_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_self.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('self', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_rel_via_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_rel_via.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('via', $feed->getEntryByOffset(0)->links(0, 'rel'));
+    }
+
+    function test_entry_link_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->getEntryByOffset(0)->links(0, 'title'));
+    }
+
+    function test_entry_link_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_link_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->getEntryByOffset(0)->links(0, 'type'));
+    }
+
+    function test_entry_rights_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_text_plain_brackets_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_text_plain_brackets.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('History of the <blink> tag', $feed->getEntryByOffset(0)->rights);
+    }
+
+    function test_entry_rights_type_default_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_type_default.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->rights(0, 'type'));
+    }
+
+    function test_entry_rights_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_rights_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->rights(0, 'type'));
+    }
+
+    function test_entry_source_author_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_author_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->source(0, 'author(0, 'email')'));
+    }
+
+    function test_entry_source_author_map_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_author_map_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author (me@example.com)', $feed->getEntryByOffset(0)->source(0, 'author'));
+    }
+
+    function test_entry_source_author_map_author_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_author_map_author_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->getEntryByOffset(0)->source(0, 'author'));
+    }
+
+    function test_entry_source_author_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_author_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->getEntryByOffset(0)->source(0, 'author(0, 'name')'));
+    }
+
+    function test_entry_source_author_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_author_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->source(0, 'author(0, 'url')'));
+    }
+
+    function test_entry_source_category_label_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_category_label.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Atom 1.0 tests', $feed->getEntryByOffset(0)->source(0, 'tags->label'));
+    }
+
+    function test_entry_source_category_scheme_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_category_scheme.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://feedparser.org/tests/', $feed->getEntryByOffset(0)->source(0, 'tags->scheme'));
+    }
+
+    function test_entry_source_category_term_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_category_term.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('atom10', $feed->getEntryByOffset(0)->source(0, 'tags->term'));
+    }
+
+    function test_entry_source_contributor_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_contributor_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->source(0, 'contributors->email'));
+    }
+
+    function test_entry_source_contributor_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_contributor_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('name' => 'Contributor 1', 'email' => 'me@example.com', 'href' => 'http://example.com/'), array('name' => 'Contributor 2', 'email' => 'you@example.com', 'href' => 'http://two.example.com/')), $feed->getEntryByOffset(0)->source(0, 'contributors'));
+    }
+
+    function test_entry_source_contributor_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_contributor_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->getEntryByOffset(0)->source(0, 'contributors->name'));
+    }
+
+    function test_entry_source_contributor_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_contributor_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->source(0, 'contributors->url'));
+    }
+
+    function test_entry_source_generator_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_generator.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->getEntryByOffset(0)->source(0, 'generator'));
+    }
+
+    function test_entry_source_generator_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_generator_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->getEntryByOffset(0)->source(0, 'generator(0, 'name')'));
+    }
+
+    function test_entry_source_generator_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_generator_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->source(0, 'generator(0, 'href')'));
+    }
+
+    function test_entry_source_generator_version_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_generator_version.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2.65', $feed->getEntryByOffset(0)->source(0, 'generator(0, 'version')'));
+    }
+
+    function test_entry_source_icon_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_icon.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/favicon.ico', $feed->getEntryByOffset(0)->source(0, 'icon'));
+    }
+
+    function test_entry_source_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->source(0, 'id'));
+    }
+
+    function test_entry_source_link_alternate_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_alternate_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->source(0, 'link'));
+    }
+
+    function test_entry_source_link_alternate_map_link_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_alternate_map_link_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->source(0, 'link'));
+    }
+
+    function test_entry_source_link_href_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_href.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->source(0, 'links->href'));
+    }
+
+    function test_entry_source_link_hreflang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_hreflang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->source(0, 'links->hreflang'));
+    }
+
+    function test_entry_source_link_length_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_length.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('42301', $feed->getEntryByOffset(0)->source(0, 'links->length'));
+    }
+
+    function test_entry_source_link_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('rel' => 'alternate', 'type' => 'application/xhtml+xml', 'href' => 'http://www.example.com/'), array('rel' => 'service.post', 'type' => 'application/atom+xml', 'href' => 'http://www.example.com/post')), $feed->getEntryByOffset(0)->source(0, 'links'));
+    }
+
+    function test_entry_source_link_no_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_no_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->getEntryByOffset(0)->source(0, 'links->rel'));
+    }
+
+    function test_entry_source_link_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->getEntryByOffset(0)->source(0, 'links->rel'));
+    }
+
+    function test_entry_source_link_rel_other_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_rel_other.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://feedparser.org/rel/test', $feed->getEntryByOffset(0)->source(0, 'links->rel'));
+    }
+
+    function test_entry_source_link_rel_related_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_rel_related.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('related', $feed->getEntryByOffset(0)->source(0, 'links->rel'));
+    }
+
+    function test_entry_source_link_rel_self_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_rel_self.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('self', $feed->getEntryByOffset(0)->source(0, 'links->rel'));
+    }
+
+    function test_entry_source_link_rel_via_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_rel_via.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('via', $feed->getEntryByOffset(0)->source(0, 'links->rel'));
+    }
+
+    function test_entry_source_link_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->getEntryByOffset(0)->source(0, 'links->title'));
+    }
+
+    function test_entry_source_link_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_link_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->getEntryByOffset(0)->source(0, 'links->type'));
+    }
+
+    function test_entry_source_logo_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_logo.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/logo.jpg', $feed->getEntryByOffset(0)->source(0, 'logo'));
+    }
+
+    function test_entry_source_rights_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->source(0, 'rights(0, 'type')'));
+    }
+
+    function test_entry_source_rights_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->source(0, 'rights(0, 'type')'));
+    }
+
+    function test_entry_source_rights_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_rights_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_rights_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'rights'));
+    }
+
+    function test_entry_source_subittle_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subittle_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->source(0, 'subtitle(0, 'type')'));
+    }
+
+    function test_entry_source_subtitle_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->source(0, 'subtitle(0, 'type')'));
+    }
+
+    function test_entry_source_subtitle_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_subtitle_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_subtitle_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'subtitle'));
+    }
+
+    function test_entry_source_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->source(0, 'title(0, 'type')'));
+    }
+
+    function test_entry_source_title_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->source(0, 'title(0, 'type')'));
+    }
+
+    function test_entry_source_title_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_source_title_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_source_title_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->source(0, 'title'));
+    }
+
+    function test_entry_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_type_default_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_type_default.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->summary(0, 'type'));
+    }
+
+    function test_entry_summary_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_summary_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->summary(0, 'type'));
+    }
+
+    function test_entry_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_text_plain_brackets_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_text_plain_brackets.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('History of the <blink> tag', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_type_default_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_type_default.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->title(0, 'type'));
+    }
+
+    function test_entry_title_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/entry_title_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->getEntryByOffset(0)->title(0, 'type'));
+    }
+
+    function test_feed_author_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_author_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_feed_author_map_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_author_map_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author (me@example.com)', $feed->author);
+    }
+
+    function test_feed_author_map_author_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_author_map_author_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->author);
+    }
+
+    function test_feed_author_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_author_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example author', $feed->author(0, 'name'));
+    }
+
+    function test_feed_author_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_author_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->author(0, 'url'));
+    }
+
+    function test_feed_author_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_author_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->author(0, 'url'));
+    }
+
+    function test_feed_contributor_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_contributor_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->contributors(0, 'email'));
+    }
+
+    function test_feed_contributor_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_contributor_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('name' => 'Contributor 1', 'email' => 'me@example.com', 'href' => 'http://example.com/'), array('name' => 'Contributor 2', 'email' => 'you@example.com', 'href' => 'http://two.example.com/')), $feed->contributors);
+    }
+
+    function test_feed_contributor_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_contributor_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->contributors(0, 'name'));
+    }
+
+    function test_feed_contributor_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_contributor_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->contributors(0, 'url'));
+    }
+
+    function test_feed_contributor_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_contributor_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->contributors(0, 'url'));
+    }
+
+    function test_feed_generator_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_generator.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->generator);
+    }
+
+    function test_feed_generator_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_generator_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->generator(0, 'name'));
+    }
+
+    function test_feed_generator_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_generator_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->generator(0, 'href'));
+    }
+
+    function test_feed_generator_version_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_generator_version.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2.65', $feed->generator(0, 'version'));
+    }
+
+    function test_feed_icon_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_icon.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/favicon.ico', $feed->icon);
+    }
+
+    function test_feed_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->id);
+    }
+
+    function test_feed_id_map_guid_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_id_map_guid.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->guid);
+    }
+
+    function test_feed_link_alternate_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_alternate_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->link);
+    }
+
+    function test_feed_link_alternate_map_link_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_alternate_map_link_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->link);
+    }
+
+    function test_feed_link_href_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_href.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->links(0, 'href'));
+    }
+
+    function test_feed_link_hreflang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_hreflang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->links(0, 'hreflang'));
+    }
+
+    function test_feed_link_length_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_length.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('42301', $feed->links(0, 'length'));
+    }
+
+    function test_feed_link_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(array('rel' => 'alternate', 'type' => 'application/xhtml+xml', 'href' => 'http://www.example.com/'), array('rel' => 'service.post', 'type' => 'application/atom+xml', 'href' => 'http://www.example.com/post')), $feed->links);
+    }
+
+    function test_feed_link_no_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_no_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_rel_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_rel.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('alternate', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_rel_other_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_rel_other.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://feedparser.org/rel/test', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_rel_related_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_rel_related.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('related', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_rel_self_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_rel_self.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('self', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_rel_via_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_rel_via.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('via', $feed->links(0, 'rel'));
+    }
+
+    function test_feed_link_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->links(0, 'title'));
+    }
+
+    function test_feed_link_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_link_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->links(0, 'type'));
+    }
+
+    function test_feed_logo_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_logo.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/logo.jpg', $feed->logo);
+    }
+
+    function test_feed_rights_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->rights);
+    }
+
+    function test_feed_rights_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->rights);
+    }
+
+    function test_feed_rights_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->rights);
+    }
+
+    function test_feed_rights_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->rights(0, 'type'));
+    }
+
+    function test_feed_rights_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->rights(0, 'type'));
+    }
+
+    function test_feed_rights_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->rights);
+    }
+
+    function test_feed_rights_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->rights);
+    }
+
+    function test_feed_rights_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->rights);
+    }
+
+    function test_feed_rights_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->rights);
+    }
+
+    function test_feed_rights_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_rights_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->rights);
+    }
+
+    function test_feed_subtitle_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->subtitle(0, 'type'));
+    }
+
+    function test_feed_subtitle_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->subtitle(0, 'type'));
+    }
+
+    function test_feed_subtitle_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->subtitle);
+    }
+
+    function test_feed_subtitle_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_subtitle_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->subtitle);
+    }
+
+    function test_feed_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_feed_title_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->title);
+    }
+
+    function test_feed_title_base64_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_base64_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>History of the &lt;blink&gt; tag</p>', $feed->title);
+    }
+
+    function test_feed_title_content_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_content_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->title(0, 'type'));
+    }
+
+    function test_feed_title_content_type_text_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_content_type_text.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/plain', $feed->title(0, 'type'));
+    }
+
+    function test_feed_title_content_value_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_content_value.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_feed_title_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example <b>Atom</b>', $feed->title);
+    }
+
+    function test_feed_title_inline_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_inline_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <b>Atom</b></div>', $feed->title);
+    }
+
+    function test_feed_title_inline_markup_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_inline_markup_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>History of the &lt;blink&gt; tag</div>', $feed->title);
+    }
+
+    function test_feed_title_text_plain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/feed_title_text_plain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example Atom', $feed->title);
+    }
+
+    function test_relative_uri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/relative_uri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <a href="http://example.com/test/test.html">test</a></div>', $feed->title);
+    }
+
+    function test_relative_uri_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/relative_uri_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <a href="http://example.com/test/test.html">test</a></div>', $feed->title);
+    }
+
+    function test_relative_uri_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/atom10/relative_uri_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>Example <a href="http://example.com/test/test.html">test</a></div>', $feed->title);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('atom10_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/feedburner.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/feedburner.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/feedburner.php	(revision 14676)
@@ -0,0 +1,23 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class feedburner_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_feedburner_browserfriendly_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/feedburner/feedburner_browserfriendly.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('This is an XML content feed. It is intended to be viewed in a newsreader or syndicated to another site.', $feed->info);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('feedburner_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/lang.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/lang.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/lang.php	(revision 14676)
@@ -0,0 +1,705 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class lang_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_channel_dc_language_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/channel_dc_language.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->language);
+    }
+
+    function test_channel_language_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/channel_language.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en-us', $feed->language);
+    }
+
+    function test_entry_content_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_content_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_content_xml_lang_blank_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_blank_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_content_xml_lang_blank_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_blank_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(1)->content->language);
+    }
+
+    function test_entry_content_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_content_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_content_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_content_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_content_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_entry_summary_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_summary_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->summary(0, 'language'));
+    }
+
+    function test_entry_summary_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_summary_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->getEntryByOffset(0)->summary(0, 'language'));
+    }
+
+    function test_entry_summary_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_summary_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->summary(0, 'language'));
+    }
+
+    function test_entry_summary_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_summary_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->summary(0, 'language'));
+    }
+
+    function test_entry_summary_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_summary_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->summary(0, 'language'));
+    }
+
+    function test_entry_summary_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_summary_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->summary(0, 'language'));
+    }
+
+    function test_entry_title_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_title_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_entry_title_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_title_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_entry_title_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_title_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_entry_title_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_title_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_entry_title_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_title_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_entry_title_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/entry_title_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_feed_copyright_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_copyright_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->copyright(0, 'language'));
+    }
+
+    function test_feed_copyright_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_copyright_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->copyright(0, 'language'));
+    }
+
+    function test_feed_copyright_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_copyright_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->copyright(0, 'language'));
+    }
+
+    function test_feed_copyright_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_copyright_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->copyright(0, 'language'));
+    }
+
+    function test_feed_copyright_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_copyright_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->copyright(0, 'language'));
+    }
+
+    function test_feed_copyright_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_copyright_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->copyright(0, 'language'));
+    }
+
+    function test_feed_info_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_info_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->info(0, 'language'));
+    }
+
+    function test_feed_info_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_info_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->info(0, 'language'));
+    }
+
+    function test_feed_info_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_info_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->info(0, 'language'));
+    }
+
+    function test_feed_info_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_info_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->info(0, 'language'));
+    }
+
+    function test_feed_info_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_info_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->info(0, 'language'));
+    }
+
+    function test_feed_info_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_info_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->info(0, 'language'));
+    }
+
+    function test_feed_language_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_language.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->language);
+    }
+
+    function test_feed_language_override_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_language_override.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->language);
+    }
+
+    function test_feed_not_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_not_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->language);
+    }
+
+    function test_feed_not_xml_lang_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_not_xml_lang_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, ! $feed.has_key(->));
+    }
+
+    function test_feed_tagline_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_tagline_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->tagline(0, 'language'));
+    }
+
+    function test_feed_tagline_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_tagline_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->tagline(0, 'language'));
+    }
+
+    function test_feed_tagline_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_tagline_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->tagline(0, 'language'));
+    }
+
+    function test_feed_tagline_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_tagline_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('fr', $feed->tagline(0, 'language'));
+    }
+
+    function test_feed_tagline_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_tagline_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('de', $feed->tagline(0, 'language'));
+    }
+
+    function test_feed_tagline_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_tagline_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->tagline(0, 'language'));
+    }
+
+    function test_feed_title_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_title_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->title(0, 'language'));
+    }
+
+    function test_feed_title_xml_lang_blank_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_title_xml_lang_blank.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(None, $feed->title(0, 'language'));
+    }
+
+    function test_feed_title_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_title_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('de', $feed->title(0, 'language'));
+    }
+
+    function test_feed_title_xml_lang_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_title_xml_lang_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('de', $feed->title(0, 'language'));
+    }
+
+    function test_feed_title_xml_lang_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_title_xml_lang_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('de', $feed->title(0, 'language'));
+    }
+
+    function test_feed_title_xml_lang_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_title_xml_lang_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->title(0, 'language'));
+    }
+
+    function test_feed_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/feed_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->language);
+    }
+
+    function test_http_content_language_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/http_content_language.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->language);
+    }
+
+    function test_http_content_language_entry_title_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/http_content_language_entry_title_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_http_content_language_entry_title_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/http_content_language_entry_title_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->title(0, 'language'));
+    }
+
+    function test_http_content_language_feed_language_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/http_content_language_feed_language.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('fr', $feed->language);
+    }
+
+    function test_http_content_language_feed_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/http_content_language_feed_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('fr', $feed->language);
+    }
+
+    function test_item_content_encoded_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_content_encoded_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_item_content_encoded_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_content_encoded_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_item_dc_language_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_dc_language.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->language);
+    }
+
+    function test_item_fullitem_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_fullitem_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_item_fullitem_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_fullitem_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_item_xhtml_body_xml_lang_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_xhtml_body_xml_lang.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+
+    function test_item_xhtml_body_xml_lang_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/lang/item_xhtml_body_xml_lang_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('en', $feed->getEntryByOffset(0)->content(0, 'language'));
+    }
+}
+
+$suite = new PHPUnit_TestSuite('lang_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/encoding.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/encoding.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/encoding.php	(revision 14676)
@@ -0,0 +1,1772 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class encoding_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_csucs4_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/csucs4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_csunicode_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/csunicode.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_encoding_attribute_crash_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/encoding_attribute_crash.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_encoding_attribute_crash_2_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/encoding_attribute_crash_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_euc-kr-attribute_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/euc-kr-attribute.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img alt="\ub144" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_euc-kr-item_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/euc-kr-item.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\ub144', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_euc-kr_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/euc-kr.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\ub144', $feed->title);
+    }
+
+    function test_http_text_xml_charset_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/http_text_xml_charset_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('This is a \xa3\u201ctest.\u201d', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_http_text_xml_charset_overrides_encoding_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/http_text_xml_charset_overrides_encoding_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('This is a \xa3\u201ctest.\u201d', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_iso-10646-ucs-2_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/iso-10646-ucs-2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_iso-10646-ucs-4_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/iso-10646-ucs-4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_u16_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/u16.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_ucs-2_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/ucs-2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_ucs-4_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/ucs-4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-16be-autodetect_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-16be-autodetect.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-16be-bom_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-16be-bom.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-16be_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-16be.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-16le-autodetect_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-16le-autodetect.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-16le-bom_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-16le-bom.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-16le_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-16le.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-32be-autodetect_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-32be-autodetect.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-32be-bom_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-32be-bom.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-32be_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-32be.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-32le-autodetect_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-32le-autodetect.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-32le-bom_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-32le-bom.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf-32le_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf-32le.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf16_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf16.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf_16_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf_16.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_utf_32_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/utf_32.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_437_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_437.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_850_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_850.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_852_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_852.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_855_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_855.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0452', $feed->title);
+    }
+
+    function test_x80_857_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_857.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_860_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_860.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_861_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_861.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_862_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_862.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u05d0', $feed->title);
+    }
+
+    function test_x80_863_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_863.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_865_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_865.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_866_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_866.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_cp037_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp037.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_cp1125_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1125.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_cp1250_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1250.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1251_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1251.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0402', $feed->title);
+    }
+
+    function test_x80_cp1252_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1252.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1253_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1253.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1254_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1254.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1255_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1255.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1256_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1256.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1257_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1257.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp1258_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp1258.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp437_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp437.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp500_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp500.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_cp737_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp737.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0391', $feed->title);
+    }
+
+    function test_x80_cp775_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp775.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0106', $feed->title);
+    }
+
+    function test_x80_cp850_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp850.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp852_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp852.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp855_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp855.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0452', $feed->title);
+    }
+
+    function test_x80_cp856_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp856.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u05d0', $feed->title);
+    }
+
+    function test_x80_cp857_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp857.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp860_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp860.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp861_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp861.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp862_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp862.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u05d0', $feed->title);
+    }
+
+    function test_x80_cp863_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp863.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp864_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp864.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xb0', $feed->title);
+    }
+
+    function test_x80_cp865_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp865.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cp866_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp866.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_cp874_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp874.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_cp875_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp875.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_cp_is_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cp_is.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_csibm037_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm037.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_csibm500_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm500.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_csibm855_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm855.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0452', $feed->title);
+    }
+
+    function test_x80_csibm857_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm857.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_csibm860_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm860.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_csibm861_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm861.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_csibm863_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm863.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_csibm864_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm864.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xb0', $feed->title);
+    }
+
+    function test_x80_csibm865_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm865.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_csibm866_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csibm866.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_cskoi8r_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cskoi8r.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u2500', $feed->title);
+    }
+
+    function test_x80_csmacintosh_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_csmacintosh.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_cspc775baltic_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cspc775baltic.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0106', $feed->title);
+    }
+
+    function test_x80_cspc850multilingual_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cspc850multilingual.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cspc862latinhebrew_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cspc862latinhebrew.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u05d0', $feed->title);
+    }
+
+    function test_x80_cspc8codepage437_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cspc8codepage437.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_cspcp852_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_cspcp852.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_dbcs_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_dbcs.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_ebcdic-cp-be_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic-cp-be.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic-cp-ca_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic-cp-ca.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic-cp-ch_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic-cp-ch.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic-cp-nl_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic-cp-nl.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic-cp-us_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic-cp-us.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic-cp-wt_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic-cp-wt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic_cp_be_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic_cp_be.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic_cp_ca_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic_cp_ca.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic_cp_ch_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic_cp_ch.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic_cp_nl_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic_cp_nl.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic_cp_us_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic_cp_us.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ebcdic_cp_wt_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ebcdic_cp_wt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ibm037_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm037.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ibm039_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm039.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ibm1140_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm1140.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ibm437_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm437.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm500_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm500.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, );
+    }
+
+    function test_x80_ibm775_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm775.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0106', $feed->title);
+    }
+
+    function test_x80_ibm850_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm850.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm852_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm852.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm855_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm855.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0452', $feed->title);
+    }
+
+    function test_x80_ibm857_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm857.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm860_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm860.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm861_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm861.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm862_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm862.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u05d0', $feed->title);
+    }
+
+    function test_x80_ibm863_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm863.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm864_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm864.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xb0', $feed->title);
+    }
+
+    function test_x80_ibm865_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm865.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc7', $feed->title);
+    }
+
+    function test_x80_ibm866_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ibm866.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_koi8-r_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_koi8-r.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u2500', $feed->title);
+    }
+
+    function test_x80_koi8-t_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_koi8-t.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u049b', $feed->title);
+    }
+
+    function test_x80_koi8-u_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_koi8-u.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u2500', $feed->title);
+    }
+
+    function test_x80_mac-cyrillic_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_mac-cyrillic.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_mac_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_mac.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_maccentraleurope_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_maccentraleurope.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_maccyrillic_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_maccyrillic.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0410', $feed->title);
+    }
+
+    function test_x80_macgreek_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_macgreek.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_maciceland_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_maciceland.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_macintosh_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_macintosh.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_maclatin2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_maclatin2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_macroman_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_macroman.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_macturkish_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_macturkish.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc4', $feed->title);
+    }
+
+    function test_x80_ms-ansi_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-ansi.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_ms-arab_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-arab.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_ms-cyrl_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-cyrl.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0402', $feed->title);
+    }
+
+    function test_x80_ms-ee_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-ee.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_ms-greek_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-greek.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_ms-hebr_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-hebr.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_ms-turk_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_ms-turk.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_tcvn-5712_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_tcvn-5712.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc0', $feed->title);
+    }
+
+    function test_x80_tcvn_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_tcvn.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc0', $feed->title);
+    }
+
+    function test_x80_tcvn5712-1_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_tcvn5712-1.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\xc0', $feed->title);
+    }
+
+    function test_x80_viscii_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_viscii.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u1ea0', $feed->title);
+    }
+
+    function test_x80_winbaltrim_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_winbaltrim.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1250_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1250.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1251_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1251.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0402', $feed->title);
+    }
+
+    function test_x80_windows-1252_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1252.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1253_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1253.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1254_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1254.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1255_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1255.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1256_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1256.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1257_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1257.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows-1258_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows-1258.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1250_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1250.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1251_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1251.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u0402', $feed->title);
+    }
+
+    function test_x80_windows_1252_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1252.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1253_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1253.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1254_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1254.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1255_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1255.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1256_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1256.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1257_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1257.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+
+    function test_x80_windows_1258_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/encoding/x80_windows_1258.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('\u20ac', $feed->title);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('encoding_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/sanitize.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/sanitize.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/sanitize.php	(revision 14676)
@@ -0,0 +1,4599 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class sanitize_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_entry_content_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe <b>description</b>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_script_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_script_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_content_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_content_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_entry_summary_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_script_base64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_script_base64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_summary_script_map_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_script_map_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_entry_summary_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_summary_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_entry_title_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_entry_title_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/entry_title_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_feed_copyright_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->copyright);
+    }
+
+    function test_feed_copyright_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->copyright);
+    }
+
+    function test_feed_copyright_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->copyright);
+    }
+
+    function test_feed_copyright_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->copyright);
+    }
+
+    function test_feed_copyright_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_copyright_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->copyright);
+    }
+
+    function test_feed_info_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->info);
+    }
+
+    function test_feed_info_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->info);
+    }
+
+    function test_feed_info_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->info);
+    }
+
+    function test_feed_info_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->info);
+    }
+
+    function test_feed_info_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_info_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->info);
+    }
+
+    function test_feed_subtitle_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->tagline);
+    }
+
+    function test_feed_subtitle_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_subtitle_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_subtitle_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->tagline);
+    }
+
+    function test_feed_subtitle_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_subtitle_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->tagline);
+    }
+
+    function test_feed_tagline_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->tagline);
+    }
+
+    function test_feed_tagline_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->tagline);
+    }
+
+    function test_feed_tagline_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->tagline);
+    }
+
+    function test_feed_tagline_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->tagline);
+    }
+
+    function test_feed_tagline_script_map_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_script_map_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->description);
+    }
+
+    function test_feed_tagline_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_tagline_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->tagline);
+    }
+
+    function test_feed_title_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->title);
+    }
+
+    function test_feed_title_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->title);
+    }
+
+    function test_feed_title_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->title);
+    }
+
+    function test_feed_title_script_inline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_script_inline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div>safe description</div>', $feed->title);
+    }
+
+    function test_feed_title_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/feed_title_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->title);
+    }
+
+    function test_item_body_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_body_script_map_content_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_script_map_content.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_body_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_body_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_map_content_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_map_content.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_content_encoded_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_content_encoded_script_map_content_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_script_map_content.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_content_encoded_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_content_encoded_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_script_map_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_script_map_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_item_description_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_description_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_crazy_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_crazy.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Crazy HTML -' + '- Can Your Regex Parse This?\n\n\n\n<!-' + '- <script> -' + '->\n\n<!-' + '- \n\t<script> \n-' + '->\n\n\n\nfunction executeMe()\n{\n\n\n\n\n/* \n<h1>Did The Javascript Execute?</h1>\n<div>\nI will execute here, too, if you mouse over me\n</div>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_script_cdata_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_script_cdata.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_fullitem_script_map_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_script_map_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_fullitem_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_fullitem_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_applet_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_applet.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_blink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_blink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_embed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_embed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_frame_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_frame.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_iframe_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_iframe.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_meta_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_meta.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_object_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_object.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onabort_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onabort.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onblur_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onblur.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onchange_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onchange.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_ondblclick_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_ondblclick.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onerror_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onerror.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onfocus_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onfocus.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onkeydown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onkeydown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onkeypress_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onkeypress.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onkeyup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onkeyup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onmousedown_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onmousedown.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onmouseout_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onmouseout.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onmouseover_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onmouseover.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onmouseup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onmouseup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onreset_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onreset.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onresize_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onresize.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onsubmit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onsubmit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_onunload_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_onunload.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<img src="http://www.ragingplatypus.com/i/cam-full.jpg" />', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_script_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_script.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_xhtml_body_script_map_content_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_script_map_content.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('safe description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_xhtml_body_style_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/sanitize/item_xhtml_body_style.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://www.ragingplatypus.com/">never trust your upstream platypus</a>', $feed->getEntryByOffset(0)->description);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('sanitize_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/itunes.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/itunes.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/itunes.php	(revision 14676)
@@ -0,0 +1,617 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class itunes_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_itunes_channel_block_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_block.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->itunes_block);
+    }
+
+    function test_itunes_channel_block_false_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_block_false.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_block);
+    }
+
+    function test_itunes_channel_block_no_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_block_no.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_block);
+    }
+
+    function test_itunes_channel_block_true_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_block_true.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_block);
+    }
+
+    function test_itunes_channel_block_uppercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_block_uppercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_block);
+    }
+
+    function test_itunes_channel_block_whitespace_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_block_whitespace.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_block);
+    }
+
+    function test_itunes_channel_category_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_category.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Technology', $feed->tags(0, 'term'));
+    }
+
+    function test_itunes_channel_category_nested_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_category_nested.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Gadgets', $feed->tags(0, 'term'));
+    }
+
+    function test_itunes_channel_category_scheme_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_category_scheme.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.itunes.com/', $feed->tags(0, 'scheme'));
+    }
+
+    function test_itunes_channel_explicit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_explicit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->itunes_explicit);
+    }
+
+    function test_itunes_channel_explicit_false_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_explicit_false.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_explicit);
+    }
+
+    function test_itunes_channel_explicit_no_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_explicit_no.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_explicit);
+    }
+
+    function test_itunes_channel_explicit_true_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_explicit_true.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_explicit);
+    }
+
+    function test_itunes_channel_explicit_uppercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_explicit_uppercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_explicit);
+    }
+
+    function test_itunes_channel_explicit_whitespace_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_explicit_whitespace.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->itunes_explicit);
+    }
+
+    function test_itunes_channel_image_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_image.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/logo.jpg', $feed->image(0, 'href'));
+    }
+
+    function test_itunes_channel_keywords_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_keywords.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Technology', $feed->tags(0, 'term'));
+    }
+
+    function test_itunes_channel_keywords_duplicate_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_keywords_duplicate.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, len(feed->tags));
+    }
+
+    function test_itunes_channel_keywords_duplicate_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_keywords_duplicate_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, len(feed->tags));
+    }
+
+    function test_itunes_channel_keywords_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_keywords_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Gadgets', $feed->tags(0, 'term'));
+    }
+
+    function test_itunes_channel_link_image_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_link_image.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/logo.jpg', $feed->image(0, 'href'));
+    }
+
+    function test_itunes_channel_owner_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_owner_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('mark@example.com', $feed->publisher(0, 'email'));
+    }
+
+    function test_itunes_channel_owner_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_owner_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Mark Pilgrim', $feed->publisher(0, 'name'));
+    }
+
+    function test_itunes_channel_subtitle_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_subtitle.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example subtitle', $feed->subtitle);
+    }
+
+    function test_itunes_channel_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_channel_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example summary', $feed->description);
+    }
+
+    function test_itunes_core_element_uppercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_core_element_uppercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->title);
+    }
+
+    function test_itunes_enclosure_url_maps_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_enclosure_url_maps_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/movie.mp4', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_itunes_enclosure_url_maps_id_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_enclosure_url_maps_id_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/id', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_itunes_item_author_map_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_author_map_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Mark Pilgrim', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_itunes_item_block_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_block.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->getEntryByOffset(0)->itunes_block);
+    }
+
+    function test_itunes_item_block_false_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_block_false.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_block);
+    }
+
+    function test_itunes_item_block_no_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_block_no.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_block);
+    }
+
+    function test_itunes_item_block_true_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_block_true.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_block);
+    }
+
+    function test_itunes_item_block_uppercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_block_uppercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_block);
+    }
+
+    function test_itunes_item_block_whitespace_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_block_whitespace.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_block);
+    }
+
+    function test_itunes_item_category_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_category.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Technology', $feed->getEntryByOffset(0)->tags(0, 'term'));
+    }
+
+    function test_itunes_item_category_nested_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_category_nested.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Gadgets', $feed->getEntryByOffset(0)->tags(0, 'term'));
+    }
+
+    function test_itunes_item_category_scheme_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_category_scheme.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.itunes.com/', $feed->getEntryByOffset(0)->tags(0, 'scheme'));
+    }
+
+    function test_itunes_item_duration_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_duration.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('3:00', $feed->getEntryByOffset(0)->itunes_duration);
+    }
+
+    function test_itunes_item_explicit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_explicit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->getEntryByOffset(0)->itunes_explicit);
+    }
+
+    function test_itunes_item_explicit_false_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_explicit_false.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_explicit);
+    }
+
+    function test_itunes_item_explicit_no_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_explicit_no.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_explicit);
+    }
+
+    function test_itunes_item_explicit_true_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_explicit_true.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_explicit);
+    }
+
+    function test_itunes_item_explicit_uppercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_explicit_uppercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_explicit);
+    }
+
+    function test_itunes_item_explicit_whitespace_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_explicit_whitespace.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(0, $feed->getEntryByOffset(0)->itunes_explicit);
+    }
+
+    function test_itunes_item_image_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_image.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/logo.jpg', $feed->getEntryByOffset(0)->image(0, 'href'));
+    }
+
+    function test_itunes_item_link_image_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_link_image.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/logo.jpg', $feed->getEntryByOffset(0)->image(0, 'href'));
+    }
+
+    function test_itunes_item_subtitle_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_subtitle.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example subtitle', $feed->getEntryByOffset(0)->subtitle);
+    }
+
+    function test_itunes_item_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_item_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example summary', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_itunes_link_enclosure_maps_id_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_link_enclosure_maps_id.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/movie.mp4', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_itunes_link_enclosure_maps_id_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_link_enclosure_maps_id_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/id', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_itunes_namespace_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_namespace.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->itunes_block);
+    }
+
+    function test_itunes_namespace_example_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_namespace_example.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->itunes_block);
+    }
+
+    function test_itunes_namespace_lowercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_namespace_lowercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->itunes_block);
+    }
+
+    function test_itunes_namespace_uppercase_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/itunes/itunes_namespace_uppercase.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(1, $feed->itunes_block);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('itunes_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/rss.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/rss.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/rss.php	(revision 14676)
@@ -0,0 +1,1574 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class rss_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_channel_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor (me@example.com)', $feed->author);
+    }
+
+    function test_channel_author_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_author_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_channel_author_map_author_detail_email_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_author_map_author_detail_email_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me+spam@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_channel_author_map_author_detail_email_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_author_map_author_detail_email_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_channel_author_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_author_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author(0, 'name'));
+    }
+
+    function test_channel_author_map_author_detail_name_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_author_map_author_detail_name_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author(0, 'name'));
+    }
+
+    function test_channel_category_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_category.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category', $feed->category);
+    }
+
+    function test_channel_category_domain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_category_domain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->categories[0][0]);
+    }
+
+    function test_channel_category_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_category_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/2', $feed->categories[1][0]);
+    }
+
+    function test_channel_category_multiple_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_category_multiple_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category 2', $feed->categories[1][1]);
+    }
+
+    function test_channel_cloud_domain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_cloud_domain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rpc.sys.com', $feed->cloud(0, 'domain'));
+    }
+
+    function test_channel_cloud_path_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_cloud_path.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('/RPC2', $feed->cloud(0, 'path'));
+    }
+
+    function test_channel_cloud_port_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_cloud_port.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('80', $feed->cloud(0, 'port'));
+    }
+
+    function test_channel_cloud_protocol_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_cloud_protocol.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('xml-rpc', $feed->cloud(0, 'protocol'));
+    }
+
+    function test_channel_cloud_registerProcedure_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_cloud_registerProcedure.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('myCloud.rssPleaseNotify', $feed->cloud(0, 'registerprocedure'));
+    }
+
+    function test_channel_copyright_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_copyright.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example copyright', $feed->copyright);
+    }
+
+    function test_channel_dc_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author);
+    }
+
+    function test_channel_dc_author_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_author_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_channel_dc_author_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_author_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author(0, 'name'));
+    }
+
+    function test_channel_dc_contributor_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_contributor.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->contributors(0, 'name'));
+    }
+
+    function test_channel_dc_creator_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_creator.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author);
+    }
+
+    function test_channel_dc_creator_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_creator_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_channel_dc_creator_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_creator_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author(0, 'name'));
+    }
+
+    function test_channel_dc_publisher_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_publisher.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->publisher);
+    }
+
+    function test_channel_dc_publisher_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_publisher_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->publisher(0, 'email'));
+    }
+
+    function test_channel_dc_publisher_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_publisher_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->publisher(0, 'name'));
+    }
+
+    function test_channel_dc_rights_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_rights.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example copyright', $feed->copyright);
+    }
+
+    function test_channel_dc_subject_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_subject.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category', $feed->category);
+    }
+
+    function test_channel_dc_subject_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_subject_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category', $feed->categories[0][1]);
+    }
+
+    function test_channel_dc_subject_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_subject_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category 2', $feed->categories[1][1]);
+    }
+
+    function test_channel_dc_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_dc_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->title);
+    }
+
+    function test_channel_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_channel_description_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_description_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example description</p>', $feed->description);
+    }
+
+    function test_channel_description_map_tagline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_description_map_tagline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->tagline);
+    }
+
+    function test_channel_description_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_description_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example description</p>', $feed->description);
+    }
+
+    function test_channel_description_shorttag_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_description_shorttag.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('', $feed->description);
+    }
+
+    function test_channel_description_shorttag_2 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_description_shorttag.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->link);
+    }
+
+    function test_channel_docs_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_docs.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->docs);
+    }
+
+    function test_channel_generator_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_generator.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example generator', $feed->generator);
+    }
+
+    function test_channel_image_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Available in Netscape RSS 0.91', $feed->image(0, 'description'));
+    }
+
+    function test_channel_image_height_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_height.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(15, $feed->image(0, 'height'));
+    }
+
+    function test_channel_image_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.org/link', $feed->image(0, 'link'));
+    }
+
+    function test_channel_image_link_conflict_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_link_conflict.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://channel.example.com/', $feed->link);
+    }
+
+    function test_channel_image_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Sample image', $feed->image(0, 'title'));
+    }
+
+    function test_channel_image_title_conflict_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_title_conflict.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Real title', $feed->title);
+    }
+
+    function test_channel_image_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.org/url', $feed->image(0, 'url'));
+    }
+
+    function test_channel_image_width_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_image_width.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(80, $feed->image(0, 'width'));
+    }
+
+    function test_channel_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->link);
+    }
+
+    function test_channel_managingEditor_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_managingEditor.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author);
+    }
+
+    function test_channel_managingEditor_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_managingEditor_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->author(0, 'email'));
+    }
+
+    function test_channel_managingEditor_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_managingEditor_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->author(0, 'name'));
+    }
+
+    function test_channel_textInput_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('textInput description', $feed->textinput(0, 'description'));
+    }
+
+    function test_channel_textInput_description_conflict_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_description_conflict.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Real description', $feed->description);
+    }
+
+    function test_channel_textInput_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://textinput.example.com/', $feed->textinput(0, 'link'));
+    }
+
+    function test_channel_textInput_link_conflict_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_link_conflict.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://channel.example.com/', $feed->link);
+    }
+
+    function test_channel_textInput_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('textinput name', $feed->textinput(0, 'name'));
+    }
+
+    function test_channel_textInput_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('textInput title', $feed->textinput(0, 'title'));
+    }
+
+    function test_channel_textInput_title_conflict_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_textInput_title_conflict.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Real title', $feed->title);
+    }
+
+    function test_channel_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example feed', $feed->title);
+    }
+
+    function test_channel_title_apos_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_title_apos.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(u"Mark's title", $feed->title);
+    }
+
+    function test_channel_title_gt_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_title_gt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2 > 1', $feed->title);
+    }
+
+    function test_channel_title_lt_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_title_lt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('1 < 2', $feed->title);
+    }
+
+    function test_channel_ttl_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_ttl.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('60', $feed->ttl);
+    }
+
+    function test_channel_webMaster_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_webMaster.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->publisher);
+    }
+
+    function test_channel_webMaster_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_webMaster_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->publisher(0, 'email'));
+    }
+
+    function test_channel_webMaster_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/channel_webMaster_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->publisher(0, 'name'));
+    }
+
+    function test_item_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_item_author_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_author_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->author(0, 'email'));
+    }
+
+    function test_item_author_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_author_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->author(0, 'name'));
+    }
+
+    function test_item_category_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_category.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category', $feed->getEntryByOffset(0)->category);
+    }
+
+    function test_item_category_domain_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_category_domain.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/', $feed->getEntryByOffset(0)->categories[0][0]);
+    }
+
+    function test_item_category_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_category_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.com/2', $feed->getEntryByOffset(0)->categories[1][0]);
+    }
+
+    function test_item_category_multiple_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_category_multiple_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category 2', $feed->getEntryByOffset(0)->categories[1][1]);
+    }
+
+    function test_item_comments_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_comments.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->comments);
+    }
+
+    function test_item_content_encoded_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_content_encoded.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example content</p>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_content_encoded_mode_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_content_encoded_mode.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_item_content_encoded_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_content_encoded_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_item_dc_author_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_author.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_item_dc_author_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_author_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->author(0, 'email'));
+    }
+
+    function test_item_dc_author_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_author_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->author(0, 'name'));
+    }
+
+    function test_item_dc_contributor_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_contributor.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example contributor', $feed->getEntryByOffset(0)->contributors(0, 'name'));
+    }
+
+    function test_item_dc_creator_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_creator.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->author);
+    }
+
+    function test_item_dc_creator_map_author_detail_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_creator_map_author_detail_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->author(0, 'email'));
+    }
+
+    function test_item_dc_creator_map_author_detail_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_creator_map_author_detail_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->author(0, 'name'));
+    }
+
+    function test_item_dc_publisher_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_publisher.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->publisher);
+    }
+
+    function test_item_dc_publisher_email_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_publisher_email.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('me@example.com', $feed->getEntryByOffset(0)->publisher(0, 'email'));
+    }
+
+    function test_item_dc_publisher_name_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_publisher_name.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example editor', $feed->getEntryByOffset(0)->publisher(0, 'name'));
+    }
+
+    function test_item_dc_rights_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_rights.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example copyright', $feed->getEntryByOffset(0)->copyright);
+    }
+
+    function test_item_dc_subject_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_subject.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category', $feed->getEntryByOffset(0)->category);
+    }
+
+    function test_item_dc_subject_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_subject_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category', $feed->getEntryByOffset(0)->categories[0][1]);
+    }
+
+    function test_item_dc_subject_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_subject_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example category 2', $feed->getEntryByOffset(0)->categories[1][1]);
+    }
+
+    function test_item_dc_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_dc_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_item_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_and_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_and_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_and_summary_2 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_and_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example summary', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_description_br_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_br.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('article title<br /><br /> article byline<br /><br />text of article', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_escaped_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_escaped_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example description</p>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_map_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_map_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_item_description_naked_markup_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_naked_markup.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example description</p>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_description_not_a_doctype_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_description_not_a_doctype.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals("""&lt;!' <a href="foo">""", $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_enclosure_length_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_enclosure_length.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('100000', $feed->getEntryByOffset(0)->enclosures(0, 'length'));
+    }
+
+    function test_item_enclosure_multiple_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_enclosure_multiple.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array('href' => 'http://example.com/2', 'length' => '200000', 'type' => 'image/gif'), $feed->getEntryByOffset(0)->enclosures[1]);
+    }
+
+    function test_item_enclosure_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_enclosure_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('image/jpeg', $feed->getEntryByOffset(0)->enclosures(0, 'type'));
+    }
+
+    function test_item_enclosure_url_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_enclosure_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->enclosures(0, 'url'));
+    }
+
+    function test_item_fullitem_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_fullitem.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example content</p>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_fullitem_mode_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_fullitem_mode.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_item_fullitem_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_fullitem_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('text/html', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_item_guid_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://guid.example.com/', $feed->getEntryByOffset(0)->guid);
+    }
+
+    function test_item_guid_conflict_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_conflict_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://link.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_guid_guidislink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_guidislink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, $feed->getEntryByOffset(0)->guidislink);
+    }
+
+    function test_item_guid_isPermaLink_conflict_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_isPermaLink_conflict_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://link.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_guid_isPermaLink_conflict_link_not_guidislink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_isPermaLink_conflict_link_not_guidislink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, ! $feed->getEntryByOffset(0)->guidislink);
+    }
+
+    function test_item_guid_isPermaLink_guidislink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_isPermaLink_guidislink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, $feed->getEntryByOffset(0)->guidislink);
+    }
+
+    function test_item_guid_isPermaLink_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_isPermaLink_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://guid.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_guid_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://guid.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_guid_not_permalink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_not_permalink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, ! $feed->getEntryByOffset(0).has_key(->));
+    }
+
+    function test_item_guid_not_permalink_conflict_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_not_permalink_conflict_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://link.example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_guid_not_permalink_not_guidislink_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_not_permalink_not_guidislink.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, ! $feed->getEntryByOffset(0)->guidislink);
+    }
+
+    function test_item_guid_not_permalink_not_guidislink_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_guid_not_permalink_not_guidislink_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, ! $feed->getEntryByOffset(0)->guidislink);
+    }
+
+    function test_item_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_source_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_source.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_item_source_url_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_source_url.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_item_summary_and_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_summary_and_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example summary', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_item_summary_and_description_2 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_summary_and_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Item 1 title', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_item_xhtml_body_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_xhtml_body.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<p>Example content</p>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_item_xhtml_body_mode_0 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_xhtml_body_mode.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(, 1);
+    }
+
+    function test_item_xhtml_body_type_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/item_xhtml_body_type.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('application/xhtml+xml', $feed->getEntryByOffset(0)->content(0, 'type'));
+    }
+
+    function test_rss_namespace_1_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_namespace_1.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_rss_namespace_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_namespace_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_rss_namespace_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_namespace_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_rss_namespace_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_namespace_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_rss_version_090_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_090.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss090', $feed->version());
+    }
+
+    function test_rss_version_091_netscape_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_091_netscape.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss091n', $feed->version());
+    }
+
+    function test_rss_version_091_userland_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_091_userland.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss091', $feed->version());
+    }
+
+    function test_rss_version_092_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_092.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss092', $feed->version());
+    }
+
+    function test_rss_version_093_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_093.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss093', $feed->version());
+    }
+
+    function test_rss_version_094_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_094.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss094', $feed->version());
+    }
+
+    function test_rss_version_20_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_20.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss20', $feed->version());
+    }
+
+    function test_rss_version_201_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_201.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss20', $feed->version());
+    }
+
+    function test_rss_version_21_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_21.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss20', $feed->version());
+    }
+
+    function test_rss_version_missing_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rss/rss_version_missing.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss', $feed->version());
+    }
+}
+
+$suite = new PHPUnit_TestSuite('rss_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/base.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/base.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/base.php	(revision 14676)
@@ -0,0 +1,1365 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class base_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_cdf_item_abstract_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/cdf_item_abstract_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://base.example.org/', $feed->getEntryByOffset(0)->summary(0, 'base'));
+    }
+
+    function test_entry_content_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_content_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->content(0, 'base'));
+    }
+
+    function test_entry_content_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_content_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->content(0, 'base'));
+    }
+
+    function test_entry_content_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_content_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->content(0, 'base'));
+    }
+
+    function test_entry_content_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_content_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->content(0, 'base'));
+    }
+
+    function test_entry_content_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_content_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->getEntryByOffset(0)->content(0, 'base'));
+    }
+
+    function test_entry_summary_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_summary_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->summary(0, 'base'));
+    }
+
+    function test_entry_summary_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_summary_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->summary(0, 'base'));
+    }
+
+    function test_entry_summary_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_summary_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->summary(0, 'base'));
+    }
+
+    function test_entry_summary_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_summary_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/summary/', $feed->getEntryByOffset(0)->summary(0, 'base'));
+    }
+
+    function test_entry_summary_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_summary_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->getEntryByOffset(0)->summary(0, 'base'));
+    }
+
+    function test_entry_title_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_title_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_entry_title_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_title_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_entry_title_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_title_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_entry_title_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_title_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_entry_title_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/entry_title_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_feed_copyright_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_copyright_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->copyright(0, 'base'));
+    }
+
+    function test_feed_copyright_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_copyright_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->copyright(0, 'base'));
+    }
+
+    function test_feed_copyright_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_copyright_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->copyright(0, 'base'));
+    }
+
+    function test_feed_copyright_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_copyright_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->copyright(0, 'base'));
+    }
+
+    function test_feed_copyright_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_copyright_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->copyright(0, 'base'));
+    }
+
+    function test_feed_info_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_info_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->info(0, 'base'));
+    }
+
+    function test_feed_info_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_info_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->info(0, 'base'));
+    }
+
+    function test_feed_info_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_info_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->info(0, 'base'));
+    }
+
+    function test_feed_info_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_info_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/info/', $feed->info(0, 'base'));
+    }
+
+    function test_feed_info_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_info_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->info(0, 'base'));
+    }
+
+    function test_feed_tagline_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_tagline_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->tagline(0, 'base'));
+    }
+
+    function test_feed_tagline_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_tagline_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->tagline(0, 'base'));
+    }
+
+    function test_feed_tagline_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_tagline_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->tagline(0, 'base'));
+    }
+
+    function test_feed_tagline_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_tagline_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->tagline(0, 'base'));
+    }
+
+    function test_feed_tagline_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_tagline_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->tagline(0, 'base'));
+    }
+
+    function test_feed_title_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_title_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->title(0, 'base'));
+    }
+
+    function test_feed_title_xml_base_inherit_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_title_xml_base_inherit.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->title(0, 'base'));
+    }
+
+    function test_feed_title_xml_base_inherit_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_title_xml_base_inherit_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->title(0, 'base'));
+    }
+
+    function test_feed_title_xml_base_inherit_3_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_title_xml_base_inherit_3.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->title(0, 'base'));
+    }
+
+    function test_feed_title_xml_base_inherit_4_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/feed_title_xml_base_inherit_4.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/parent/', $feed->title(0, 'base'));
+    }
+
+    function test_http_channel_docs_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_channel_docs_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/uri', $feed->docs);
+    }
+
+    function test_http_channel_docs_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_channel_docs_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/uri', $feed->docs);
+    }
+
+    function test_http_channel_link_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_channel_link_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/uri', $feed->link);
+    }
+
+    function test_http_channel_link_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_channel_link_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/uri', $feed->link);
+    }
+
+    function test_http_entry_author_url_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_author_url_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_http_entry_author_url_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_author_url_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->getEntryByOffset(0)->author(0, 'url'));
+    }
+
+    function test_http_entry_content_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_content_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_entry_content_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_content_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_entry_content_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_content_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_entry_content_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_content_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_entry_content_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_content_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_entry_content_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_content_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_entry_contributor_url_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_contributor_url_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_http_entry_contributor_url_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_contributor_url_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->getEntryByOffset(0)->contributors(0, 'url'));
+    }
+
+    function test_http_entry_id_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_id_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_http_entry_id_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_id_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_http_entry_link_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_link_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->getEntryByOffset(0)->links(0, 'href'));
+    }
+
+    function test_http_entry_link_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_link_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->getEntryByOffset(0)->links(0, 'href'));
+    }
+
+    function test_http_entry_summary_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_summary_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_http_entry_summary_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_summary_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_http_entry_summary_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_summary_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_http_entry_summary_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_summary_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_http_entry_summary_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_summary_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_http_entry_summary_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_summary_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_http_entry_title_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_title_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_http_entry_title_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_title_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_http_entry_title_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_title_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_http_entry_title_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_title_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_http_entry_title_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_title_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_http_entry_title_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_entry_title_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_http_feed_author_url_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_author_url_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->author(0, 'url'));
+    }
+
+    function test_http_feed_author_url_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_author_url_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->author(0, 'url'));
+    }
+
+    function test_http_feed_contributor_url_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_contributor_url_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->contributors(0, 'url'));
+    }
+
+    function test_http_feed_contributor_url_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_contributor_url_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->contributors(0, 'url'));
+    }
+
+    function test_http_feed_copyright_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_copyright_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->copyright);
+    }
+
+    function test_http_feed_copyright_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_copyright_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->copyright);
+    }
+
+    function test_http_feed_copyright_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_copyright_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->copyright);
+    }
+
+    function test_http_feed_copyright_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_copyright_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->copyright);
+    }
+
+    function test_http_feed_copyright_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_copyright_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->copyright);
+    }
+
+    function test_http_feed_copyright_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_copyright_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->copyright);
+    }
+
+    function test_http_feed_generator_url_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_generator_url_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->generator(0, 'url'));
+    }
+
+    function test_http_feed_generator_url_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_generator_url_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->generator(0, 'url'));
+    }
+
+    function test_http_feed_id_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_id_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->id);
+    }
+
+    function test_http_feed_id_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_id_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->id);
+    }
+
+    function test_http_feed_info_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_info_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->info);
+    }
+
+    function test_http_feed_info_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_info_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->info);
+    }
+
+    function test_http_feed_info_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_info_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->info);
+    }
+
+    function test_http_feed_info_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_info_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->info);
+    }
+
+    function test_http_feed_info_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_info_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->info);
+    }
+
+    function test_http_feed_info_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_info_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->info);
+    }
+
+    function test_http_feed_link_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_link_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/link', $feed->links(0, 'href'));
+    }
+
+    function test_http_feed_link_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_link_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/link', $feed->links(0, 'href'));
+    }
+
+    function test_http_feed_tagline_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_tagline_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->tagline);
+    }
+
+    function test_http_feed_tagline_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_tagline_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->tagline);
+    }
+
+    function test_http_feed_tagline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_tagline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->tagline);
+    }
+
+    function test_http_feed_tagline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_tagline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->tagline);
+    }
+
+    function test_http_feed_tagline_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_tagline_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->tagline);
+    }
+
+    function test_http_feed_tagline_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_tagline_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->tagline);
+    }
+
+    function test_http_feed_title_base64_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_title_base64_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->title);
+    }
+
+    function test_http_feed_title_base64_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_title_base64_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->title);
+    }
+
+    function test_http_feed_title_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_title_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->title);
+    }
+
+    function test_http_feed_title_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_title_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->title);
+    }
+
+    function test_http_feed_title_inline_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_title_inline_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://example.com/relative/uri">click here</a></div>', $feed->title);
+    }
+
+    function test_http_feed_title_inline_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_feed_title_inline_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><a href="http://127.0.0.1:8097/relative/uri">click here</a></div>', $feed->title);
+    }
+
+    function test_http_item_body_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_body_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://example.com/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_body_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_body_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://127.0.0.1:8097/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_comments_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_comments_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/uri', $feed->getEntryByOffset(0)->comments);
+    }
+
+    function test_http_item_comments_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_comments_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/uri', $feed->getEntryByOffset(0)->comments);
+    }
+
+    function test_http_item_content_encoded_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_content_encoded_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://example.com/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_content_encoded_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_content_encoded_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://127.0.0.1:8097/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_description_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_description_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://example.com/relative/uri">click here</a>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_http_item_description_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_description_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://127.0.0.1:8097/relative/uri">click here</a>', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_http_item_fullitem_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_fullitem_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://example.com/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_fullitem_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_fullitem_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://127.0.0.1:8097/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_link_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_link_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/uri', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_http_item_link_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_link_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/uri', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_http_item_wfw_comment_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_wfw_comment_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/uri', $feed->getEntryByOffset(0)->wfw_comment);
+    }
+
+    function test_http_item_wfw_comment_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_wfw_comment_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/uri', $feed->getEntryByOffset(0)->wfw_comment);
+    }
+
+    function test_http_item_wfw_commentRSS_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_wfw_commentRSS_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/relative/uri', $feed->getEntryByOffset(0)->wfw_commentrss);
+    }
+
+    function test_http_item_wfw_commentRSS_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_wfw_commentRSS_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://127.0.0.1:8097/relative/uri', $feed->getEntryByOffset(0)->wfw_commentrss);
+    }
+
+    function test_http_item_xhtml_body_base_content_location_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_xhtml_body_base_content_location.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://example.com/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_item_xhtml_body_base_docuri_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_item_xhtml_body_base_docuri.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<a href="http://127.0.0.1:8097/relative/uri">click here</a>', $feed->getEntryByOffset(0)->content(0, 'value'));
+    }
+
+    function test_http_relative_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_relative_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/feed/entry/title/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_http_relative_xml_base_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/http_relative_xml_base_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/entry/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_malformed_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/malformed_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_relative_xml_base_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/relative_xml_base.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+
+    function test_relative_xml_base_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/base/relative_xml_base_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/test/', $feed->getEntryByOffset(0)->title(0, 'base'));
+    }
+}
+
+$suite = new PHPUnit_TestSuite('base_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/rdf.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/rdf.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/rdf.php	(revision 14676)
@@ -0,0 +1,133 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class rdf_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_rdf_channel_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_channel_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_rdf_channel_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_channel_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/', $feed->link);
+    }
+
+    function test_rdf_channel_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_channel_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example feed', $feed->title);
+    }
+
+    function test_rdf_item_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_item_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_rdf_item_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_item_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.com/1', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_rdf_item_rdf_about_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_item_rdf_about.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://example.org/1', $feed->getEntryByOffset(0)->id);
+    }
+
+    function test_rdf_item_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rdf_item_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss090_channel_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rss090_channel_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example title', $feed->title);
+    }
+
+    function test_rss090_item_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rss090_item_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Item title', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss_version_10_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rss_version_10.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss10', $feed->version());
+    }
+
+    function test_rss_version_10_not_default_ns_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/rdf/rss_version_10_not_default_ns.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('rss10', $feed->version());
+    }
+}
+
+$suite = new PHPUnit_TestSuite('rdf_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/cdf.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/cdf.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/cdf.php	(revision 14676)
@@ -0,0 +1,122 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class cdf_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_channel_abstract_map_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/channel_abstract_map_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->description);
+    }
+
+    function test_channel_abstract_map_tagline_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/channel_abstract_map_tagline.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->tagline);
+    }
+
+    function test_channel_href_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/channel_href_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.org/', $feed->link);
+    }
+
+    function test_channel_href_map_links_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/channel_href_map_links.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.org/', $feed->links(0, 'href'));
+    }
+
+    function test_channel_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/channel_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example feed', $feed->title);
+    }
+
+    function test_item_abstract_map_description_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/item_abstract_map_description.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_item_abstract_map_summary_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/item_abstract_map_summary.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example description', $feed->getEntryByOffset(0)->summary);
+    }
+
+    function test_item_href_map_link_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/item_href_map_link.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.org/', $feed->getEntryByOffset(0)->link);
+    }
+
+    function test_item_href_map_links_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/item_href_map_links.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('http://www.example.org/', $feed->getEntryByOffset(0)->links(0, 'href'));
+    }
+
+    function test_item_title_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/cdf/item_title.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Example item', $feed->getEntryByOffset(0)->title);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('cdf_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/namespace.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/namespace.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/namespace.php	(revision 14676)
@@ -0,0 +1,100 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class namespace_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_rss1_0withModules_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss1.0withModules.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Test Item - RSS 1.0', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss1_0withModulesNoDefNS_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss1.0withModulesNoDefNS.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Test Item - RSS 1.0 no Default NS', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss1_0withModulesNoDefNSLocalNameClash_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss1.0withModulesNoDefNSLocalNameClash.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('correct description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_rss2_0noNSwithModules_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss2.0noNSwithModules.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Test Item - RSS 2.0 no NS', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss2_0noNSwithModulesLocalNameClash_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss2.0noNSwithModulesLocalNameClash.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('correct description', $feed->getEntryByOffset(0)->description);
+    }
+
+    function test_rss2_0NSwithModules_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss2.0NSwithModules.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Test Item - RSS2.0 w/ NS', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss2_0NSwithModulesNoDefNS_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss2.0NSwithModulesNoDefNS.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Test Item - - RSS2.0 w/ NS no default NS', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_rss2_0NSwithModulesNoDefNSLocalNameClash_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/namespace/rss2.0NSwithModulesNoDefNSLocalNameClash.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('correct description', $feed->getEntryByOffset(0)->description);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('namespace_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/amp.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/amp.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/amp.php	(revision 14676)
@@ -0,0 +1,716 @@
+<?php
+
+require_once '../XML_Feed_Parser_TestCase.php';
+
+class amp_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_amp01_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp01.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#38;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp02_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp02.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#x26;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp03_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp03.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp04_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp04.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&amp;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp05_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp05.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#38;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp06_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp06.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#x26;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp07_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp07.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp08_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp08.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&amp;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp09_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp09.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#38;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp10_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp10.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#x26;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp11_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp11.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp12_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp12.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&amp;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp13_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp13.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp14_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp14.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp15_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp15.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp16_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp16.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp17_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp17.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp18_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp18.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp19_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp19.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp20_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp20.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp21_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp21.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp22_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp22.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp23_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp23.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp24_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp24.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp25_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp25.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp26_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp26.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp27_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp27.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp28_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp28.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp29_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp29.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp30_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp30.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp31_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp31.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp32_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp32.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp33_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp33.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp34_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp34.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp35_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp35.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp36_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp36.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp37_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp37.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp38_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp38.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp39_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp39.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp40_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp40.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp41_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp41.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp42_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp42.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp43_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp43.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp44_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp44.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp45_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp45.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp46_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp46.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp47_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp47.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp48_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp48.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp49_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp49.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#38;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp50_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp50.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&#x26;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp51_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp51.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp52_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp52.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('&amp;', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp53_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp53.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#38;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp54_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp54.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&#x26;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp55_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp55.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<b>&amp;</b>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp56_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp56.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#38;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp57_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp57.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&#x26;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp58_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp58.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<strong>&amp;</strong>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp59_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp59.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><b>&amp;</b></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp60_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp60.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><b>&amp;</b></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp61_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp61.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><b>&amp;</b></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp62_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp62.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><strong>&amp;</strong></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp63_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp63.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><strong>&amp;</strong></div>', $feed->getEntryByOffset(0)->title);
+    }
+
+    function test_amp64_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/amp/amp64.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('<div><strong>&amp;</strong></div>', $feed->getEntryByOffset(0)->title);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('amp_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/date.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/date.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/date.php	(revision 14676)
@@ -0,0 +1,1211 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class date_TestCase extends XML_Feed_Parser_Converted_TestCase {
+
+    function test_cdf_channel_lastmod_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/cdf_channel_lastmod_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2004-04-06T23:05:43-05:00', $feed->date);
+    }
+
+    function test_cdf_channel_lastmod_map_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/cdf_channel_lastmod_map_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2004-04-06T23:05:43-05:00', $feed->modified);
+    }
+
+    function test_cdf_channel_lastmod_map_modified_parsed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/cdf_channel_lastmod_map_modified_parsed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 4, 7, 4, 5, 43, 2, 98, 0), $feed->modified_parsed);
+    }
+
+    function test_cdf_item_lastmod_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/cdf_item_lastmod_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2004-04-06T23:05:43-05:00', $feed->getEntryByOffset(0)->date);
+    }
+
+    function test_cdf_item_lastmod_map_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/cdf_item_lastmod_map_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2004-04-06T23:05:43-05:00', $feed->getEntryByOffset(0)->modified);
+    }
+
+    function test_cdf_item_lastmod_map_modified_parsed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/cdf_item_lastmod_map_modified_parsed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 4, 7, 4, 5, 43, 2, 98, 0), $feed->getEntryByOffset(0)->modified_parsed);
+    }
+
+    function test_channel_dc_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dc_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->date);
+    }
+
+    function test_channel_dc_date_map_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dc_date_map_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->modified);
+    }
+
+    function test_channel_dc_date_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dc_date_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_dc_date_w3dtf_utc_map_modified_parsed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dc_date_w3dtf_utc_map_modified_parsed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_channel_dcterms_created_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_created.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->created);
+    }
+
+    function test_channel_dcterms_created_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_created_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->created_parsed);
+    }
+
+    function test_channel_dcterms_issued_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_issued.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->issued);
+    }
+
+    function test_channel_dcterms_issued_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_issued_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->issued_parsed);
+    }
+
+    function test_channel_dcterms_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->modified);
+    }
+
+    function test_channel_dcterms_modified_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_modified_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->date);
+    }
+
+    function test_channel_dcterms_modified_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_modified_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_channel_dcterms_modified_w3dtf_utc_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_dcterms_modified_w3dtf_utc_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->date);
+    }
+
+    function test_channel_pubDate_asctime_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_asctime.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 5, 0, 29, 6, 0, 5, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_disney_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_disney.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 21, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_disney_at_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_disney_at.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 20, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_disney_ct_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_disney_ct.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 22, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_disney_mt_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_disney_mt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 23, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_disney_pt_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_disney_pt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 27, 0, 31, 0, 1, 27, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_greek_1_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_greek_1.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 7, 11, 17, 0, 0, 6, 193, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_hungarian_1_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_hungarian_1.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 7, 13, 14, 15, 0, 1, 195, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_iso8601_ym_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_iso8601_ym.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_iso8601_ym_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_iso8601_ym_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_iso8601_ymd_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_iso8601_ymd.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_iso8601_ymd_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_iso8601_ymd_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_iso8601_yo_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_iso8601_yo_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_korean_nate_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_korean_nate.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 5, 25, 14, 23, 17, 1, 146, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_map_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_map_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->modified_parsed);
+    }
+
+    function test_channel_pubDate_mssql_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_mssql.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 7, 8, 14, 56, 58, 3, 190, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_mssql_nofraction_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_mssql_nofraction.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 7, 8, 14, 56, 58, 3, 190, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_nosecond_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_nosecond.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 0, 0, 0, 3, 1, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_notime_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_notime.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 0, 0, 0, 3, 1, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_rfc2822_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_rfc2822.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_rfc2822_rollover_june_31_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_rfc2822_rollover_june_31.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 7, 1, 19, 48, 21, 3, 183, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_rfc822_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_rfc822.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_rollover_25h_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_rollover_25h.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 1, 14, 55, 3, 1, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_rollover_61m_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_rollover_61m.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 11, 1, 55, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_rollover_61s_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_rollover_61s.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 15, 1, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_rollover_leapyear_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_rollover_leapyear.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 2, 29, 2, 14, 55, 6, 60, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_rollover_leapyear400_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_rollover_leapyear400.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2000, 2, 29, 2, 14, 55, 1, 60, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_rollover_nonleapyear_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_rollover_nonleapyear.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 3, 1, 2, 14, 55, 5, 60, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_sf_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_sf.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 18, 14, 55, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_tokyo_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_tokyo.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_y_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_y.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 1, 1, 0, 0, 0, 2, 1, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_ym_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_ym.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_ymd_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_ymd.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_channel_pubDate_w3dtf_ymd_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/channel_pubDate_w3dtf_ymd_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->date_parsed);
+    }
+
+    function test_entry_created_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_created.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->getEntryByOffset(0)->created);
+    }
+
+    function test_entry_created_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_created_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->created_parsed);
+    }
+
+    function test_entry_issued_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_issued.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->getEntryByOffset(0)->issued);
+    }
+
+    function test_entry_issued_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_issued_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->issued_parsed);
+    }
+
+    function test_entry_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->getEntryByOffset(0)->modified);
+    }
+
+    function test_entry_modified_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_modified_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->getEntryByOffset(0)->date_parsed);
+    }
+
+    function test_entry_modified_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_modified_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->modified_parsed);
+    }
+
+    function test_entry_published_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_published_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->published_parsed);
+    }
+
+    function test_entry_source_updated_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_source_updated_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->source(0, 'updated_parsed'));
+    }
+
+    function test_entry_updated_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/entry_updated_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->updated_parsed);
+    }
+
+    function test_feed_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->modified);
+    }
+
+    function test_feed_modified_asctime_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_asctime.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 5, 0, 29, 6, 0, 5, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_disney_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_disney.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 21, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_feed_modified_disney_at_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_disney_at.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 20, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_feed_modified_disney_ct_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_disney_ct.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 22, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_feed_modified_disney_mt_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_disney_mt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 26, 23, 31, 0, 0, 26, 0), $feed->date_parsed);
+    }
+
+    function test_feed_modified_disney_pt_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_disney_pt.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 27, 0, 31, 0, 1, 27, 0), $feed->date_parsed);
+    }
+
+    function test_feed_modified_iso8601_ym_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_iso8601_ym.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_iso8601_ym_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_iso8601_ym_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_iso8601_ymd_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_iso8601_ymd.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_iso8601_ymd_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_iso8601_ymd_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_iso8601_yo_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_iso8601_yo_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->date_parsed);
+    }
+
+    function test_feed_modified_rfc2822_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_rfc2822.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_rfc2822_rollover_june_31_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_rfc2822_rollover_june_31.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 7, 1, 19, 48, 21, 3, 183, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_rfc822_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_rfc822.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_rollover_leapyear_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_rollover_leapyear.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 2, 29, 2, 14, 55, 6, 60, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_rollover_leapyear400_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_rollover_leapyear400.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2000, 2, 29, 2, 14, 55, 1, 60, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_rollover_nonleapyear_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_rollover_nonleapyear.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 3, 1, 2, 14, 55, 5, 60, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_sf_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_sf.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 18, 14, 55, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_tokyo_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_tokyo.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_y_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_y.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 1, 1, 0, 0, 0, 2, 1, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_ym_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_ym.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 1, 0, 0, 0, 0, 335, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_ymd_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_ymd.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_modified_w3dtf_ymd_2_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_modified_w3dtf_ymd_2.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 0, 0, 0, 2, 365, 0), $feed->modified_parsed);
+    }
+
+    function test_feed_updated_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/feed_updated_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->updated_parsed);
+    }
+
+    function test_item_dc_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dc_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->getEntryByOffset(0)->date);
+    }
+
+    function test_item_dc_date_map_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dc_date_map_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->getEntryByOffset(0)->modified);
+    }
+
+    function test_item_dc_date_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dc_date_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->date_parsed);
+    }
+
+    function test_item_dc_date_w3dtf_utc_map_modified_parsed_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dc_date_w3dtf_utc_map_modified_parsed.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->modified_parsed);
+    }
+
+    function test_item_dcterms_created_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_created.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->getEntryByOffset(0)->created);
+    }
+
+    function test_item_dcterms_created_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_created_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->created_parsed);
+    }
+
+    function test_item_dcterms_issued_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_issued.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->getEntryByOffset(0)->issued);
+    }
+
+    function test_item_dcterms_issued_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_issued_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->issued_parsed);
+    }
+
+    function test_item_dcterms_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->getEntryByOffset(0)->modified);
+    }
+
+    function test_item_dcterms_modified_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_modified_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('2003-12-31T10:14:55Z', $feed->getEntryByOffset(0)->date);
+    }
+
+    function test_item_dcterms_modified_w3dtf_utc_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_modified_w3dtf_utc.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->modified_parsed);
+    }
+
+    function test_item_dcterms_modified_w3dtf_utc_map_date_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_dcterms_modified_w3dtf_utc_map_date.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2003, 12, 31, 10, 14, 55, 2, 365, 0), $feed->getEntryByOffset(0)->date_parsed);
+    }
+
+    function test_item_expirationDate_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_expirationDate.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->getEntryByOffset(0)->expired);
+    }
+
+    function test_item_expirationDate_rfc2822_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_expirationDate_rfc2822.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->getEntryByOffset(0)->expired_parsed);
+    }
+
+    function test_item_pubDate_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_pubDate.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals('Thu, 01 Jan 2004 19:48:21 GMT', $feed->getEntryByOffset(0)->date);
+    }
+
+    function test_item_pubDate_euc-kr_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_pubDate_euc-kr.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 5, 27, 16, 31, 15, 3, 148, 0), $feed->getEntryByOffset(0)->modified_parsed);
+    }
+
+    function test_item_pubDate_map_modified_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_pubDate_map_modified.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->getEntryByOffset(0)->modified_parsed);
+    }
+
+    function test_item_pubDate_rfc2822_1 () { 
+        $content = file_get_contents($this->fp_test_dir . DIRECTORY_SEPARATOR . 'wellformed/date/item_pubDate_rfc2822.xml');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(array(2004, 1, 1, 19, 48, 21, 3, 1, 0), $feed->getEntryByOffset(0)->date_parsed);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('date_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/http.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/http.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convertedtests/http.php	(revision 14676)
@@ -0,0 +1,12 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class http_TestCase extends XML_Feed_Parser_Converted_TestCase {
+}
+
+$suite = new PHPUnit_TestSuite('http_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/japanese.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/japanese.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/japanese.php	(revision 14676)
@@ -0,0 +1,44 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_Japanese_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . "sixapart-jp.xml");
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function test_itemTitleJapanese()
+    {
+        $value = "ファイブ・ディーが、Movable Typeでブログプロモーションをスタート";
+        $this->assertEquals($value, $this->entry->title);
+    }
+    
+    function test_itemDescriptionJapanese()
+    {
+        $value = "<p><img alt=\"MIYAZAWAblog_banner.jpg\" src=\"http://www.sixapart.jp/MIYAZAWAblog_banner.jpg\" width=\"200\" height=\"88\" align=\"right\" /><br />
+ファイブ・ディーは、Movable Typeで構築したプロモーション ブログ『宮沢和史 中南米ツアーblog Latin America 2005』を開設しました。</p>
+
+<p>9月21日に開設されたこのブログは、ブラジル、ホンジュラス、ニカラグア、メキシコ、キューバの5か国を巡る「Latin America 2005」ツアーに合わせ、そのツアーの模様を同行マネージャーがレポートしていきます。<br />
+さらに今月2日からは宮沢和史自身が日々録音した声をPodcastingするという点でも、ブログを使ったユニークなプロモーションとなっています。</p>
+
+<p><a href=\"http://www.five-d.co.jp/miyazawa/jp/blog/la2005/\">「宮沢和史 中南米ツアーblog Latin America 2005」</a></p>
+
+<p>※シックス・アパートではこうしたブログを使ったプロモーションに最適な製品をご用意しております。<br />
+<ul><li><a href=\"/movabletype/\">Movable Type</a><br />
+<li><a href=\"/typepad/typepad_promotion.html\">TypePad Promotion</a><br />
+</ul></p>";
+        $this->assertEquals($value, $this->entry->description);
+    }
+}
+
+$suite = new PHPUnit_TestSuite("XML_Feed_Parser_Japanese_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/XML_Feed_Parser_TestCase.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/XML_Feed_Parser_TestCase.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/XML_Feed_Parser_TestCase.php	(revision 14676)
@@ -0,0 +1,25 @@
+<?php
+set_include_path('/Users/james/Projects/PEAR' . PATH_SEPARATOR . get_include_path());
+require_once 'PEAR/Config.php';
+require_once 'XML/Feed/Parser.php';
+require_once 'PHPUnit.php';
+
+abstract class XML_Feed_Parser_TestCase extends PHPUnit_Testcase {
+    static function getSampleDir() {
+        $config = new PEAR_Config;
+        return $config->get('data_dir') . '/XML_Feed_Parser/samples';
+    }
+}
+
+abstract class XML_Feed_Parser_Converted_TestCase extends XML_Feed_Parser_TestCase {
+    function setup() {
+        $this->fp_test_dir = XML_Feed_Parser_TestCase::getSampleDir() . 
+            DIRECTORY_SEPARATOR . 'feedparsertests';
+        if (! is_dir($fp_test_dir)) {
+            throw new Exception('Feed parser tests must be unpacked into the folder ' . 
+                $this->fp_test_dir);
+        }
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomCompliance.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomCompliance.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomCompliance.php	(revision 14676)
@@ -0,0 +1,226 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+/**
+ * This test is to make sure that we get sane values back for all
+ * elements specified by the atom specification. It is okay for a feed
+ * to not have some of these, but if they're not present we should
+ * get a null or false return rather than an error. This test begins
+ * to ensure consistency of our API.
+ */
+class XML_Feed_Parser_AtomCompat1_TestCase extends XML_Feed_Parser_TestCase
+{
+    
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'atom10-example1.xml');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+    
+    function setUp() {
+    }
+    
+    function tearDown() {
+    }
+    
+    function checkString($attribute, $entry = false) {
+        if ($entry) {
+            $author = $this->entry->$attribute;            
+        } else {
+            $author = $this->parser->$attribute;
+        }
+        if (is_string($author) or $author === false) {
+            $test = true;
+        }
+        return $test;
+    }
+
+    function checkNumeric($attribute, $entry = false) {
+        if ($entry) {
+            $author = $this->entry->$attribute;            
+        } else {
+            $author = $this->parser->$attribute;
+        }
+        if (is_numeric($author)) {
+            $test = true;
+        } else if ($author === false) {
+            $test = true;
+        }
+        return $test;
+    }
+
+    function test_feedAuthor() {
+        $this->assertTrue($this->checkString('author'));
+    }
+
+    function test_feedContributor()
+    {
+        $this->assertTrue($this->checkString('contributor'));
+    }
+
+    function test_feedIcon() {
+        $this->assertTrue($this->checkString('icon'));
+    }
+    
+    function test_feedId() {
+        $this->assertTrue($this->checkString('id'));
+    }
+    
+    function test_feedRights() {
+        $this->assertTrue($this->checkString('rights'));
+    }
+    
+    function test_feedTitle() {
+        $this->assertTrue($this->checkString('title'));
+    }
+    
+    function test_feedSubtitle() {
+        $this->assertTrue($this->checkString('subtitle'));
+    }
+    
+    function test_feedUpdated() {
+        $this->assertTrue($this->checkNumeric('updated'));
+    }
+    
+    function test_feedLink() {
+        $this->assertTrue($this->checkString('link'));
+    }
+    
+    function test_entryAuthor() {
+        $this->assertTrue($this->checkString('author', true));
+    }
+
+    function test_entryContributor()
+    {
+        $this->assertTrue($this->checkString('contributor', true));
+    }
+
+    function test_entryId() {
+        $this->assertTrue($this->checkString('id', true));
+    }
+    
+    function test_entryPublished() {
+        $this->assertTrue($this->checkNumeric('published', true));
+    }
+    
+    function testEntryTitle() {
+        $this->assertTrue($this->checkString('title', true));
+    }
+    
+    function testEntryRights() {
+        $this->assertTrue($this->checkString('rights', true));
+    }
+    
+    function testEntrySummary() {
+        $this->assertTrue($this->checkString('summary', true));
+    }
+    
+    function testEntryContent() {
+        $this->assertTrue($this->checkString('content', true));
+    }
+    
+    function testEntryLink() {
+        $this->assertTrue($this->checkString('link', true));
+    }
+}
+
+class XML_Feed_Parser_AtomCompat2_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'atom10-example2.xml');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AtomCompat3_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'rss10-example1.xml');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AtomCompat4_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'rss10-example2.xml');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AtomCompat5_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'rss2sample.xml');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AtomCompat6_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'delicious.feed');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AtomCompat7_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'technorati.feed');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+class XML_Feed_Parser_AtomCompat8_TestCase extends XML_Feed_Parser_AtomCompat1_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'grwifi-atom.xml');
+        $this->parser = new XML_Feed_Parser($this->file);
+        $this->entry = $this->parser->getEntryByOffset(0);
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat1_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat2_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat3_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat4_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat5_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat6_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat7_TestCase');
+$suite->addTestSuite('XML_Feed_Parser_AtomCompat8_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/iteration.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/iteration.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/iteration.php	(revision 14676)
@@ -0,0 +1,53 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_Iteration_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $this->sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+    }
+    
+    function setUp() {
+    }
+    
+    function tearDown() {
+    }
+    
+    function test_Atom() {
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $feed = new XML_Feed_Parser(file_get_contents($this->sample_dir . "/grwifi-atom.xml"));
+        $entries = array();
+        foreach ($feed as $entry) {
+            array_push($entries, $entry);
+        }
+        $this->assertNotSame($entries[0], $entries[1]);
+    }
+
+    function test_RSS1() {
+        $feed = new XML_Feed_Parser(file_get_contents($this->sample_dir . "/delicious.feed"));
+        $entries = array();
+        foreach ($feed as $entry) {
+            array_push($entries, $entry);
+        }
+        $this->assertNotSame($entries[0], $entries[1]);
+    }
+    
+    function test_RSS2() {
+        $feed = new XML_Feed_Parser(file_get_contents($this->sample_dir . "/rss2sample.xml"));
+        $entries = array();
+        foreach ($feed as $entry) {
+            array_push($entries, $entry);
+        }
+        $this->assertNotSame($entries[0], $entries[1]);
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_Iteration_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/farsi.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/farsi.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/farsi.php	(revision 14676)
@@ -0,0 +1,27 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_Farsi_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'hoder.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function test_itemTitleFarsi()
+    {
+        $value = 'لينکدونی‌ | جلسه‌ی امریکن انترپرایز برای تقسیم قومی ایران';
+        $this->assertEquals($value, $this->entry->title);
+    }
+}
+
+$suite = new PHPUnit_TestSuite('XML_Feed_Parser_Farsi_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss1Values.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss1Values.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss1Values.php	(revision 14676)
@@ -0,0 +1,189 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_RSS1_valueValidity_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . "rss10-example2.xml");
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function setup()
+    {
+    }
+
+    function test_feedNumberItems()
+    {
+        $value = 1;
+        $this->assertEquals($value, $this->feed->numberEntries);
+    }
+    function test_feedTitle()
+    {
+        $value = "Meerkat";
+        $this->assertEquals($value, $this->feed->title);
+    }
+    
+    function test_feedLink()
+    {
+        $value = "http://meerkat.oreillynet.com";
+        $this->assertEquals($value, $this->feed->link);
+    }
+    
+    function test_feedDescription()
+    {
+        $value = "Meerkat: An Open Wire Service";
+        $this->assertEquals($value, $this->feed->description);
+    }
+    
+    function test_feedSubtitleEquivalence()
+    {
+        $value = "Meerkat: An Open Wire Service";
+        $this->assertEquals($value, $this->feed->subtitle);
+    }
+    
+    function test_feedPublisher()
+    {
+        $value = "The O'Reilly Network";
+        $this->assertEquals($value, $this->feed->publisher);
+    }
+    
+    function test_feedCreator()
+    {
+        $value = "Rael Dornfest (mailto:rael@oreilly.com)";
+        $this->assertEquals($value, $this->feed->creator);
+    }
+    
+    function test_feedAuthorEquivalence()
+    {
+        $value = "Rael Dornfest (mailto:rael@oreilly.com)"; 
+        $this->assertEquals($value, $this->feed->author);
+    }
+    
+    function test_feedRights()
+    {
+        $value = "Copyright &copy; 2000 O'Reilly &amp; Associates, Inc.";
+        $this->assertEquals($value, htmlentities(utf8_decode($this->feed->rights)));
+    }
+    
+    function test_feedDate()
+    {
+        $value = strtotime("2000-01-01T12:00+00:00");
+        $this->assertEquals($value, $this->feed->date);
+    }
+    
+    function test_feedUpdatedEquivalence()
+    {
+        $value = strtotime("2000-01-01T12:00+00:00");
+        $this->assertEquals($value, $this->feed->updated);
+    }
+    
+    function test_feedUpdatePeriod()
+    {
+        $value = 'hourly';
+        $this->assertEquals($value, $this->feed->updatePeriod);
+    }
+    
+    function test_feedUpdateFrequency()
+    {
+        $value = "2";
+        $this->assertEquals($value, $this->feed->updateFrequency);
+    }
+    
+    function test_feedUpdateBase()
+    {
+        $value = strtotime("2000-01-01T12:00+00:00");
+        $this->assertEquals($value, $this->feed->updateBase);
+    }
+    
+    function test_feedImage()
+    {
+        $value = array(
+            'title' => false,
+            'link' => false,
+            'url' => "http://meerkat.oreillynet.com/icons/meerkat-powered.jpg",
+            'description' => false,
+            'height' => false,
+            'width' => false);
+        $this->assertEquals($value, $this->feed->image);
+    }
+    
+    function test_entryTitle()
+    {
+        $value = "XML: A Disruptive Technology";
+        $this->assertEquals($value, $this->entry->title);
+    }
+    
+    function test_entryLink()
+    {
+        $value = "http://c.moreover.com/click/here.pl?r123";
+        $this->assertEquals($value, $this->entry->link);
+    }
+    
+    function test_entryDescription()
+    {
+        $value  = "XML is placing increasingly heavy loads on the existing technical infrastructure of the Internet.";
+        $description = trim($this->entry->description);
+        $description = preg_replace("/\t/", " ", $description);
+        $description = preg_replace("/(\s\s)+/", " ", $description);
+        $description = preg_replace("/(\s\s)+/", " ", $description);
+        $this->assertEquals($value, $description);
+    }
+    
+    function test_entryRights()
+    {
+        $value = "Copyright &copy; 2000 O'Reilly &amp; Associates, Inc.";
+        $this->assertEquals($value, htmlentities(utf8_decode($this->feed->rights)));
+    }
+    
+    function test_entryCreator()
+    {
+        $value = "Simon St.Laurent (mailto:simonstl@simonstl.com)";
+        $this->assertEquals($value, $this->entry->creator);
+    }
+    
+    function test_entryAuthorEquivalence()
+    {
+        $value = "Simon St.Laurent (mailto:simonstl@simonstl.com)";
+        $this->assertEquals($value, $this->entry->author);
+    }
+    
+    function test_entryPublisher()
+    {
+        $value = "The O'Reilly Network";
+        $this->assertEquals($value, $this->entry->publisher);
+    }
+    
+    function test_entryCategory()
+    {
+        $value = "XML";
+        $this->assertEquals($value, $this->entry->category);
+    }
+    
+    function test_entryIdEquivalence()
+    {
+        $value = "http://c.moreover.com/click/here.pl?r123";
+        $this->assertEquals($value, $this->entry->id);
+    }
+    
+    function test_feedTextInput()
+    {
+        $value = array(
+            'title' => null,
+             'description' => null,
+             'name' => null,
+             'link' => "http://meerkat.oreillynet.com");
+        $this->assertEquals($value, $this->feed->textinput);
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_RSS1_valueValidity_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss2Values.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss2Values.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/rss2Values.php	(revision 14676)
@@ -0,0 +1,147 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_RSS2_valueValidity_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . "rss2sample.xml");
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(2);
+    }
+
+    function test_feedNumberItems()
+    {
+        $value = 4;
+        $this->assertEquals($value, $this->feed->numberEntries);
+    }
+    function test_feedTitle()
+    {
+        $value = "Liftoff News";
+        $this->assertEquals($value, $this->feed->title);
+    }
+    
+    function test_feedLink()
+    {
+        $value = "http://liftoff.msfc.nasa.gov/";
+        $this->assertEquals($value, $this->feed->link);
+    }
+    
+    function test_feedDescription()
+    {
+        $value = "Liftoff to Space Exploration.";
+        $this->assertEquals($value, $this->feed->description);
+    }
+    
+    function test_feedSubtitleEquivalence()
+    {
+        $value = "Liftoff to Space Exploration.";
+        $this->assertEquals($value, $this->feed->subtitle);
+    }
+    
+    function test_feedDate()
+    {
+        $value = strtotime("Tue, 10 Jun 2003 04:00:00 GMT");
+        $this->assertEquals($value, $this->feed->date);
+    }
+    
+    function test_feedLastBuildDate()
+    {
+        $value = strtotime("Tue, 10 Jun 2003 09:41:01 GMT");
+        $this->assertEquals($value, $this->feed->lastBuildDate);
+    }
+    
+    function test_feedUpdatedEquivalence()
+    {
+        $value = strtotime("Tue, 10 Jun 2003 09:41:01 GMT");
+        $this->assertEquals($value, $this->feed->updated);
+    }
+    
+    function test_feedGenerator()
+    {
+        $value = 'Weblog Editor 2.0';
+        $this->assertEquals($value, $this->feed->generator);
+    }
+    
+    function test_feedLanguage()
+    {
+        $value = "en-us";
+        $this->assertEquals($value, $this->feed->language);
+    }
+    
+    function test_feedDocs()
+    {
+        $value = "http://blogs.law.harvard.edu/tech/rss";
+        $this->assertEquals($value, $this->feed->docs);
+    }
+    
+    function test_feedManagingEditor()
+    {
+        $value = "editor@example.com";
+        $this->assertEquals($value, $this->feed->managingEditor);
+    }
+    
+    function test_feedAuthorEquivalence()
+    {
+        $value = "editor@example.com";
+        $this->assertEquals($value, $this->feed->author);
+    }
+    
+    function test_feedWebmaster()
+    {
+        $value = "webmaster@example.com";
+        $this->assertEquals($value, $this->feed->webMaster);
+    }
+    
+    function test_entryTitle()
+    {
+        $value = "The Engine That Does More";
+        $this->assertEquals($value, $this->entry->title);
+    }
+    
+    function test_entryLink()
+    {
+        $value = "http://liftoff.msfc.nasa.gov/news/2003/news-VASIMR.asp";
+        $this->assertEquals($value, $this->entry->link);
+    }
+    
+    function test_entryDescription()
+    {
+        $value = "Before man travels to Mars, NASA hopes to design new engines that will let us fly through the Solar System more quickly.  The proposed VASIMR engine would do that.";
+        $this->assertEquals($value, $this->entry->description);
+    }
+    
+    function test_entryPubDate()
+    {
+        $value = strtotime("Tue, 27 May 2003 08:37:32 GMT");
+        $this->assertEquals($value, $this->entry->pubDate);
+    }
+    
+    function test_entryGuid()
+    {
+        $value = "http://liftoff.msfc.nasa.gov/2003/05/27.html#item571";
+        $this->assertEquals($value, $this->entry->guid);
+    }
+    
+    function test_entryIdEquivalence()
+    {
+        $value = "http://liftoff.msfc.nasa.gov/2003/05/27.html#item571";
+        $this->assertEquals($value, $this->entry->id);   
+    }
+
+	function test_entryContent()
+	{
+		$value = "<p>Test content</p>";
+		$this->assertEquals($value, $this->entry->content);
+	}
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_RSS2_valueValidity_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/tidy.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/tidy.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/tidy.php	(revision 14676)
@@ -0,0 +1,47 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_Tidy_TestCase extends XML_Feed_Parser_TestCase
+{
+    
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+    }
+    
+    function setUp() {
+    }
+    
+    function tearDown() {
+    }
+
+    /**
+     * Try to work with this ill-formed feed. If the tidy extension is not installed,
+     * it expects parsing to fail. If tidy is installed and parsing fails, the test
+     * fails. If tidy is installed and it parses, then the test passes.
+     */ 
+    function test_Tidy() {
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . "illformed_atom10.xml");
+        try {
+            $feed = new XML_Feed_Parser($file, false, true, true);    
+        } catch (XML_Feed_Parser_Exception $e) {
+            if (extension_loaded('tidy')) {
+                $this->assertTrue(false);
+            } else {
+                $this->assertTrue(true);
+            }
+            return;
+        }
+        $entry = $feed->getEntryByOffset(0);
+        $this->assertEquals($entry->author, 'Example author');
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_Tidy_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/errors.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/errors.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/errors.php	(revision 14676)
@@ -0,0 +1,98 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+/**
+ * This test is to make sure that we get errors when we should. In
+ * particular we check that it throws an exception if we hand in an
+ * illegal feed type.
+ */
+class XML_Feed_Parser_ThrowErrors_TestCase extends XML_Feed_Parser_TestCase
+{
+    
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+    }
+    
+    function setUp() {
+    }
+    
+    function tearDown() {
+    }
+    
+    function test_fakeFeedType()
+    {
+        $file = "<myfeed><myitem /></myfeed>";
+        try {
+            $feed = new XML_Feed_Parser($file, false, true);
+        } catch (Exception $e) {
+            $this->assertTrue($e instanceof XML_Feed_Parser_Exception);
+        }
+    }
+    
+    function test_badRSSVersion()
+    {
+        $file = "<?xml version=\"1.0\"?>
+        <rss version=\"0.8\">
+           <channel></channel></rss>";
+       try {
+           $feed = new XML_Feed_Parser($file, false, true);
+       } catch (Exception $e) {
+           $this->assertTrue($e instanceof XML_Feed_Parser_Exception);
+       }
+    }
+    
+    function test_emptyInput()
+    {
+        $file = null;
+        try {
+            $feed = new XML_Feed_Parser($file, false, true);
+        } catch (Exception $e) {
+            $this->assertTrue($e instanceof XML_Feed_Parser_Exception);
+        }
+    }
+
+    function test_nonXMLInput()
+    {
+        $file = "My string";
+        try {
+            $feed = new XML_Feed_Parser($file, false, true);
+        } catch (Exception $e) {
+            $this->assertTrue($e instanceof XML_Feed_Parser_Exception);
+        }
+    }
+    
+    function test_missingElement() {
+        $file = '<?xml version="1.0" encoding="utf-8"?>
+        <rss version="2.0">
+           <channel>
+              <title>sample blog</title>
+              <link>http://www.example.com/</link>
+              <description>sample rss2 feed</description>
+              <language>en</language>
+              <copyright>Copyright 2006</copyright>
+              <lastBuildDate>Tue, 25 Jul 2006 11:53:38 -0500</lastBuildDate>
+              <generator>http://www.sixapart.com/movabletype/?v=3.31</generator>
+              <docs>http://blogs.law.harvard.edu/tech/rss</docs> 
+              <item>
+                 <title>A sample entry</title>
+                 <description>Sample content</description>
+                 <link>http://www.example.com/archives/2006/07</link>
+                 <guid>http://www.example.com/archives/2006/07</guid>
+                 <category>Examples</category>
+                 <pubDate>Tue, 25 Jul 2006 11:53:38 -0500</pubDate>
+              </item>
+            </channel></rss>';
+          $feed = new XML_Feed_Parser($file, false, true);
+          $entry = $feed->getEntryByOffset(0);
+          $this->assertFalse($entry->enclosure());
+    }
+}
+
+$suite = new PHPUnit_TestSuite;
+$suite->addTestSuite("XML_Feed_Parser_ThrowErrors_TestCase");
+$result = PHPUnit::run($suite, "123");
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomValues.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomValues.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/atomValues.php	(revision 14676)
@@ -0,0 +1,161 @@
+<?php
+
+require_once 'XML_Feed_Parser_TestCase.php';
+
+class XML_Feed_Parser_Atom_valueValidity_TestCase extends XML_Feed_Parser_TestCase
+{
+    function __construct($name)
+    {
+        $this->PHPUnit_TestCase($name);
+        $sample_dir = XML_Feed_Parser_TestCase::getSampleDir();
+        $this->file = file_get_contents($sample_dir . DIRECTORY_SEPARATOR . 'atom10-example2.xml');
+        $this->feed = new XML_Feed_Parser($this->file);
+        $this->entry = $this->feed->getEntryByOffset(0);
+    }
+
+    function test_feedNumberItems()
+    {
+        $value = 1;
+        $this->assertEquals($value, $this->feed->numberEntries);
+    }
+
+    function test_FeedTitle()
+    {
+        $value = 'dive into mark';
+        $this->assertEquals($value, $this->feed->title);
+    }
+    
+    function test_feedSubtitle()
+    {
+        $value = 'A <em>lot</em> of effort
+  went into making this effortless';
+        $content = trim($this->feed->subtitle);
+        $content = preg_replace('/\t/', ' ', $content);
+        $content = preg_replace('/(  )+/', ' ', $content);
+        $this->assertEquals($content, $value);
+    }
+    
+    function test_feedUpdated()
+    {
+        $value = strtotime('2005-07-31T12:29:29Z');
+        $this->assertEquals($this->feed->updated, $value);
+    }
+    
+    function test_feedId()
+    {
+        $value = 'tag:example.org,2003:3';
+        $this->assertEquals($this->feed->id, $value);
+    }
+    
+    function test_feedRights()
+    {
+        $value = 'Copyright (c) 2003, Mark Pilgrim';
+        $this->assertEquals($this->feed->rights, $value);
+    }
+    
+    function test_feedLinkPlain()
+    {
+        $value = 'http://example.org/';
+        $this->assertEquals($this->feed->link, $value);
+    }
+
+    function test_feedLinkAttributes()
+    {
+        $value = 'self';
+        $link = $this->feed->link(0, 'rel', array('type' => 'application/atom+xml'));
+        $this->assertEquals($link, $value);
+    }
+    
+    function test_feedGenerator()
+    {
+        $value = 'Example Toolkit';
+        $this->assertEquals($value, trim($this->feed->generator));
+    }
+    
+    function test_entryTitle()
+    {
+        $value = 'Atom draft-07 snapshot';
+        $this->assertEquals($value, trim($this->entry->title));
+    }
+    
+    function test_entryLink()
+    {
+        $value = 'http://example.org/2005/04/02/atom';
+        $this->assertEquals($value, trim($this->entry->link));
+    }
+    
+    function test_entryId()
+    {
+        $value = 'tag:example.org,2003:3.2397';
+        $this->assertEquals($value, trim($this->entry->id));
+    }
+    function test_entryUpdated()
+    {
+        $value = strtotime('2005-07-31T12:29:29Z');
+        $this->assertEquals($value, $this->entry->updated);
+    }
+    
+    function test_entryPublished()
+    {
+        $value = strtotime('2003-12-13T08:29:29-04:00');
+        $this->assertEquals($value, $this->entry->published);
+    }
+    
+    function test_entryContent()
+    {
+        $value = '<p><i>[Update: The Atom draft is finished.]</i></p>';
+        $content = trim($this->entry->content);
+        $content = preg_replace('/\t/', ' ', $content);
+        $content = preg_replace('/(  )+/', ' ', $content);
+        $this->assertEquals($value, $content);
+    }
+    
+    function test_entryAuthorURL()
+    {
+        $value = 'http://example.org/';
+        $name = $this->entry->author(false, array('param' => 'uri'));
+        $this->assertEquals($value, $name);
+    }
+    
+    function test_entryAuthorName()
+    {
+        $value = 'Mark Pilgrim';
+        $this->assertEquals($value, $this->entry->author);
+    }
+    
+    function test_entryContributor()
+    {
+        $value = 'Sam Ruby';
+        $this->assertEquals($value, $this->entry->contributor);
+    }
+    
+    function test_entryContributorOffset()
+    {
+        $value = 'Joe Gregorio';
+        $this->assertEquals($value, $this->entry->contributor(1));
+    }
+    
+    # According to RFC4287 section 4.2.7.2:
+    # [..]If the 'rel' attribute is not present, the link element MUST be
+    # interpreted as if the link relation type is "alternate".
+    function test_getsLinkWithoutRel()
+    {
+        $source = '<?xml version="1.0" ?>
+        <entry xmlns="http://www.w3.org/2005/Atom">
+        <link href="http://example.org/2005/04/02/atom" />
+        </entry>
+        ';
+        $feed = new XML_Feed_Parser($source);
+        $entry = $feed->getEntryByOffset(0);
+
+        // Output
+        $this->assertEquals( "http://example.org/2005/04/02/atom", 
+            $entry->link(0, 'href', array('rel'=>'alternate')));
+    }
+}
+
+$suite = new PHPUnit_TestSuite('XML_Feed_Parser_Atom_valueValidity_TestCase');
+$result = PHPUnit::run($suite, '123');
+echo $result->toString();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convert-tests.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convert-tests.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/tests/convert-tests.php	(revision 14676)
@@ -0,0 +1,148 @@
+<?php
+
+$template = '<?php
+require_once \'PHPUnit.php\';
+require_once \'XML/Feed/Parser.php\';
+class ';
+
+$endTemplate = '
+$result = PHPUnit::run($suite, \'123\');
+echo $result->toString();
+
+?>
+';
+error_reporting(E_ERROR);
+
+function applyFilters(&$test)
+{
+    if (! strstr($test, 'bozo') and ! preg_match('/^encoding/', $test)
+        and ! preg_match('/^header/', $test))
+    {
+        $testparts = explode(' == ', $test);
+        $testparts[0] = preg_replace('/^not/', '!', $testparts[0]);
+        $testparts[0] = preg_replace('/(^|\s)feed/', '$1\$feed', $testparts[0]);
+        $testparts[0] = preg_replace('/entries\[(\d+)\]/', '\$feed->getEntryByOffset($1)', $testparts[0]);
+        $testparts[0] = preg_replace('/\[\'(.*)\'\]/', '->$1', $testparts[0]);
+        $testparts[0] = preg_replace('/\'.*?\'/', '->', $testparts[0]);
+        $testparts[0] = preg_replace('/^version$/', '\$feed->version()', $testparts[0]);
+        $testparts[0] = preg_replace('/_detail->value/', '', $testparts[0]);
+        $testparts[0] = preg_replace('/_detail->(.*)/', '(0, \'$1\')', $testparts[0]);
+        $testparts[0] = preg_replace('/getEntryByOffset\(0\)->(.*?)->(.*)/', 
+            'getEntryByOffset(0)->$1(0, \'$2\')', $testparts[0]);
+
+        if (! preg_match('/feed->getEntry/', $testparts[0])) {
+            $testparts[0] = preg_replace('/feed->(.*?)->(.*)/', 'feed->$1(0, \'$2\')', $testparts[0]);
+        }
+
+        $testparts[1] = preg_replace('/u\'/', '\'', $testparts[1]);
+        $testparts[1] = preg_replace('/\'(.*?)\': \'(.*?)\'/', '\'$1\' => \'$2\'', $testparts[1]);
+        $testparts[1] = preg_replace('/{(.*?)}/', 'array($1)', $testparts[1]);
+        $testparts[1] = preg_replace('/\[(.*?)\]/', 'array($1)', $testparts[1]);
+        $testparts[1] = preg_replace('/^\((.*)\)$/', 'array($1)', $testparts[1]);
+        $testparts[1] = preg_replace('/^<div>(.*)<\/div>$/', '$1', $testparts[1]);
+
+        $test = implode(' == ', $testparts);
+        return $test;
+    }
+}
+
+function testToPHP($test)
+{
+    $tests = explode(' and ', $test);
+    return $tests;
+}
+
+function extractTest($path)
+{
+    $data = array();
+    $f = fopen('./feedparsertests/wellformed/' . $path, 'r');
+    while ($line = fgets($f))
+    {
+        $line = trim($line);
+        if (preg_match('/^Description:/', $line))
+        {
+            $data['description'] = trim(preg_replace('/Description:/', '', $line));
+        } else if (preg_match('/^Expect:/', $line))
+        {
+            $data['expect'] = trim(preg_replace('/Expect:/', '', $line));
+        }
+        if (!empty($data['expect']) and !empty($data['description']))
+        {
+            break;
+        }
+    }
+    fclose($f);
+    return $data;
+}
+
+$handle = opendir('./feedparsertests/wellformed/');
+$tests_passed = array();
+$tests_failed = array();
+$all_tests = array();
+while (false !== ($dir = readdir($handle)))
+{
+    if (! preg_match('/^\./', $dir) and is_dir('./feedparsertests/wellformed/' . $dir))
+    {
+        $tests_passed[$dir] = array();
+        $tests_failed[$dir] = array();
+        $allTests[$dir] = array();
+        $innerHandle = opendir('feedparsertests/wellformed/' . $dir);
+        while (false !== ($file = readdir($innerHandle)))
+        {
+            if (preg_match('/.xml$/', $file))
+            {
+                $parts = extractTest($dir . '/' . $file);
+                $theseTests = testToPHP($parts['expect']);
+                foreach ($theseTests as $thisKey => $thisTest)
+                {
+                    $allTests[$dir][$file . '_' . $thisKey] = $thisTest;
+                }
+            }
+        }
+        $iterTests = array_filter($allTests[$dir], 'applyFilters');
+        $fw = fopen('./convertedtests/' . $dir . '.php', 'w');
+        fwrite($fw, $template . $dir . "_TestCase extends XML_Feed_Parser_TestCase {\n");
+        foreach($iterTests as $key => $test)
+        {
+            $funcname = str_replace('.xml', '', $key);
+            $funcname = str_replace('.', '_', $funcname);
+            $file = preg_replace('/(.*)_.*/', '$1', $key);
+            fwrite($fw, '
+    function test_' . $funcname . ' () { 
+        $content = file_get_contents(\'../feedparsertests/wellformed/' . $dir . '/' . $file . '\');
+        try {
+            $feed = new XML_Feed_Parser($content);
+        } catch (XML_Feed_Parser_Exception $e) {
+            $this->assertTrue(false);
+            return;
+        }
+        $this->assertEquals(' . implode(', ', array_reverse(explode(' == ', $test))) .');
+    }
+');
+        }
+        fwrite($fw, '}
+
+$suite = new PHPUnit_TestSuite(\'' . $dir . '_TestCase\');');
+        fwrite($fw, $endTemplate);
+        fclose($fw);
+        $all_tests = array_merge($all_tests, $allTests[$dir]);
+    }
+}
+
+$total_tests = 0;
+$total_passed = 0;
+$total_failed = 0;
+
+foreach($tests_passed as $test)
+{
+    $total_tests += count($test);
+    $total_passed += count($test);
+}
+
+foreach ($tests_failed as $testf)
+{
+    $total_tests += count($testf);
+    $total_failed += count($testf);
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/atom.rnc
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/atom.rnc	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/atom.rnc	(revision 14676)
@@ -0,0 +1,338 @@
+# -*- rnc -*-
+# RELAX NG Compact Syntax Grammar for the
+# Atom Format Specification Version 11
+
+namespace atom = "http://www.w3.org/2005/Atom"
+namespace xhtml = "http://www.w3.org/1999/xhtml"
+namespace s = "http://www.ascc.net/xml/schematron"
+namespace local = ""
+
+start = atomFeed | atomEntry
+
+# Common attributes
+
+atomCommonAttributes =
+   attribute xml:base { atomUri }?,
+   attribute xml:lang { atomLanguageTag }?,
+   undefinedAttribute*
+
+# Text Constructs
+
+atomPlainTextConstruct =
+   atomCommonAttributes,
+   attribute type { "text" | "html" }?,
+   text
+
+atomXHTMLTextConstruct =
+   atomCommonAttributes,
+   attribute type { "xhtml" },
+   xhtmlDiv
+
+atomTextConstruct = atomPlainTextConstruct | atomXHTMLTextConstruct
+
+# Person Construct
+
+atomPersonConstruct =
+   atomCommonAttributes,
+   (element atom:name { text }
+    & element atom:uri { atomUri }?
+    & element atom:email { atomEmailAddress }?
+    & extensionElement*)
+
+# Date Construct
+
+atomDateConstruct =
+   atomCommonAttributes,
+   xsd:dateTime
+
+# atom:feed
+
+atomFeed =
+   [
+      s:rule [
+         context = "atom:feed"
+         s:assert [
+            test = "atom:author or not(atom:entry[not(atom:author)])"
+            "An atom:feed must have an atom:author unless all "
+            ~ "of its atom:entry children have an atom:author."
+         ]
+      ]
+   ]
+   element atom:feed {
+      atomCommonAttributes,
+      (atomAuthor*
+       & atomCategory*
+       & atomContributor*
+       & atomGenerator?
+       & atomIcon?
+       & atomId
+       & atomLink*
+       & atomLogo?
+       & atomRights?
+       & atomSubtitle?
+       & atomTitle
+       & atomUpdated
+       & extensionElement*),
+      atomEntry*
+   }
+
+# atom:entry
+
+atomEntry =
+   [
+      s:rule [
+         context = "atom:entry"
+         s:assert [
+            test = "atom:link[@rel='alternate'] "
+            ~ "or atom:link[not(@rel)] "
+            ~ "or atom:content"
+            "An atom:entry must have at least one atom:link element "
+            ~ "with a rel attribute of 'alternate' "
+            ~ "or an atom:content."
+         ]
+      ]
+      s:rule [
+         context = "atom:entry"
+         s:assert [
+            test = "atom:author or "
+            ~ "../atom:author or atom:source/atom:author"
+            "An atom:entry must have an atom:author "
+            ~ "if its feed does not."
+         ]
+      ]
+   ]
+   element atom:entry {
+      atomCommonAttributes,
+      (atomAuthor*
+       & atomCategory*
+       & atomContent?
+       & atomContributor*
+       & atomId
+       & atomLink*
+       & atomPublished?
+       & atomRights?
+       & atomSource?
+       & atomSummary?
+       & atomTitle
+       & atomUpdated
+       & extensionElement*)
+   }
+
+# atom:content
+
+atomInlineTextContent =
+   element atom:content {
+      atomCommonAttributes,
+      attribute type { "text" | "html" }?,
+      (text)*
+   }
+
+atomInlineXHTMLContent =
+   element atom:content {
+      atomCommonAttributes,
+      attribute type { "xhtml" },
+      xhtmlDiv
+   }
+
+atomInlineOtherContent =
+   element atom:content {
+      atomCommonAttributes,
+      attribute type { atomMediaType }?,
+      (text|anyElement)*
+   }
+
+atomOutOfLineContent =
+   element atom:content {
+      atomCommonAttributes,
+      attribute type { atomMediaType }?,
+      attribute src { atomUri },
+      empty
+   }
+
+atomContent = atomInlineTextContent
+ | atomInlineXHTMLContent
+ | atomInlineOtherContent
+ | atomOutOfLineContent
+
+# atom:author
+
+atomAuthor = element atom:author { atomPersonConstruct }
+
+# atom:category
+
+atomCategory =
+   element atom:category {
+      atomCommonAttributes,
+      attribute term { text },
+      attribute scheme { atomUri }?,
+      attribute label { text }?,
+      undefinedContent
+   }
+
+# atom:contributor
+
+atomContributor = element atom:contributor { atomPersonConstruct }
+
+# atom:generator
+
+atomGenerator = element atom:generator {
+   atomCommonAttributes,
+   attribute uri { atomUri }?,
+   attribute version { text }?,
+   text
+}
+
+# atom:icon
+
+atomIcon = element atom:icon {
+   atomCommonAttributes,
+   (atomUri)
+}
+
+# atom:id
+
+atomId = element atom:id {
+   atomCommonAttributes,
+   (atomUri)
+}
+
+# atom:logo
+
+atomLogo = element atom:logo {
+   atomCommonAttributes,
+   (atomUri)
+}
+
+# atom:link
+
+atomLink =
+   element atom:link {
+      atomCommonAttributes,
+      attribute href { atomUri },
+      attribute rel { atomNCName | atomUri }?,
+      attribute type { atomMediaType }?,
+      attribute hreflang { atomLanguageTag }?,
+      attribute title { text }?,
+      attribute length { text }?,
+      undefinedContent
+   }
+
+# atom:published
+
+atomPublished = element atom:published { atomDateConstruct }
+
+# atom:rights
+
+atomRights = element atom:rights { atomTextConstruct }
+
+# atom:source
+
+atomSource =
+   element atom:source {
+      atomCommonAttributes,
+      (atomAuthor*
+       & atomCategory*
+       & atomContributor*
+       & atomGenerator?
+       & atomIcon?
+       & atomId?
+       & atomLink*
+       & atomLogo?
+       & atomRights?
+       & atomSubtitle?
+       & atomTitle?
+       & atomUpdated?
+       & extensionElement*)
+   }
+
+# atom:subtitle
+
+atomSubtitle = element atom:subtitle { atomTextConstruct }
+
+# atom:summary
+
+atomSummary = element atom:summary { atomTextConstruct }
+
+# atom:title
+
+atomTitle = element atom:title { atomTextConstruct }
+
+# atom:updated
+
+atomUpdated = element atom:updated { atomDateConstruct }
+
+# Low-level simple types
+
+atomNCName = xsd:string { minLength = "1" pattern = "[^:]*" }
+
+# Whatever a media type is, it contains at least one slash
+atomMediaType = xsd:string { pattern = ".+/.+" }
+
+# As defined in RFC 3066
+atomLanguageTag = xsd:string {
+   pattern = "[A-Za-z]{1,8}(-[A-Za-z0-9]{1,8})*"
+}
+
+# Unconstrained; it's not entirely clear how IRI fit into
+# xsd:anyURI so let's not try to constrain it here
+atomUri = text
+
+# Whatever an email address is, it contains at least one @
+atomEmailAddress = xsd:string { pattern = ".+@.+" }
+
+# Simple Extension
+
+simpleExtensionElement =
+   element * - atom:* {
+      text
+   }
+
+# Structured Extension
+
+structuredExtensionElement =
+   element * - atom:* {
+      (attribute * { text }+,
+         (text|anyElement)*)
+    | (attribute * { text }*,
+       (text?, anyElement+, (text|anyElement)*))
+   }
+
+# Other Extensibility
+
+extensionElement =
+   simpleExtensionElement | structuredExtensionElement
+
+undefinedAttribute =
+  attribute * - (xml:base | xml:lang | local:*) { text }
+
+undefinedContent = (text|anyForeignElement)*
+
+anyElement =
+   element * {
+      (attribute * { text }
+       | text
+       | anyElement)*
+   }
+
+anyForeignElement =
+   element * - atom:* {
+      (attribute * { text }
+       | text
+       | anyElement)*
+   }
+
+# XHTML
+
+anyXHTML = element xhtml:* {
+   (attribute * { text }
+    | text
+    | anyXHTML)*
+}
+
+xhtmlDiv = element xhtml:div {
+   (attribute * { text }
+    | text
+    | anyXHTML)*
+}
+
+# EOF
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/rss10.rnc
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/rss10.rnc	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/rss10.rnc	(revision 14676)
@@ -0,0 +1,113 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<!-- http://www.xml.com/lpt/a/2002/01/23/relaxng.html -->
+<!-- http://www.oasis-open.org/committees/relax-ng/tutorial-20011203.html -->
+<!-- http://www.zvon.org/xxl/XMLSchemaTutorial/Output/ser_wildcards_st8.html -->
+
+<grammar xmlns='http://relaxng.org/ns/structure/1.0'
+        xmlns:rdf='http://www.w3.org/1999/02/22-rdf-syntax-ns#'
+        xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
+        ns='http://purl.org/rss/1.0/'
+        datatypeLibrary='http://www.w3.org/2001/XMLSchema-datatypes'>
+
+    <start>
+        <element name='RDF' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+            <ref name='RDFContent'/>
+        </element>
+    </start>   
+
+    <define name='RDFContent' ns='http://purl.org/rss/1.0/'>
+        <interleave>
+            <element name='channel'>
+                <ref name='channelContent'/>
+            </element>
+            <optional>
+                <element name='image'><ref name='imageContent'/></element>
+            </optional>
+            <oneOrMore>
+                <element name='item'><ref name='itemContent'/></element>
+            </oneOrMore>
+        </interleave>
+    </define>
+
+     <define name='channelContent' combine="interleave">
+        <interleave>
+            <element name='title'><data type='string'/></element>
+            <element name='link'><data type='anyURI'/></element>
+            <element name='description'><data type='string'/></element>
+            <element name='image'>
+                <attribute name='resource' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                    <data type='anyURI'/>
+                </attribute>
+            </element>
+            <element name='items'>
+                    <ref name='itemsContent'/>
+            </element>
+            <attribute name='about' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                <data type='anyURI'/>
+            </attribute>
+        </interleave>
+    </define>
+    
+        <define name="itemsContent">
+            <element name="Seq" ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                <oneOrMore>
+                    <element name="li" ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                        <choice>
+                            <attribute name='resource'>    <!-- Why doesn't RDF/RSS1.0 ns qualify this attribute? -->
+                                <data type='anyURI'/>
+                            </attribute>
+                            <attribute name='resource' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                                <data type='anyURI'/>
+                            </attribute>
+                        </choice>
+                    </element>
+                </oneOrMore>
+            </element>
+        </define>
+        
+    <define name='imageContent'>
+        <interleave>
+            <element name='title'><data type='string'/></element>
+            <element name='link'><data type='anyURI'/></element>
+            <element name='url'><data type='anyURI'/></element>
+            <attribute name='about' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                <data type='anyURI'/>
+            </attribute>
+        </interleave>
+    </define>
+
+    <define name='itemContent'>
+        <interleave>
+            <element name='title'><data type='string'/></element>
+            <element name='link'><data type='anyURI'/></element>
+            <optional><element name='description'><data type='string'/></element></optional>
+            <ref name="anyThing"/>
+            <attribute name='about' ns='http://www.w3.org/1999/02/22-rdf-syntax-ns#'>
+                <data type='anyURI'/>
+            </attribute>
+        </interleave>
+    </define>            
+            
+
+        <define name='anyThing'>
+            <zeroOrMore>
+                <choice>
+                    <text/>
+                    <element>
+                        <anyName>
+                            <except>
+                                <nsName/>
+                            </except>
+                        </anyName>
+                        <ref name='anyThing'/>
+                        <zeroOrMore>
+                            <attribute>
+                              <anyName/>
+                            </attribute>
+                        </zeroOrMore>
+                    </element>
+                </choice>
+            </zeroOrMore>
+            </define>
+            
+</grammar>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/rss11.rnc
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/rss11.rnc	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/schemas/rss11.rnc	(revision 14676)
@@ -0,0 +1,218 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  RELAX NG Compact Schema for RSS 1.1
+  Sean B. Palmer, inamidst.com
+  Christopher Schmidt, crschmidt.net
+  License: This schema is in the public domain
+-->
+<grammar xmlns:rss="http://purl.org/net/rss1.1#" xmlns:a="http://relaxng.org/ns/compatibility/annotations/1.0" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" ns="http://purl.org/net/rss1.1#" xmlns="http://relaxng.org/ns/structure/1.0" datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
+  <start>
+    <ref name="Channel"/>
+  </start>
+  <define name="Channel">
+    <a:documentation>http://purl.org/net/rss1.1#Channel</a:documentation>
+    <element name="Channel">
+      <ref name="Channel.content"/>
+
+    </element>
+  </define>
+  <define name="Channel.content">
+    <optional>
+      <ref name="AttrXMLLang"/>
+    </optional>
+    <optional>
+      <ref name="AttrXMLBase"/>
+    </optional>
+
+    <ref name="AttrRDFAbout"/>
+    <interleave>
+      <ref name="title"/>
+      <ref name="link"/>
+      <ref name="description"/>
+      <optional>
+        <ref name="image"/>
+      </optional>
+      <zeroOrMore>
+
+        <ref name="Any"/>
+      </zeroOrMore>
+      <ref name="items"/>
+    </interleave>
+  </define>
+  <define name="title">
+    <a:documentation>http://purl.org/net/rss1.1#title</a:documentation>
+    <element name="title">
+
+      <ref name="title.content"/>
+    </element>
+  </define>
+  <define name="title.content">
+    <optional>
+      <ref name="AttrXMLLang"/>
+    </optional>
+    <text/>
+  </define>
+
+  <define name="link">
+    <a:documentation>http://purl.org/net/rss1.1#link</a:documentation>
+    <element name="link">
+      <ref name="link.content"/>
+    </element>
+  </define>
+  <define name="link.content">
+    <data type="anyURI"/>
+
+  </define>
+  <define name="description">
+    <a:documentation>http://purl.org/net/rss1.1#description</a:documentation>
+    <element name="description">
+      <ref name="description.content"/>
+    </element>
+  </define>
+  <define name="description.content">
+
+    <optional>
+      <ref name="AttrXMLLang"/>
+    </optional>
+    <text/>
+  </define>
+  <define name="image">
+    <a:documentation>http://purl.org/net/rss1.1#image</a:documentation>
+    <element name="image">
+
+      <ref name="image.content"/>
+    </element>
+  </define>
+  <define name="image.content">
+    <optional>
+      <ref name="AttrXMLLang"/>
+    </optional>
+    <ref name="AttrRDFResource"/>
+    <interleave>
+
+      <ref name="title"/>
+      <optional>
+        <ref name="link"/>
+      </optional>
+      <ref name="url"/>
+      <zeroOrMore>
+        <ref name="Any"/>
+      </zeroOrMore>
+    </interleave>
+
+  </define>
+  <define name="url">
+    <a:documentation>http://purl.org/net/rss1.1#url</a:documentation>
+    <element name="url">
+      <ref name="url.content"/>
+    </element>
+  </define>
+  <define name="url.content">
+
+    <data type="anyURI"/>
+  </define>
+  <define name="items">
+    <a:documentation>http://purl.org/net/rss1.1#items</a:documentation>
+    <element name="items">
+      <ref name="items.content"/>
+    </element>
+  </define>
+
+  <define name="items.content">
+    <optional>
+      <ref name="AttrXMLLang"/>
+    </optional>
+    <ref name="AttrRDFCollection"/>
+    <zeroOrMore>
+      <ref name="item"/>
+    </zeroOrMore>
+  </define>
+
+  <define name="item">
+    <a:documentation>http://purl.org/net/rss1.1#item</a:documentation>
+    <element name="item">
+      <ref name="item.content"/>
+    </element>
+  </define>
+  <define name="item.content">
+    <optional>
+
+      <ref name="AttrXMLLang"/>
+    </optional>
+    <ref name="AttrRDFAbout"/>
+    <interleave>
+      <ref name="title"/>
+      <ref name="link"/>
+      <optional>
+        <ref name="description"/>
+      </optional>
+
+      <optional>
+        <ref name="image"/>
+      </optional>
+      <zeroOrMore>
+        <ref name="Any"/>
+      </zeroOrMore>
+    </interleave>
+  </define>
+  <define name="Any">
+
+    <a:documentation>http://purl.org/net/rss1.1#Any</a:documentation>
+    <element>
+      <anyName>
+        <except>
+          <nsName/>
+        </except>
+      </anyName>
+      <ref name="Any.content"/>
+
+    </element>
+  </define>
+  <define name="Any.content">
+    <zeroOrMore>
+      <attribute>
+        <anyName>
+          <except>
+            <nsName/>
+            <nsName ns=""/>
+
+          </except>
+        </anyName>
+      </attribute>
+    </zeroOrMore>
+    <mixed>
+      <zeroOrMore>
+        <ref name="Any"/>
+      </zeroOrMore>
+    </mixed>
+
+  </define>
+  <define name="AttrXMLLang">
+    <attribute name="xml:lang">
+      <data type="language"/>
+    </attribute>
+  </define>
+  <define name="AttrXMLBase">
+    <attribute name="xml:base">
+      <data type="anyURI"/>
+
+    </attribute>
+  </define>
+  <define name="AttrRDFAbout">
+    <attribute name="rdf:about">
+      <data type="anyURI"/>
+    </attribute>
+  </define>
+  <define name="AttrRDFResource">
+    <attribute name="rdf:parseType">
+
+      <value>Resource</value>
+    </attribute>
+  </define>
+  <define name="AttrRDFCollection">
+    <attribute name="rdf:parseType">
+      <value>Collection</value>
+    </attribute>
+  </define>
+
+</grammar>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss10-example1.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss10-example1.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss10-example1.xml	(revision 14676)
@@ -0,0 +1,62 @@
+<?xml version="1.0"?>
+
+<rdf:RDF 
+  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+  xmlns="http://purl.org/rss/1.0/"
+>
+
+  <channel rdf:about="http://www.xml.com/xml/news.rss">
+    <title>XML.com</title>
+    <link>http://xml.com/pub</link>
+    <description>
+      XML.com features a rich mix of information and services 
+      for the XML community.
+    </description>
+
+    <image rdf:resource="http://xml.com/universal/images/xml_tiny.gif" />
+
+    <items>
+      <rdf:Seq>
+        <rdf:li resource="http://xml.com/pub/2000/08/09/xslt/xslt.html" />
+        <rdf:li resource="http://xml.com/pub/2000/08/09/rdfdb/index.html" />
+      </rdf:Seq>
+    </items>
+
+    <textinput rdf:resource="http://search.xml.com" />
+
+  </channel>
+  
+  <image rdf:about="http://xml.com/universal/images/xml_tiny.gif">
+    <title>XML.com</title>
+    <link>http://www.xml.com</link>
+    <url>http://xml.com/universal/images/xml_tiny.gif</url>
+  </image>
+  
+  <item rdf:about="http://xml.com/pub/2000/08/09/xslt/xslt.html">
+    <title>Processing Inclusions with XSLT</title>
+    <link>http://xml.com/pub/2000/08/09/xslt/xslt.html</link>
+    <description>
+     Processing document inclusions with general XML tools can be 
+     problematic. This article proposes a way of preserving inclusion 
+     information through SAX-based processing.
+    </description>
+  </item>
+  
+  <item rdf:about="http://xml.com/pub/2000/08/09/rdfdb/index.html">
+    <title>Putting RDF to Work</title>
+    <link>http://xml.com/pub/2000/08/09/rdfdb/index.html</link>
+    <description>
+     Tool and API support for the Resource Description Framework 
+     is slowly coming of age. Edd Dumbill takes a look at RDFDB, 
+     one of the most exciting new RDF toolkits.
+    </description>
+  </item>
+
+  <textinput rdf:about="http://search.xml.com">
+    <title>Search XML.com</title>
+    <description>Search XML.com's XML collection</description>
+    <name>s</name>
+    <link>http://search.xml.com</link>
+  </textinput>
+
+</rdf:RDF>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss10-example2.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss10-example2.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss10-example2.xml	(revision 14676)
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="utf-8"?> 
+
+<rdf:RDF 
+  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" 
+  xmlns:dc="http://purl.org/dc/elements/1.1/"
+  xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
+  xmlns:co="http://purl.org/rss/1.0/modules/company/"
+  xmlns:ti="http://purl.org/rss/1.0/modules/textinput/"
+  xmlns="http://purl.org/rss/1.0/"
+> 
+
+  <channel rdf:about="http://meerkat.oreillynet.com/?_fl=rss1.0">
+    <title>Meerkat</title>
+    <link>http://meerkat.oreillynet.com</link>
+    <description>Meerkat: An Open Wire Service</description>
+    <dc:publisher>The O'Reilly Network</dc:publisher>
+    <dc:creator>Rael Dornfest (mailto:rael@oreilly.com)</dc:creator>
+    <dc:rights>Copyright &#169; 2000 O'Reilly &amp; Associates, Inc.</dc:rights>
+    <dc:date>2000-01-01T12:00+00:00</dc:date>
+    <sy:updatePeriod>hourly</sy:updatePeriod>
+    <sy:updateFrequency>2</sy:updateFrequency>
+    <sy:updateBase>2000-01-01T12:00+00:00</sy:updateBase>
+
+    <image rdf:resource="http://meerkat.oreillynet.com/icons/meerkat-powered.jpg" />
+
+    <items>
+      <rdf:Seq>
+        <rdf:li resource="http://c.moreover.com/click/here.pl?r123" />
+      </rdf:Seq>
+    </items>
+
+    <textinput rdf:resource="http://meerkat.oreillynet.com" />
+
+  </channel>
+
+  <image rdf:about="http://meerkat.oreillynet.com/icons/meerkat-powered.jpg">
+    <title>Meerkat Powered!</title>
+    <url>http://meerkat.oreillynet.com/icons/meerkat-powered.jpg</url>
+    <link>http://meerkat.oreillynet.com</link>
+  </image>
+
+  <item rdf:about="http://c.moreover.com/click/here.pl?r123">
+    <title>XML: A Disruptive Technology</title> 
+    <link>http://c.moreover.com/click/here.pl?r123</link>
+    <dc:description>
+      XML is placing increasingly heavy loads on the existing technical
+      infrastructure of the Internet.
+    </dc:description>
+    <dc:publisher>The O'Reilly Network</dc:publisher>
+    <dc:creator>Simon St.Laurent (mailto:simonstl@simonstl.com)</dc:creator>
+    <dc:rights>Copyright &#169; 2000 O'Reilly &amp; Associates, Inc.</dc:rights>
+    <dc:subject>XML</dc:subject>
+    <co:name>XML.com</co:name>
+    <co:market>NASDAQ</co:market>
+    <co:symbol>XML</co:symbol>
+  </item> 
+
+  <textinput rdf:about="http://meerkat.oreillynet.com">
+    <title>Search Meerkat</title>
+    <description>Search Meerkat's RSS Database...</description>
+    <name>s</name>
+    <link>http://meerkat.oreillynet.com/</link>
+    <ti:function>search</ti:function>
+    <ti:inputType>regex</ti:inputType>
+  </textinput>
+
+</rdf:RDF>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/delicious.feed
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/delicious.feed	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/delicious.feed	(revision 14676)
@@ -0,0 +1,177 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<rdf:RDF
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns="http://purl.org/rss/1.0/"
+ xmlns:cc="http://web.resource.org/cc/"
+ xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/"
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:syn="http://purl.org/rss/1.0/modules/syndication/"
+ xmlns:admin="http://webns.net/mvcb/"
+>
+<channel rdf:about="http://del.icio.us/tag/greenbelt">
+<title>del.icio.us/tag/greenbelt</title>
+<link>http://del.icio.us/tag/greenbelt</link>
+<description>Text</description>
+<items>
+ <rdf:Seq>
+  <rdf:li rdf:resource="http://www.greenbelt.org.uk/" />
+  <rdf:li rdf:resource="http://www.greenbelt.org.uk/" />
+  <rdf:li rdf:resource="http://www.natuerlichwien.at/rundumadum/dergruenguertel/" />
+  <rdf:li rdf:resource="http://www.flickerweb.co.uk/wiki/index.php/Tank#Seminars" />
+  <rdf:li rdf:resource="http://www.greenbelt.ca/home.htm" />
+  <rdf:li rdf:resource="http://pipwilsonbhp.blogspot.com/" />
+  <rdf:li rdf:resource="http://maggidawn.typepad.com/maggidawn/" />
+  <rdf:li rdf:resource="http://www.johndavies.org/" />
+  <rdf:li rdf:resource="http://jonnybaker.blogs.com/" />
+ </rdf:Seq>
+</items>
+</channel>
+
+<item rdf:about="http://www.greenbelt.org.uk/">
+<dc:title>Greenbelt - Homepage Section</dc:title>
+<link>http://www.greenbelt.org.uk/</link>
+<dc:creator>jonnybaker</dc:creator>
+<dc:date>2005-05-16T16:30:38Z</dc:date>
+<dc:subject>greenbelt</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/greenbelt" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://www.greenbelt.org.uk/">
+<title>Greenbelt festival (uk)</title>
+<link>http://www.greenbelt.org.uk/</link>
+<dc:creator>sssshhhh</dc:creator>
+<dc:date>2005-05-14T18:19:40Z</dc:date>
+<dc:subject>audiology festival gigs greenbelt</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/gigs" />
+    <rdf:li resource="http://del.icio.us/tag/audiology" />
+    <rdf:li resource="http://del.icio.us/tag/festival" />
+    <rdf:li resource="http://del.icio.us/tag/greenbelt" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://www.natuerlichwien.at/rundumadum/dergruenguertel/">
+<title>Natuerlichwien.at - Rundumadum</title>
+<link>http://www.natuerlichwien.at/rundumadum/dergruenguertel/</link>
+<dc:creator>egmilman47</dc:creator>
+<dc:date>2005-05-06T21:33:41Z</dc:date>
+<dc:subject>Austria Vienna Wien greenbelt nature walking</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/Vienna" />
+    <rdf:li resource="http://del.icio.us/tag/Wien" />
+    <rdf:li resource="http://del.icio.us/tag/Austria" />
+    <rdf:li resource="http://del.icio.us/tag/walking" />
+    <rdf:li resource="http://del.icio.us/tag/nature" />
+    <rdf:li resource="http://del.icio.us/tag/greenbelt" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://www.flickerweb.co.uk/wiki/index.php/Tank#Seminars">
+<title>Tank - GBMediaWiki</title>
+<link>http://www.flickerweb.co.uk/wiki/index.php/Tank#Seminars</link>
+<dc:creator>jystewart</dc:creator>
+<dc:date>2005-03-21T22:44:11Z</dc:date>
+<dc:subject>greenbelt</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/greenbelt" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://www.greenbelt.ca/home.htm">
+<title>Greenbelt homepage</title>
+<link>http://www.greenbelt.ca/home.htm</link>
+<dc:creator>Gooberoo</dc:creator>
+<dc:date>2005-03-01T22:43:17Z</dc:date>
+<dc:subject>greenbelt ontario</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/ontario" />
+    <rdf:li resource="http://del.icio.us/tag/greenbelt" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://pipwilsonbhp.blogspot.com/">
+<title>Pip Wilson bhp ...... blog</title>
+<link>http://pipwilsonbhp.blogspot.com/</link>
+<dc:creator>sssshhhh</dc:creator>
+<dc:date>2004-12-27T11:20:51Z</dc:date>
+<dc:subject>Greenbelt friend ideas links thinking weblog</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/Greenbelt" />
+    <rdf:li resource="http://del.icio.us/tag/thinking" />
+    <rdf:li resource="http://del.icio.us/tag/ideas" />
+    <rdf:li resource="http://del.icio.us/tag/links" />
+    <rdf:li resource="http://del.icio.us/tag/friend" />
+    <rdf:li resource="http://del.icio.us/tag/weblog" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://maggidawn.typepad.com/maggidawn/">
+<title>maggi dawn</title>
+<link>http://maggidawn.typepad.com/maggidawn/</link>
+<dc:creator>sssshhhh</dc:creator>
+<dc:date>2004-12-27T11:20:11Z</dc:date>
+<dc:subject>Greenbelt ideas links thinking weblog</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/Greenbelt" />
+    <rdf:li resource="http://del.icio.us/tag/thinking" />
+    <rdf:li resource="http://del.icio.us/tag/ideas" />
+    <rdf:li resource="http://del.icio.us/tag/links" />
+    <rdf:li resource="http://del.icio.us/tag/weblog" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://www.johndavies.org/">
+<title>John Davies</title>
+<link>http://www.johndavies.org/</link>
+<dc:creator>sssshhhh</dc:creator>
+<dc:date>2004-12-27T11:18:37Z</dc:date>
+<dc:subject>Greenbelt ideas links thinking weblog</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/Greenbelt" />
+    <rdf:li resource="http://del.icio.us/tag/thinking" />
+    <rdf:li resource="http://del.icio.us/tag/ideas" />
+    <rdf:li resource="http://del.icio.us/tag/links" />
+    <rdf:li resource="http://del.icio.us/tag/weblog" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+<item rdf:about="http://jonnybaker.blogs.com/">
+<title>jonnybaker</title>
+<link>http://jonnybaker.blogs.com/</link>
+<dc:creator>sssshhhh</dc:creator>
+<dc:date>2004-12-27T11:18:17Z</dc:date>
+<dc:subject>Greenbelt event ideas links resources thinking weblog youth</dc:subject>
+<taxo:topics>
+  <rdf:Bag>
+    <rdf:li resource="http://del.icio.us/tag/Greenbelt" />
+    <rdf:li resource="http://del.icio.us/tag/thinking" />
+    <rdf:li resource="http://del.icio.us/tag/ideas" />
+    <rdf:li resource="http://del.icio.us/tag/links" />
+    <rdf:li resource="http://del.icio.us/tag/weblog" />
+    <rdf:li resource="http://del.icio.us/tag/youth" />
+    <rdf:li resource="http://del.icio.us/tag/event" />
+    <rdf:li resource="http://del.icio.us/tag/resources" />
+  </rdf:Bag>
+</taxo:topics>
+</item>
+
+</rdf:RDF>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/grwifi-atom.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/grwifi-atom.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/grwifi-atom.xml	(revision 14676)
@@ -0,0 +1,120 @@
+<?xml version="1.0" encoding="iso-8859-1"?>
+<feed xmlns="http://www.w3.org/2005/Atom"
+	xmlns:dc="http://purl.org/dc/elements/1.1/" xml:lang="en">
+<title>Updates to Grand Rapids WiFi hotspot details</title>
+<link rel="alternate" type="text/html" href="http://grwifi.net/"/>
+<link rel="self" type="application/atom+xml" href="http://grwifi.net/atom/locations"/>
+<updated>2005-09-01T15:43:01-05:00</updated>
+<subtitle>WiFi Hotspots in Grand Rapids, MI</subtitle>
+<id>http://grwifi.net/atom/locations</id>
+<rights>Creative Commons Attribution-NonCommercial-ShareAlike 2.0 http://creativecommons.org/licenses/by-nc-sa/2.0/ </rights>
+
+
+<entry>
+    <title>Hotspot Details Updated: Sweetwaters</title>
+    <link rel="alternate" type="text/html" href="http://grwifi.net/location/sweetwaters"/>
+    <id>http://grwifi.net/location/sweetwaters</id>
+    <updated>2005-09-01T15:43:01-05:00</updated>
+
+	<summary type="html">
+		The details of the WiFi hotspot at: Sweetwaters have been updated. Find out more at:
+http://grwifi.net/location/sweetwaters
+	</summary>
+
+	<author>
+		<name>James</name>
+		<uri>http://jystewart.net</uri>
+		<email>james@jystewart.net</email>	</author>
+	<dc:subject>wifi hotspot</dc:subject>
+</entry>
+
+<entry>
+    <title>Hotspot Details Updated: Common Ground Coffee Shop</title>
+    <link rel="alternate" type="text/html" href="http://grwifi.net/location/common-ground"/>
+    <id>http://grwifi.net/location/common-ground</id>
+    <updated>2005-09-01T15:42:39-05:00</updated>
+
+	<summary type="html">
+		The details of the WiFi hotspot at: Common Ground Coffee Shop have been updated. Find out more at:
+http://grwifi.net/location/common-ground
+	</summary>
+
+	<author>
+		<name>James</name>
+		<uri>http://jystewart.net</uri>
+		<email>james@jystewart.net</email>	</author>
+	<dc:subject>wifi hotspot</dc:subject>
+</entry>
+
+<entry>
+    <title>Hotspot Details Updated: Grand Rapids Public Library, Main Branch</title>
+    <link rel="alternate" type="text/html" href="http://grwifi.net/location/grpl-main-branch"/>
+    <id>http://grwifi.net/location/grpl-main-branch</id>
+    <updated>2005-09-01T15:42:20-05:00</updated>
+
+	<summary type="html">
+		The details of the WiFi hotspot at: Grand Rapids Public Library, Main Branch have been updated. Find out more at:
+http://grwifi.net/location/grpl-main-branch
+	</summary>
+
+	<author>
+		<name>James</name>
+		<uri>http://jystewart.net</uri>
+		<email>james@jystewart.net</email>	</author>
+	<dc:subject>wifi hotspot</dc:subject>
+</entry>
+
+<entry>
+    <title>Hotspot Details Updated: Four Friends Coffee House</title>
+    <link rel="alternate" type="text/html" href="http://grwifi.net/location/four-friends"/>
+    <id>http://grwifi.net/location/four-friends</id>
+    <updated>2005-09-01T15:41:35-05:00</updated>
+
+	<summary type="html">
+		The details of the WiFi hotspot at: Four Friends Coffee House have been updated. Find out more at:
+http://grwifi.net/location/four-friends
+	</summary>
+
+	<author>
+		<name>James</name>
+		<uri>http://jystewart.net</uri>
+		<email>james@jystewart.net</email>	</author>
+	<dc:subject>wifi hotspot</dc:subject>
+</entry>
+
+<entry>
+    <title>Hotspot Details Updated: Barnes and Noble, Rivertown Crossings</title>
+    <link rel="alternate" type="text/html" href="http://grwifi.net/location/barnes-noble-rivertown"/>
+    <id>http://grwifi.net/location/barnes-noble-rivertown</id>
+    <updated>2005-09-01T15:40:41-05:00</updated>
+
+	<summary type="html">
+		The details of the WiFi hotspot at: Barnes and Noble, Rivertown Crossings have been updated. Find out more at:
+http://grwifi.net/location/barnes-noble-rivertown
+	</summary>
+
+	<author>
+		<name>James</name>
+		<uri>http://jystewart.net</uri>
+		<email>james@jystewart.net</email>	</author>
+	<dc:subject>wifi hotspot</dc:subject>
+</entry>
+
+<entry>
+    <title>Hotspot Details Updated: The Boss Sports Bar &amp; Grille</title>
+    <link rel="alternate" type="text/html" href="http://grwifi.net/location/boss-sports-bar"/>
+    <id>http://grwifi.net/location/boss-sports-bar</id>
+    <updated>2005-09-01T15:40:19-05:00</updated>
+
+	<summary type="html">
+		The details of the WiFi hotspot at: The Boss Sports Bar &amp; Grille have been updated. Find out more at:
+http://grwifi.net/location/boss-sports-bar
+	</summary>
+
+	<author>
+		<name>James</name>
+		<uri>http://jystewart.net</uri>
+		<email>james@jystewart.net</email>	</author>
+	<dc:subject>wifi hotspot</dc:subject>
+</entry>
+</feed>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-simple.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-simple.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-simple.xml	(revision 14676)
@@ -0,0 +1,15 @@
+<?xml version="1.0"?>
+<!DOCTYPE rss SYSTEM "http://my.netscape.com/publish/formats/rss-0.91.dtd">
+<rss version="0.91">
+<channel>
+<language>en</language>
+<description>News and commentary from the cross-platform scripting community.</description>
+<link>http://www.scripting.com/</link>
+<title>Scripting News</title>
+<image>
+<link>http://www.scripting.com/</link>
+<title>Scripting News</title>
+<url>http://www.scripting.com/gifs/tinyScriptingNews.gif</url>
+</image>
+</channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss2sample.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss2sample.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss2sample.xml	(revision 14676)
@@ -0,0 +1,42 @@
+<?xml version="1.0"?>
+<rss version="2.0" xmlns:content="http://purl.org/rss/1.0.modules/content/">
+   <channel>
+      <title>Liftoff News</title>
+      <link>http://liftoff.msfc.nasa.gov/</link>
+      <description>Liftoff to Space Exploration.</description>
+      <language>en-us</language>
+      <pubDate>Tue, 10 Jun 2003 04:00:00 GMT</pubDate>
+      <lastBuildDate>Tue, 10 Jun 2003 09:41:01 GMT</lastBuildDate>
+      <docs>http://blogs.law.harvard.edu/tech/rss</docs>
+      <generator>Weblog Editor 2.0</generator>
+      <managingEditor>editor@example.com</managingEditor>
+      <webMaster>webmaster@example.com</webMaster>
+      <item>
+         <title>Star City</title>
+         <link>http://liftoff.msfc.nasa.gov/news/2003/news-starcity.asp</link>
+         <description>How do Americans get ready to work with Russians aboard the International Space Station? They take a crash course in culture, language and protocol at Russia's &lt;a href="http://howe.iki.rssi.ru/GCTC/gctc_e.htm"&gt;Star City&lt;/a&gt;.</description>
+         <pubDate>Tue, 03 Jun 2003 09:39:21 GMT</pubDate>
+         <guid>http://liftoff.msfc.nasa.gov/2003/06/03.html#item573</guid>
+      </item>
+      <item>
+         <description>Sky watchers in Europe, Asia, and parts of Alaska and Canada will experience a &lt;a href="http://science.nasa.gov/headlines/y2003/30may_solareclipse.htm"&gt;partial eclipse of the Sun&lt;/a&gt; on Saturday, May 31st.</description>
+         <pubDate>Fri, 30 May 2003 11:06:42 GMT</pubDate>
+         <guid>http://liftoff.msfc.nasa.gov/2003/05/30.html#item572</guid>
+      </item>
+      <item>
+         <title>The Engine That Does More</title>
+         <link>http://liftoff.msfc.nasa.gov/news/2003/news-VASIMR.asp</link>
+         <description>Before man travels to Mars, NASA hopes to design new engines that will let us fly through the Solar System more quickly.  The proposed VASIMR engine would do that.</description>
+         <pubDate>Tue, 27 May 2003 08:37:32 GMT</pubDate>
+         <guid>http://liftoff.msfc.nasa.gov/2003/05/27.html#item571</guid>
+		 <content:encoded><![CDATA[<p>Test content</p>]]></content:encoded>
+      </item>
+      <item>
+         <title>Astronauts' Dirty Laundry</title>
+         <link>http://liftoff.msfc.nasa.gov/news/2003/news-laundry.asp</link>
+         <description>Compared to earlier spacecraft, the International Space Station has many luxuries, but laundry facilities are not one of them.  Instead, astronauts have other options.</description>
+         <pubDate>Tue, 20 May 2003 08:56:02 GMT</pubDate>
+         <guid>http://liftoff.msfc.nasa.gov/2003/05/20.html#item570</guid>
+      </item>
+   </channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/illformed_atom10.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/illformed_atom10.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/illformed_atom10.xml	(revision 14676)
@@ -0,0 +1,13 @@
+<!--
+Description: entry author name
+Expect:      bozo and entries[0]['author_detail']['name'] == u'Example author'
+-->
+<feed xmlns="http://www.w3.org/2005/Atom">
+<entry>
+  <author>
+    <name>Example author</name>
+    <email>me@example.com</email>
+    <uri>http://example.com/</uri>
+  </author>
+</entry>
+</feed
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/hoder.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/hoder.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/hoder.xml	(revision 14676)
@@ -0,0 +1,102 @@
+<?xml version="1.0" encoding="utf-8"?>
+<rss version="2.0" 
+  xmlns:dc="http://purl.org/dc/elements/1.1/"
+  xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
+  xmlns:admin="http://webns.net/mvcb/"
+  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
+
+<channel>
+<title>Editor: Myself (Persian)</title>
+<link>http://editormyself.info</link>
+<description>This is a Persian (Farsi) weblog, written by Hossein Derakhshan (aka, Hoder), an Iranian Multimedia designer and a journalist who lives in Toronto since Dec 2000. He also keeps an English weblog with the same name.</description>
+<dc:language>en-us</dc:language>
+<dc:creator>hoder@hotmail.com</dc:creator>
+<dc:date>2005-10-12T19:45:32-05:00</dc:date>
+<admin:generatorAgent rdf:resource="http://www.movabletype.org/?v=3.15" />
+<sy:updatePeriod>hourly</sy:updatePeriod>
+<sy:updateFrequency>1</sy:updateFrequency>
+<sy:updateBase>2000-01-01T12:00+00:00</sy:updateBase>
+
+
+<item>
+<title>لينکدونی‌ | جلسه‌ی امریکن انترپرایز برای تقسیم قومی ایران</title>
+<link>http://www.aei.org/events/type.upcoming,eventID.1166,filter.all/event_detail.asp</link>
+<description>چطور بعضی‌ها فکر می‌کنند دست راستی‌های آمریکا از خامنه‌ای ملی‌گراترند</description>
+<guid isPermaLink="false">14645@http://i.hoder.com/</guid>
+<dc:subject>iran</dc:subject>
+<dc:date>2005-10-12T19:45:32-05:00</dc:date>
+</item>
+
+<item>
+<title>لينکدونی‌ | به صبحانه آگهی بدهید</title>
+<link>http://www.adbrite.com/mb/commerce/purchase_form.php?opid=24346&amp;afsid=1</link>
+<description>خیلی ارزان و راحت است</description>
+<guid isPermaLink="false">14644@http://i.hoder.com/</guid>
+<dc:subject>media/journalism</dc:subject>
+<dc:date>2005-10-12T17:23:15-05:00</dc:date>
+</item>
+
+<item>
+<title>لينکدونی‌ | نیروی انتظامی چگونه تابوهای هم‌جنس‌گرایانه را می‌شکند؛ فرنگوپولیس</title>
+<link>http://farangeopolis.blogspot.com/2005/10/blog-post_08.html</link>
+<description>از پس و پیش و حاشیه‌ی این ماجرا می‌توان یک مستند بی‌نظیر ساخت</description>
+<guid isPermaLink="false">14643@http://i.hoder.com/</guid>
+<dc:subject>soc_popculture</dc:subject>
+<dc:date>2005-10-12T17:06:40-05:00</dc:date>
+</item>
+
+<item>
+<title>لينکدونی‌ | بازتاب توقیف شد</title>
+<link>http://www.baztab.com/news/30201.php</link>
+<description>اگر گفتید یک وب‌سایت را چطور توقیف می‌کنند؟ لابد ماوس‌شان را قایم می‌کنند.</description>
+<guid isPermaLink="false">14642@http://i.hoder.com/</guid>
+<dc:subject>media/journalism</dc:subject>
+<dc:date>2005-10-12T14:41:57-05:00</dc:date>
+</item>
+
+<item>
+<title>لينکدونی‌ | رشد وب در سال 2005 از همیشه بیشتر بوده است&quot; بی.بی.سی</title>
+<link>http://news.bbc.co.uk/2/hi/technology/4325918.stm</link>
+<description></description>
+<guid isPermaLink="false">14640@http://i.hoder.com/</guid>
+<dc:subject>tech</dc:subject>
+<dc:date>2005-10-12T13:04:46-05:00</dc:date>
+</item>
+
+
+
+<item>
+<title>==قرعه کشی گرین کارد به زودی شروع می‌شود==</title>
+<link>http://nice.newsxphotos.biz/05/09/2007_dv_lottery_registration_to_begin_oct_5_14589.php</link>
+<description></description>
+<guid isPermaLink="false">14613@http://vagrantly.com</guid>
+<dc:subject>ads03</dc:subject>
+<dc:date>2005-09-27T04:49:22-05:00</dc:date>
+</item>
+
+
+
+
+
+
+<item>
+<title>پروژه‌ی هاروارد، قدم دوم</title>
+<link>http://editormyself.info/archives/2005/10/051012_014641.shtml</link>
+<description><![CDATA[<p>اگر یادتان باشد <a href="/archives/2005/09/050906_014504.shtml">چند وقت پیش نوشتم</a> که دانشگاه هاروارد پروژه‌ای دارد با نام آواهای جهانی که در آن به وبلاگ‌های غیر انگلیسی‌زبان می‌پردازد. خواشتم که اگر کسی علاقه دارد ایمیل بزند. تعداد زیادی جواب دادند و ابراز علاقه کردند. حالا وقت قدم دوم است.</p>
+
+<p>قدم دوم این است که برای اینکه مسوولین پروژه بتوانند تصمیم بگیرند که با چه کسی کار کنند، می‌خواهند نمونه‌ی کارهای علاقمندان مشارکت در این پرزو‌ه را ببینند.</p>
+
+<p>برای همین از همه‌ی علاقماندان، حتی کسانی که قبلا اعلام آمادگی نکرده بودند، می‌‌خواهم که یک موضوع رایج این روزهای وبلاگستان فارسی را انتخاب کنند و در هفتصد کلمه، به انگلیسی، بنویسند که وبلاگ‌دارهای درباره‌اش چه می‌گویند. لینک به پنج، شش وبلاگ و بازنویسی آنچه آنها از جنبه‌های گوناگون درباره‌ی آن موضوع نوشته‌اند با نقل قول مستقیم از آنها (البته ترجمه شده از فارسی) کافی است. دو سه جمله هم اول کار توضیح دهید که چرا این موضوع مهم است.</p>
+
+<p>متن نمونه را به آدرس ایمیل من hoder@hoder.com و نیز برای افراد زیر تا روز دوشنبه بفرستید:<br />
+ربکا : rmackinnon@cyber.law.harvard.edu<br />
+هیثم: haitham.sabbah@gmail.com</p>]]></description>
+<guid isPermaLink="false">14641@http://editormyself.info</guid>
+<dc:subject>weblog</dc:subject>
+<dc:date>2005-10-12T14:04:23-05:00</dc:date>
+</item>
+
+
+
+</channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-entryonly.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-entryonly.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-entryonly.xml	(revision 14676)
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="utf-8"?>
+<entry xmlns="http://www.w3.org/2005/Atom">
+    <title>Atom draft-07 snapshot</title>
+    <link rel="alternate" type="text/html" 
+     href="http://example.org/2005/04/02/atom"/>
+    <link rel='enclosure' type="audio/mpeg" length="1337"
+     href="http://example.org/audio/ph34r_my_podcast.mp3"/>
+    <id>tag:example.org,2003:3.2397</id>
+    <updated>2005-07-10T12:29:29Z</updated>
+    <published>2003-12-13T08:29:29-04:00</published>
+    <author>
+      <name>Mark Pilgrim</name>
+      <uri>http://example.org/</uri>
+      <email>f8dy@example.com</email>
+    </author>
+    <contributor>
+      <name>Sam Ruby</name>
+    </contributor>
+    <contributor>
+      <name>Joe Gregorio</name>
+    </contributor>
+    <content type="xhtml" xml:lang="en" 
+     xml:base="http://diveintomark.org/">
+      <div xmlns="http://www.w3.org/1999/xhtml">
+        <p><i>[Update: The Atom draft is finished.]</i></p>
+      </div>
+    </content>
+  </entry>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/sixapart-jp.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/sixapart-jp.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/sixapart-jp.xml	(revision 14676)
@@ -0,0 +1,226 @@
+<?xml version="1.0" encoding="utf-8"?>
+<rss version="2.0">
+<channel>
+<title>Six Apart - News</title>
+<link>http://www.sixapart.jp/</link>
+<description></description>
+<language>ja</language>
+<copyright>Copyright 2005</copyright>
+<lastBuildDate>Fri, 07 Oct 2005 19:09:34 +0900</lastBuildDate>
+<generator>http://www.movabletype.org/?v=3.2-ja</generator>
+<docs>http://blogs.law.harvard.edu/tech/rss</docs> 
+
+<item>
+<title>ファイブ・ディーが、Movable Typeでブログプロモーションをスタート</title>
+<description><![CDATA[<p><img alt="MIYAZAWAblog_banner.jpg" src="http://www.sixapart.jp/MIYAZAWAblog_banner.jpg" width="200" height="88" align="right" /><br />
+ファイブ・ディーは、Movable Typeで構築したプロモーション ブログ『宮沢和史 中南米ツアーblog Latin America 2005』を開設しました。</p>
+
+<p>9月21日に開設されたこのブログは、ブラジル、ホンジュラス、ニカラグア、メキシコ、キューバの5か国を巡る「Latin America 2005」ツアーに合わせ、そのツアーの模様を同行マネージャーがレポートしていきます。<br />
+さらに今月2日からは宮沢和史自身が日々録音した声をPodcastingするという点でも、ブログを使ったユニークなプロモーションとなっています。</p>
+
+<p><a href="http://www.five-d.co.jp/miyazawa/jp/blog/la2005/">「宮沢和史 中南米ツアーblog Latin America 2005」</a></p>
+
+<p>※シックス・アパートではこうしたブログを使ったプロモーションに最適な製品をご用意しております。<br />
+<ul><li><a href="/movabletype/">Movable Type</a><br />
+<li><a href="/typepad/typepad_promotion.html">TypePad Promotion</a><br />
+</ul></p>]]></description>
+<link>http://www.sixapart.jp/news/2005/10/07-1909.html</link>
+<guid>http://www.sixapart.jp/news/2005/10/07-1909.html</guid>
+<category>news</category>
+<pubDate>Fri, 07 Oct 2005 19:09:34 +0900</pubDate>
+</item>
+<item>
+<title>Movable Type 3.2日本語版の提供を開始</title>
+<description><![CDATA[<p><img alt="Movable Type Logo" src="/images/mt3-logo-small.gif" width="151" height="37"/></p>
+<p>シックス・アパートは、Movable Type 3.2日本語版の提供を開始いたしました。<br />
+ベータテストにご協力いただいた多くの皆様に、スタッフ一同、心から感謝いたします。</p>
+<p>製品概要など、詳しくは<a href="http://www.sixapart.jp/press_releases/2005/09/29-1529.html" title="Six Apart - News: シックス・アパートが、スパム対策強化の「Movable Type 3.2 日本語版」を提供開始">プレスリリース</a>をご参照下さい。</p>
+<p>ご購入のご検討は、<a href="http://www.sixapart.jp/movabletype/purchase-mt.html">Movable Typeのご購入</a>からどうぞ。</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/29-1530.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/29-1530.html</guid>
+<category>news</category>
+<pubDate>Thu, 29 Sep 2005 15:30:00 +0900</pubDate>
+</item>
+<item>
+<title>シックス・アパートが、スパム対策強化の「Movable Type 3.2 日本語版」を提供開始</title>
+<description><![CDATA[<p>＜プレスリリース資料＞</p>
+<ul>
+  <li><a href="http://www.sixapart.jp/sixapart20050929.pdf">印刷用（PDF版）</a></li>
+</ul>
+<p><strong>シックス・アパートが、スパム対策強化の「Movable Type 3.2 日本語版」を提供開始 ～ スパムの自動判別機能や新ユーザー・インターフェースで、運用管理の機能を強化 ～</strong></p>
+<p>2005年9月29日<br />
+シックス・アパート株式会社</p>
+<p>ブログ・ソフトウェア大手のシックス・アパート株式会社（本社：東京都港区、代表取締役：関 信浩）は、「Movable Type（ムーバブル・タイプ） 3.2 日本語版」(URL：<a href="http://www.sixapart.jp/movabletype/">http://www.sixapart.jp/movabletype/</a>)を9月29日より提供開始いたします。</p>]]></description>
+<link>http://www.sixapart.jp/press_releases/2005/09/29-1529.html</link>
+<guid>http://www.sixapart.jp/press_releases/2005/09/29-1529.html</guid>
+<category>Press Releases</category>
+<pubDate>Thu, 29 Sep 2005 15:29:00 +0900</pubDate>
+</item>
+<item>
+<title>スタッフを募集しています</title>
+<description><![CDATA[<p>シックス・アパートはMovable TypeやTypePadの開発エンジニアなど、スタッフを広く募集しています。具体的な募集職種は次の通りです。</p>
+
+<ul>
+<li><a href="http://www.sixapart.jp/jobs/2005/09/13-0007.html">Movable Type開発エンジニア</a></li>
+<li><a href="http://www.sixapart.jp/jobs/2005/09/13-0004.html">TypePad開発エンジニア</a></li>
+<li><a href="http://www.sixapart.jp/jobs/2005/09/13-0003.html">カスタマーサポート・ディレクター</a></li>
+<li><a href="http://www.sixapart.jp/jobs/2005/09/13-0002.html">マーケティング・広報アシスタント</a></li>
+<li><a href="http://www.sixapart.jp/jobs/2005/09/13-0001.html">開発アシスタント</a></li>
+</ul>
+
+<p>拡大を続ける、日本のブログ市場を積極的にリードする人材を、シックス・アパートは募集しています。上記以外の職種につきましても、お気軽にお問い合わせください。詳しい募集要項や応募方法については、<a href="/jobs/">求人情報のページ</a>をご覧ください。<br />
+</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/27-0906.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/27-0906.html</guid>
+<category>news</category>
+<pubDate>Tue, 27 Sep 2005 09:06:10 +0900</pubDate>
+</item>
+<item>
+<title>サイト接続不具合に関するお詫びと復旧のお知らせ</title>
+<description><![CDATA[<p>9月24日（土）の14:45ごろから、同日18:30ごろまで、シックス・アパート社のウェブサイトが不安定になっており、断続的に接続できない不具合が発生しておりました。このため、この期間中にウェブサイトの閲覧や製品のダウンロードができませんでした。</p>
+
+<p>なお現在は不具合は解消しております。みなさまにご迷惑をおかけしたことをお詫びいたします。</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/26-1000.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/26-1000.html</guid>
+<category>news</category>
+<pubDate>Mon, 26 Sep 2005 10:00:56 +0900</pubDate>
+</item>
+<item>
+<title>企業ブログ向けパッケージ「TypePad Promotion」を新発売</title>
+<description><![CDATA[<p>シックス・アパートは、ウェブログ・サービスTypePadの企業ブログ向けパッケージ「TypePad Promotion」（タイプパッド・プロモーションの発売を10月下旬から開始いたします。</p>
+
+<p>詳しくは、<a href="http://www.sixapart.jp/press_releases/2005/09/20-1500.html" title="プレスリリース: 「TypePad Promotion」新発売">プレスリリース</a>をご参照下さい。</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/20-1500.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/20-1500.html</guid>
+<category>news</category>
+<pubDate>Tue, 20 Sep 2005 15:00:01 +0900</pubDate>
+</item>
+<item>
+<title>シックス・アパートが、法人向けブログパッケージ「TypePad Promotion」を発売</title>
+<description><![CDATA[<p>＜プレスリリース資料＞<br />
+<a href="http://www.sixapart.jp/sixapart20050920.pdf">印刷用（PDF版）</a></p>
+
+<p><br />
+<strong>シックス・アパートが、法人向けブログパッケージ「TypePad Promotion」を発売<br />
+～PR/IRサイトやキャンペーンサイトなど企業のプロモーションニーズに特化～<br />
+</strong><br />
+2005年9月20日<br />
+シックス・アパート株式会社</p>
+
+<p>ブログ・サービス大手のシックス・アパート株式会社（本社：東京都港区、代表取締役：関 信浩）は、法人向けプロモーションブログ・パッケージ「TypePad Promotion（タイプパッド・プロモーション）」(URL：<a href="http://www.sixapart.jp/typepad/typepad_promotion.html">http://www.sixapart.jp/typepad/typepad_promotion.html</a>)を10月下旬より販売開始いたします。</p>]]></description>
+<link>http://www.sixapart.jp/press_releases/2005/09/20-1500.html</link>
+<guid>http://www.sixapart.jp/press_releases/2005/09/20-1500.html</guid>
+<category>Press Releases</category>
+<pubDate>Tue, 20 Sep 2005 15:00:00 +0900</pubDate>
+</item>
+<item>
+<title>Six [days] Apart Week</title>
+<description><![CDATA[<p>本日、9月16日はSix Apartの創業者ミナ・トロットの誕生日です。<br />
+私たちの会社は、創業者のトロット夫妻（ベンとミナ）の誕生日が、6日離れていることからSix  [days] Apart →Six Apartという風に名付けられています。本日から22日までの6日間を社名の由来となる　Six　[days] Apart Weekとして、私たちのプロダクトをご紹介させていただきます。</p>
+
+<p>今日は、ブログ・サービスのTypePad（タイプパッド）をご紹介します。<br />
+<img alt="tp-logo.gif" src="http://www.sixapart.jp/tp-logo.gif" width="227" height="52" /></p>
+
+<p>TypePadは、米国PC MAGAZINE誌の2003年EDITOR'S CHOICE とBEST OF THE YEARに選ばれております。<br />
+<img alt="pcmag-ad.gif" src="http://www.sixapart.jp/pcmag-ad.gif" width="297" height="100" /><br />
+</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/16-1941.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/16-1941.html</guid>
+<category>news</category>
+<pubDate>Fri, 16 Sep 2005 19:41:47 +0900</pubDate>
+</item>
+<item>
+<title>ハイパーワークスが商用フォントを利用できるMovable Typeホスティングサービスを開始</title>
+<description><![CDATA[<p>ソフト開発会社の<a href="http://www.hyperwrx.co.jp/">有限会社ハイパーワークス</a>は、商用フォントなど多彩なフォントをブログ上で利用できるブログ･サービス「<a href="http://glyph-on.jp/">Glyph-On!（グリフォン） Movable Type ホスティング サービス</a>｣の提供を開始しました。<br />
+</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/14-1700.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/14-1700.html</guid>
+<category>news</category>
+<pubDate>Wed, 14 Sep 2005 17:00:00 +0900</pubDate>
+</item>
+<item>
+<title>Movable Type開発エンジニアの募集</title>
+<description><![CDATA[<p>
+勤務形態: フルタイム<br />
+勤務地: 東京 (赤坂)<br />
+職種: ソフトウェア・エンジニア<br />
+職務内容: Movable Typeの開発業務全般<br />
+募集人数: 若干名
+</p>]]></description>
+<link>http://www.sixapart.jp/jobs/2005/09/13-0007.html</link>
+<guid>http://www.sixapart.jp/jobs/2005/09/13-0007.html</guid>
+<category>Jobs</category>
+<pubDate>Tue, 13 Sep 2005 00:07:00 +0900</pubDate>
+</item>
+<item>
+<title>TypePad開発エンジニアの募集</title>
+<description><![CDATA[<p>
+勤務形態: フルタイム<br />
+勤務地: 東京 (赤坂)<br />
+職種: アプリケーション・エンジニア<br />
+職務内容: TypePadのカスタマイズ、周辺開発<br />
+募集人数: 若干名
+</p>]]></description>
+<link>http://www.sixapart.jp/jobs/2005/09/13-0004.html</link>
+<guid>http://www.sixapart.jp/jobs/2005/09/13-0004.html</guid>
+<category>Jobs</category>
+<pubDate>Tue, 13 Sep 2005 00:04:00 +0900</pubDate>
+</item>
+<item>
+<title>カスタマーサポート・ディレクターの募集</title>
+<description><![CDATA[<p>勤務形態: フルタイム<br />
+勤務地: 東京（赤坂）<br />
+職種: カスタマーサポート・ディレクター<br />
+職務内容: TypePadやMovable Typeのカスタマーサポート業務の統括<br />
+募集人数: 若干名
+</p>
+]]></description>
+<link>http://www.sixapart.jp/jobs/2005/09/13-0003.html</link>
+<guid>http://www.sixapart.jp/jobs/2005/09/13-0003.html</guid>
+<category>Jobs</category>
+<pubDate>Tue, 13 Sep 2005 00:03:30 +0900</pubDate>
+</item>
+<item>
+<title>アルバイト（マーケティング・広報アシスタント）の募集</title>
+<description><![CDATA[<p>勤務形態: アルバイト<br />
+勤務地: 東京（港区）<br />
+職種：マーケティング・PRのアシスタント業務<br />
+募集人数: 若干名<br />
+時給：1000円～（但し、試用期間終了後に応相談）。交通費支給<br />
+時間：平日10時30分～18時30分まで。週3日以上(応相談）<br />
+</p>]]></description>
+<link>http://www.sixapart.jp/jobs/2005/09/13-0002.html</link>
+<guid>http://www.sixapart.jp/jobs/2005/09/13-0002.html</guid>
+<category>Jobs</category>
+<pubDate>Tue, 13 Sep 2005 00:02:00 +0900</pubDate>
+</item>
+<item>
+<title>アルバイト（開発アシスタント）の募集</title>
+<description><![CDATA[<p>勤務形態: アルバイト<br />
+勤務地: 東京（港区）<br />
+職種： アプリケーション開発のアシスタント業務<br />
+募集人数: 若干名<br />
+時給：1000円～（但し、試用期間終了後に応相談）。交通費支給<br />
+時間：平日10時30分～18時30分まで。週3日以上(応相談）
+</p>]]></description>
+<link>http://www.sixapart.jp/jobs/2005/09/13-0001.html</link>
+<guid>http://www.sixapart.jp/jobs/2005/09/13-0001.html</guid>
+<category>Jobs</category>
+<pubDate>Tue, 13 Sep 2005 00:01:00 +0900</pubDate>
+</item>
+<item>
+<title>TypePad Japan がバージョンアップしました。</title>
+<description><![CDATA[<p><a href="http://www.sixapart.jp/typepad/">「TypePad Japan（タイプパッドジャパン）」</a>において、本日、「TypePad 1.6 日本語版」へのバージョンアップを行いました。最新版となる「TypePad 1.6 日本語版」では、ブログデザインの機能強化、ポッドキャスティング対応、モブログ対応に加え、今回新たに大幅な容量アップが行われております。皆様、新しくなった<a href="http://www.sixapart.jp/typepad/">TypePad Japan</a>にどうぞご期待ください。</p>
+
+<p>なお、TypePadの携帯対応強化に関しましては、本日よりTypePad Japanのお客様を対象にオープン・ベータを開始しております。</p>
+
+<p>2005年9月5日発表のTypePad日本語版 1.6プレスリリースは<a href="http://www.sixapart.jp/press_releases/2005/09/05-1420.html">こちら</a>をご覧下さい。</p>]]></description>
+<link>http://www.sixapart.jp/news/2005/09/12-1953.html</link>
+<guid>http://www.sixapart.jp/news/2005/09/12-1953.html</guid>
+<category>news</category>
+<pubDate>Mon, 12 Sep 2005 19:53:07 +0900</pubDate>
+</item>
+
+
+</channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/technorati.feed
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/technorati.feed	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/technorati.feed	(revision 14676)
@@ -0,0 +1,54 @@
+<?xml version="1.0" encoding="utf-8"?>
+<rss version="2.0"
+    xmlns:tapi="http://api.technorati.com/dtd/tapi-002.xml">
+    <channel>
+        <title>[Technorati] Tag results for greenbelt</title>
+        <link>http://www.technorati.com/tag/greenbelt</link>
+        <description>Posts tagged with "greenbelt" on Technorati.</description>
+        <pubDate>Mon, 08 Aug 2005 15:15:08 GMT</pubDate>
+        <category domain="http://www.technorati.com/tag">greenbelt</category>
+        <tapi:inboundblogs>2</tapi:inboundblogs>
+        <tapi:inboundlinks>2</tapi:inboundlinks>
+        <cloud domain="rpc.sys.com" port="80" path="/RPC2" registerProcedure="myCloud.rssPleaseNotify" protocol="xml-rpc" />
+        <generator>Technorati v1.0</generator>
+        <image>
+            <url>http://static.technorati.com/pix/logos/logo_reverse_sm.gif</url>
+            <title>Technorati logo</title>
+            <link>http://www.technorati.com</link>
+        </image>
+        <skipHours>
+            <hour>1</hour>
+            <hour>7</hour>
+            <hour>9</hour>
+        </skipHours>
+        <webMaster>support@technorati.com (Technorati Support)</webMaster>
+        <docs>http://blogs.law.harvad.edu/tech/rss</docs>
+        <ttl>60</ttl>
+        <item>
+            <title>Greenbelt</title>
+            <link>http://maggidawn.typepad.com/maggidawn/2005/07/greenbelt.html</link>
+            <description>So if the plan goes according to plan (!)... I'll be speaking at Greenbelt at these times: Slot 1...</description>
+            <guid isPermaLink="true">http://maggidawn.typepad.com/maggidawn/2005/07/greenbelt.html</guid>
+            <pubDate>Mon, 18 Jul 2005 02:11:42 GMT</pubDate>
+            <category>James</category>
+            <tapi:linkcreated>2005-07-11 02:08:12</tapi:linkcreated>
+            <comments>http://www.technorati.com/cosmos/search.html?url=http%3A%2F%2Fmaggidawn.typepad.com%2Fmaggidawn%2F2005%2F07%2Fgreenbelt.html</comments>
+            <tapi:inboundblogs>190</tapi:inboundblogs>
+            <tapi:inboundlinks>237</tapi:inboundlinks>
+            <source url="http://maggidawn.typepad.com/maggidawn/index.rdf">maggi dawn</source>
+        </item>
+
+        <item>
+            <title>Walking along the Greenbelt</title>
+            <link>http://pictureshomeless.blogspot.com/2005/06/walking-along-greenbelt.html</link>
+            <description>[IMG] Photo of homeless man walking near the greenbelt in Boise, Idaho Tags: photo homeless greenbelt Boise Idaho picture</description>
+            <guid isPermaLink="true">http://pictureshomeless.blogspot.com/2005/06/walking-along-greenbelt.html</guid>
+            <pubDate>Tue, 28 Jun 2005 01:41:24 GMT</pubDate>
+            <tapi:linkcreated>2005-06-26 17:24:03</tapi:linkcreated>
+            <comments>http://www.technorati.com/cosmos/search.html?url=http%3A%2F%2Fpictureshomeless.blogspot.com%2F2005%2F06%2Fwalking-along-greenbelt.html</comments>
+            <tapi:inboundblogs>2</tapi:inboundblogs>
+            <tapi:inboundlinks>2</tapi:inboundlinks>
+        </item>
+
+    </channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-international.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-international.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-international.xml	(revision 14676)
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="EuC-JP"?>  
+<!DOCTYPE rss SYSTEM "http://my.netscape.com/publish/formats/rss-0.91.dtd">
+<rss version="0.91">
+<channel>
+<title>è†®ŸÛë´é´Ì´×´è´ŒÁ¹´Õ</title>
+<link>http://www.mozilla.org</link>
+<description>è†®ŸÛë´é´Ì´×´è´ŒÁ¹´Õ</description>
+<language>ja</language>  <!-- tagged as Japanese content -->
+<item>
+<title>NYÒ™Á¢¸»ÌêÛì15285.25´ƒ´‘Á£´Û´—´ÀÁ¹´ê´Ì´éÒ™Ûì¡êçÒÕ‰ÌêÁ£</title>
+<link>http://www.mozilla.org/status/</link>
+<description>This is an item description...</description>
+</item>
+<item>
+<title>‚§±Çç¡ËßÛÂÒéøÓ¸Á£Ë²®Ÿè†Ûèå±ÇÌ’¡Íæ—éøë‡Á£</title>
+<link>http://www.mozilla.org/status/</link>
+<description>This is an item description...</description>
+</item>
+<item>
+<title>ËÜË”ïÌëÈšÁ¢È†Ë§æàÀè±ŽË‰Û‚Á¢Ë‚åÜ¼šÛ˜íËüËÁ£</title>
+<link>http://www.mozilla.org/status/</link>
+<description>This is an item description...</description>
+</item>
+<item>
+<title>2000‚øíŠåÁ¢«‘¦éÛë¹ÛçéÛ§ÛÂè†ÒæÓ¸Á£Ì¾«…æ—ÕÝéøƒ¸Á£</title>
+<link>http://www.mozilla.org/status/</link>
+<description>This is an item description...</description>
+</item>
+</channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-complete.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-complete.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss091-complete.xml	(revision 14676)
@@ -0,0 +1,47 @@
+<?xml version="1.0"?>
+<!DOCTYPE rss SYSTEM "http://my.netscape.com/publish/formats/rss-0.91.dtd">
+<rss version="0.91">
+<channel>
+<copyright>Copyright 1997-1999 UserLand Software, Inc.</copyright>
+<pubDate>Thu, 08 Jul 1999 07:00:00 GMT</pubDate>
+<lastBuildDate>Thu, 08 Jul 1999 16:20:26 GMT</lastBuildDate>
+<docs>http://my.userland.com/stories/storyReader$11</docs>
+<description>News and commentary from the cross-platform scripting community.</description>
+<link>http://www.scripting.com/</link>
+<title>Scripting News</title>
+<image>
+<link>http://www.scripting.com/</link>
+<title>Scripting News</title>
+<url>http://www.scripting.com/gifs/tinyScriptingNews.gif</url>
+<height>40</height>
+<width>78</width>
+<description>What is this used for?</description>
+</image>
+<managingEditor>dave@userland.com (Dave Winer)</managingEditor>
+<webMaster>dave@userland.com (Dave Winer)</webMaster>
+<language>en-us</language>
+<skipHours>
+<hour>6</hour>
+<hour>7</hour>
+<hour>8</hour>
+<hour>9</hour>
+<hour>10</hour>
+<hour>11</hour>
+</skipHours>
+<skipDays>
+<day>Sunday</day>
+</skipDays>
+<rating>(PICS-1.1 "http://www.rsac.org/ratingsv01.html" l gen true comment "RSACi North America Server" for "http://www.rsac.org" on "1996.04.16T08:15-0500" r (n 0 s 0 v 0 l 0))</rating>
+<item>
+<title>stuff</title>
+<link>http://bar</link>
+<description>This is an article about some stuff</description>
+</item>
+<textinput>
+<title>Search Now!</title>
+<description>Enter your search &lt;terms&gt;</description>
+<name>find</name>
+<link>http://my.site.com/search.cgi</link>
+</textinput>
+</channel>
+</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-example1.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-example1.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-example1.xml	(revision 14676)
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<feed xmlns="http://www.w3.org/2005/Atom">
+
+ <title>Example Feed</title>
+ <link href="http://example.org/"/>
+ <updated>2003-12-13T18:30:02Z</updated>
+ <author>
+   <name>John Doe</name>
+ </author>
+ <id>urn:uuid:60a76c80-d399-11d9-b93C-0003939e0af6</id>
+
+ <entry>
+   <title>Atom-Powered Robots Run Amok</title>
+   <link href="http://example.org/2003/12/13/atom03"/>
+   <id>urn:uuid:1225c695-cfb8-4ebb-aaaa-80da344efa6a</id>
+   <updated>2003-12-13T18:30:02Z</updated>
+   <summary>Some text.</summary>
+ </entry>
+
+</feed>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-example2.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-example2.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/atom10-example2.xml	(revision 14676)
@@ -0,0 +1,45 @@
+<?xml version="1.0" encoding="utf-8"?>
+   <feed xmlns="http://www.w3.org/2005/Atom">
+     <title type="text">dive into mark</title>
+     <subtitle type="html">
+       A &lt;em&gt;lot&lt;/em&gt; of effort
+       went into making this effortless
+     </subtitle>
+     <updated>2005-07-31T12:29:29Z</updated>
+     <id>tag:example.org,2003:3</id>
+     <link rel="alternate" type="text/html"
+      hreflang="en" href="http://example.org/"/>
+     <link rel="self" type="application/atom+xml"
+      href="http://example.org/feed.atom"/>
+     <rights>Copyright (c) 2003, Mark Pilgrim</rights>
+     <generator uri="http://www.example.com/" version="1.0">
+       Example Toolkit
+     </generator>
+     <entry>
+       <title>Atom draft-07 snapshot</title>
+       <link rel="alternate" type="text/html"
+        href="http://example.org/2005/04/02/atom"/>
+       <link rel='enclosure' type="audio/mpeg" length="1337"
+        href="http://example.org/audio/ph34r_my_podcast.mp3"/>
+       <id>tag:example.org,2003:3.2397</id>
+       <updated>2005-07-31T12:29:29Z</updated>
+       <published>2003-12-13T08:29:29-04:00</published>
+       <author>
+         <name>Mark Pilgrim</name>
+         <uri>http://example.org/</uri>
+         <email>f8dy@example.com</email>
+       </author>
+       <contributor>
+         <name>Sam Ruby</name>
+       </contributor>
+       <contributor>
+         <name>Joe Gregorio</name>
+       </contributor>
+       <content type="xhtml" xml:lang="en"
+        xml:base="http://diveintomark.org/">
+         <div xmlns="http://www.w3.org/1999/xhtml">
+           <p><i>[Update: The Atom draft is finished.]</i></p>
+         </div>
+       </content>
+     </entry>
+   </feed>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/flickr.feed
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/flickr.feed	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/flickr.feed	(revision 14676)
@@ -0,0 +1,184 @@
+<?xml version="1.0" encoding="utf-8" standalone="yes"?>
+<feed version="0.3" xmlns="http://purl.org/atom/ns#" 
+    xmlns:dc="http://purl.org/dc/elements/1.1/">
+
+	<title>jamesstewart - Everyone's Tagged Photos</title>
+	<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/tags/jamesstewart/"/>
+	<link rel="icon" type="image/jpeg" href="http://www.flickr.com/images/buddyicon.jpg"/>
+	<info type="text/html" mode="escaped">A feed of jamesstewart - Everyone's Tagged Photos</info>
+	<modified>2005-08-01T18:50:26Z</modified>
+	<generator url="http://www.flickr.com/">Flickr</generator>
+
+	<entry>
+		<title>Oma and James</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/30484029@N00/30367516/"/>
+		<link rel='enclosure' type="application/xml" href="http://james.anthropiccollective.org" />
+		<id>tag:flickr.com,2004:/photo/30367516</id>
+		<issued>2005-08-01T18:50:26Z</issued>
+		<modified>2005-08-01T18:50:26Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/30484029@N00/&quot;&gt;kstewart&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/30484029@N00/30367516/&quot; title=&quot;Oma and James&quot;&gt;&lt;img src=&quot;http://photos23.flickr.com/30367516_1f685a16e8_m.jpg&quot; width=&quot;240&quot; height=&quot;180&quot; alt=&quot;Oma and James&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+&lt;p&gt;I have a beautiful Oma and a gorgeous husband.&lt;/p&gt;</content>
+		<author>
+			<name>kstewart</name>
+			<url>http://www.flickr.com/people/30484029@N00/</url>
+		</author>
+				<dc:subject>jamesstewart oma stoelfamily</dc:subject>
+	</entry>
+	<entry>
+		<title></title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/buddscreek/21376174/"/>
+		<id>tag:flickr.com,2004:/photo/21376174</id>
+		<issued>2005-06-25T02:00:35Z</issued>
+		<modified>2005-06-25T02:00:35Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/buddscreek/&quot;&gt;Lan Rover&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/buddscreek/21376174/&quot; title=&quot;&quot;&gt;&lt;img src=&quot;http://photos17.flickr.com/21376174_4314fd8d5c_m.jpg&quot; width=&quot;240&quot; height=&quot;160&quot; alt=&quot;&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+&lt;p&gt;AMA Motocross Championship 2005, Budds Creek, Maryland&lt;/p&gt;</content>
+		<author>
+			<name>Lan Rover</name>
+			<url>http://www.flickr.com/people/buddscreek/</url>
+		</author>
+				<dc:subject>amamotocrosschampionship buddscreek maryland 2005 fathersday motocrossnational rickycarmichael 259 jamesstewart 4</dc:subject>
+	</entry>
+	<entry>
+		<title></title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/buddscreek/21375650/"/>
+		<id>tag:flickr.com,2004:/photo/21375650</id>
+		<issued>2005-06-25T01:56:24Z</issued>
+		<modified>2005-06-25T01:56:24Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/buddscreek/&quot;&gt;Lan Rover&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/buddscreek/21375650/&quot; title=&quot;&quot;&gt;&lt;img src=&quot;http://photos16.flickr.com/21375650_5c60e0dab1_m.jpg&quot; width=&quot;240&quot; height=&quot;160&quot; alt=&quot;&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>Lan Rover</name>
+			<url>http://www.flickr.com/people/buddscreek/</url>
+		</author>
+				<dc:subject>amamotocrosschampionship buddscreek maryland 2005 fathersday motocrossnational 259 jamesstewart</dc:subject>
+	</entry>
+	<entry>
+		<title></title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/buddscreek/21375345/"/>
+		<id>tag:flickr.com,2004:/photo/21375345</id>
+		<issued>2005-06-25T01:54:11Z</issued>
+		<modified>2005-06-25T01:54:11Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/buddscreek/&quot;&gt;Lan Rover&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/buddscreek/21375345/&quot; title=&quot;&quot;&gt;&lt;img src=&quot;http://photos15.flickr.com/21375345_4205fdd22b_m.jpg&quot; width=&quot;160&quot; height=&quot;240&quot; alt=&quot;&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>Lan Rover</name>
+			<url>http://www.flickr.com/people/buddscreek/</url>
+		</author>
+				<dc:subject>amamotocrosschampionship buddscreek maryland 2005 fathersday motocrossnational 259 jamesstewart</dc:subject>
+	</entry>
+	<entry>
+		<title>Lunch with Kari &amp; James, café in the crypt of St Martin in the fields</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/fidothe/16516618/"/>
+		<id>tag:flickr.com,2004:/photo/16516618</id>
+		<issued>2005-05-30T21:56:39Z</issued>
+		<modified>2005-05-30T21:56:39Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/fidothe/&quot;&gt;fidothe&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/fidothe/16516618/&quot; title=&quot;Lunch with Kari &amp;amp; James, café in the crypt of St Martin in the fields&quot;&gt;&lt;img src=&quot;http://photos14.flickr.com/16516618_afaa4a395e_m.jpg&quot; width=&quot;240&quot; height=&quot;180&quot; alt=&quot;Lunch with Kari &amp;amp; James, café in the crypt of St Martin in the fields&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>fidothe</name>
+			<url>http://www.flickr.com/people/fidothe/</url>
+		</author>
+				<dc:subject>nokia7610 london stmartininthefields clarepatterson jamesstewart parvinstewart jimstewart susanstewart</dc:subject>
+	</entry>
+	<entry>
+		<title>Stewart keeping it low over the obstacle.</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/pqbon/10224728/"/>
+		<id>tag:flickr.com,2004:/photo/10224728</id>
+		<issued>2005-04-21T07:30:29Z</issued>
+		<modified>2005-04-21T07:30:29Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/pqbon/&quot;&gt;pqbon&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/pqbon/10224728/&quot; title=&quot;Stewart keeping it low over the obstacle.&quot;&gt;&lt;img src=&quot;http://photos7.flickr.com/10224728_b756341957_m.jpg&quot; width=&quot;240&quot; height=&quot;180&quot; alt=&quot;Stewart keeping it low over the obstacle.&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>pqbon</name>
+			<url>http://www.flickr.com/people/pqbon/</url>
+		</author>
+				<dc:subject>ama hangtown motocross jamesstewart bubba</dc:subject>
+	</entry>
+	<entry>
+		<title>king james stewart</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/jjlook/7152910/"/>
+		<id>tag:flickr.com,2004:/photo/7152910</id>
+		<issued>2005-03-22T21:53:37Z</issued>
+		<modified>2005-03-22T21:53:37Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/jjlook/&quot;&gt;jj look&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/jjlook/7152910/&quot; title=&quot;king james stewart&quot;&gt;&lt;img src=&quot;http://photos7.flickr.com/7152910_a02ab5a750_m.jpg&quot; width=&quot;180&quot; height=&quot;240&quot; alt=&quot;king james stewart&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+&lt;p&gt;11th&lt;/p&gt;</content>
+		<author>
+			<name>jj look</name>
+			<url>http://www.flickr.com/people/jjlook/</url>
+		</author>
+				<dc:subject>dilomar05 eastside austin texas 78702 kingjames stewart jamesstewart borrowed</dc:subject>
+	</entry>
+	<entry>
+		<title>It's a Grind, downtown Grand Rapids (James, Susan, Jim, Harv, Lawson)</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/fidothe/1586562/"/>
+		<id>tag:flickr.com,2004:/photo/1586562</id>
+		<issued>2004-11-20T09:34:28Z</issued>
+		<modified>2004-11-20T09:34:28Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/fidothe/&quot;&gt;fidothe&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/fidothe/1586562/&quot; title=&quot;It's a Grind, downtown Grand Rapids (James, Susan, Jim, Harv, Lawson)&quot;&gt;&lt;img src=&quot;http://photos2.flickr.com/1586562_0bc5313a3e_m.jpg&quot; width=&quot;240&quot; height=&quot;180&quot; alt=&quot;It's a Grind, downtown Grand Rapids (James, Susan, Jim, Harv, Lawson)&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>fidothe</name>
+			<url>http://www.flickr.com/people/fidothe/</url>
+		</author>
+				<dc:subject>holiday grandrapids jamesstewart</dc:subject>
+	</entry>
+	<entry>
+		<title>It's a Grind, downtown Grand Rapids (James, Susan, Jim, Harv, Lawson)</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/fidothe/1586539/"/>
+		<id>tag:flickr.com,2004:/photo/1586539</id>
+		<issued>2004-11-20T09:28:16Z</issued>
+		<modified>2004-11-20T09:28:16Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/fidothe/&quot;&gt;fidothe&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/fidothe/1586539/&quot; title=&quot;It's a Grind, downtown Grand Rapids (James, Susan, Jim, Harv, Lawson)&quot;&gt;&lt;img src=&quot;http://photos2.flickr.com/1586539_c51e5f2e7a_m.jpg&quot; width=&quot;240&quot; height=&quot;180&quot; alt=&quot;It's a Grind, downtown Grand Rapids (James, Susan, Jim, Harv, Lawson)&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>fidothe</name>
+			<url>http://www.flickr.com/people/fidothe/</url>
+		</author>
+				<dc:subject>holiday grandrapids jamesstewart</dc:subject>
+	</entry>
+	<entry>
+		<title>It's a Grind, James and Jim can't decide)</title>
+		<link rel="alternate" type="text/html" href="http://www.flickr.com/photos/fidothe/1586514/"/>
+		<id>tag:flickr.com,2004:/photo/1586514</id>
+		<issued>2004-11-20T09:25:05Z</issued>
+		<modified>2004-11-20T09:25:05Z</modified>
+		<content type="text/html" mode="escaped">&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/people/fidothe/&quot;&gt;fidothe&lt;/a&gt; posted a photo:&lt;/p&gt;
+
+&lt;p&gt;&lt;a href=&quot;http://www.flickr.com/photos/fidothe/1586514/&quot; title=&quot;It's a Grind, James and Jim can't decide)&quot;&gt;&lt;img src=&quot;http://photos2.flickr.com/1586514_733c2dfa3e_m.jpg&quot; width=&quot;240&quot; height=&quot;180&quot; alt=&quot;It's a Grind, James and Jim can't decide)&quot; style=&quot;border: 1px solid #000000;&quot; /&gt;&lt;/a&gt;&lt;/p&gt;
+
+</content>
+		<author>
+			<name>fidothe</name>
+			<url>http://www.flickr.com/people/fidothe/</url>
+		</author>
+				<dc:subject>holiday grandrapids jamesstewart johnkentish</dc:subject>
+	</entry>
+
+</feed>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss092-sample.xml
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss092-sample.xml	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/samples/rss092-sample.xml	(revision 14676)
@@ -0,0 +1,103 @@
+<?xml version="1.0"?>
+<!-- RSS generation done by 'Radio UserLand' on Fri, 13 Apr 2001 19:23:02 GMT -->
+<rss version="0.92">
+	<channel>
+		<title>Dave Winer: Grateful Dead</title>
+		<link>http://www.scripting.com/blog/categories/gratefulDead.html</link>
+		<description>A high-fidelity Grateful Dead song every day. This is where we&apos;re experimenting with enclosures on RSS news items that download when you&apos;re not using your computer. If it works (it will) it will be the end of the Click-And-Wait multimedia experience on the Internet. </description>
+		<lastBuildDate>Fri, 13 Apr 2001 19:23:02 GMT</lastBuildDate>
+		<docs>http://backend.userland.com/rss092</docs>
+		<managingEditor>dave@userland.com (Dave Winer)</managingEditor>
+		<webMaster>dave@userland.com (Dave Winer)</webMaster>
+		<cloud domain="data.ourfavoritesongs.com" port="80" path="/RPC2" registerProcedure="ourFavoriteSongs.rssPleaseNotify" protocol="xml-rpc"/>
+		<item>
+			<description>It&apos;s been a few days since I added a song to the Grateful Dead channel. Now that there are all these new Radio users, many of whom are tuned into this channel (it&apos;s #16 on the hotlist of upstreaming Radio users, there&apos;s no way of knowing how many non-upstreaming users are subscribing, have to do something about this..). Anyway, tonight&apos;s song is a live version of Weather Report Suite from Dick&apos;s Picks Volume 7. It&apos;s wistful music. Of course a beautiful song, oft-quoted here on Scripting News. &lt;i&gt;A little change, the wind and rain.&lt;/i&gt;
+</description>
+			<enclosure url="http://www.scripting.com/mp3s/weatherReportDicksPicsVol7.mp3" length="6182912" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>Kevin Drennan started a &lt;a href=&quot;http://deadend.editthispage.com/&quot;&gt;Grateful Dead Weblog&lt;/a&gt;. Hey it&apos;s cool, he even has a &lt;a href=&quot;http://deadend.editthispage.com/directory/61&quot;&gt;directory&lt;/a&gt;. &lt;i&gt;A Frontier 7 feature.&lt;/i&gt;</description>
+			<source url="http://scriptingnews.userland.com/xml/scriptingNews2.xml">Scripting News</source>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://arts.ucsc.edu/GDead/AGDL/other1.html&quot;&gt;The Other One&lt;/a&gt;, live instrumental, One From The Vault. Very rhythmic very spacy, you can listen to it many times, and enjoy something new every time.</description>
+			<enclosure url="http://www.scripting.com/mp3s/theOtherOne.mp3" length="6666097" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>This is a test of a change I just made. Still diggin..</description>
+			</item>
+		<item>
+			<description>The HTML rendering almost &lt;a href=&quot;http://validator.w3.org/check/referer&quot;&gt;validates&lt;/a&gt;. Close. Hey I wonder if anyone has ever published a style guide for ALT attributes on images? What are you supposed to say in the ALT attribute? I sure don&apos;t know. If you&apos;re blind send me an email if u cn rd ths. </description>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://www.cs.cmu.edu/~mleone/gdead/dead-lyrics/Franklin&apos;s_Tower.txt&quot;&gt;Franklin&apos;s Tower&lt;/a&gt;, a live version from One From The Vault.</description>
+			<enclosure url="http://www.scripting.com/mp3s/franklinsTower.mp3" length="6701402" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>Moshe Weitzman says Shakedown Street is what I&apos;m lookin for for tonight. I&apos;m listening right now. It&apos;s one of my favorites. &quot;Don&apos;t tell me this town ain&apos;t got no heart.&quot; Too bright. I like the jazziness of Weather Report Suite. Dreamy and soft. How about The Other One? &quot;Spanish lady come to me..&quot;</description>
+			<source url="http://scriptingnews.userland.com/xml/scriptingNews2.xml">Scripting News</source>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://www.scripting.com/mp3s/youWinAgain.mp3&quot;&gt;The news is out&lt;/a&gt;, all over town..&lt;p&gt;
+You&apos;ve been seen, out runnin round. &lt;p&gt;
+The lyrics are &lt;a href=&quot;http://www.cs.cmu.edu/~mleone/gdead/dead-lyrics/You_Win_Again.txt&quot;&gt;here&lt;/a&gt;, short and sweet. &lt;p&gt;
+&lt;i&gt;You win again!&lt;/i&gt;
+</description>
+			<enclosure url="http://www.scripting.com/mp3s/youWinAgain.mp3" length="3874816" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://www.getlyrics.com/lyrics/grateful-dead/wake-of-the-flood/07.htm&quot;&gt;Weather Report Suite&lt;/a&gt;: &quot;Winter rain, now tell me why, summers fade, and roses die? The answer came. The wind and rain. Golden hills, now veiled in grey, summer leaves have blown away. Now what remains? The wind and rain.&quot;</description>
+			<enclosure url="http://www.scripting.com/mp3s/weatherReportSuite.mp3" length="12216320" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://arts.ucsc.edu/gdead/agdl/darkstar.html&quot;&gt;Dark Star&lt;/a&gt; crashes, pouring its light into ashes.</description>
+			<enclosure url="http://www.scripting.com/mp3s/darkStar.mp3" length="10889216" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>DaveNet: &lt;a href=&quot;http://davenet.userland.com/2001/01/21/theUsBlues&quot;&gt;The U.S. Blues&lt;/a&gt;.</description>
+			</item>
+		<item>
+			<description>Still listening to the US Blues. &lt;i&gt;&quot;Wave that flag, wave it wide and high..&quot;&lt;/i&gt; Mistake made in the 60s. We gave our country to the assholes. Ah ah. Let&apos;s take it back. Hey I&apos;m still a hippie. &lt;i&gt;&quot;You could call this song The United States Blues.&quot;&lt;/i&gt;</description>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://www.sixties.com/html/garcia_stack_0.html&quot;&gt;&lt;img src=&quot;http://www.scripting.com/images/captainTripsSmall.gif&quot; height=&quot;51&quot; width=&quot;42&quot; border=&quot;0&quot; hspace=&quot;10&quot; vspace=&quot;10&quot; align=&quot;right&quot;&gt;&lt;/a&gt;In celebration of today&apos;s inauguration, after hearing all those great patriotic songs, America the Beautiful, even The Star Spangled Banner made my eyes mist up. It made my choice of Grateful Dead song of the night realllly easy. Here are the &lt;a href=&quot;http://searchlyrics2.homestead.com/gd_usblues.html&quot;&gt;lyrics&lt;/a&gt;. Click on the audio icon to the left to give it a listen. &quot;Red and white, blue suede shoes, I&apos;m Uncle Sam, how do you do?&quot; It&apos;s a different kind of patriotic music, but man I love my country and I love Jerry and the band. &lt;i&gt;I truly do!&lt;/i&gt;</description>
+			<enclosure url="http://www.scripting.com/mp3s/usBlues.mp3" length="5272510" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>Grateful Dead: &quot;Tennessee, Tennessee, ain&apos;t no place I&apos;d rather be.&quot;</description>
+			<enclosure url="http://www.scripting.com/mp3s/tennesseeJed.mp3" length="3442648" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>Ed Cone: &quot;Had a nice Deadhead experience with my wife, who never was one but gets the vibe and knows and likes a lot of the music. Somehow she made it to the age of 40 without ever hearing Wharf Rat. We drove to Jersey and back over Christmas with the live album commonly known as Skull and Roses in the CD player much of the way, and it was cool to see her discover one the band&apos;s finest moments. That song is unique and underappreciated. Fun to hear that disc again after a few years off -- you get Jerry as blues-guitar hero on Big Railroad Blues and a nice version of Bertha.&quot;</description>
+			<enclosure url="http://www.scripting.com/mp3s/darkStarWharfRat.mp3" length="27503386" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://arts.ucsc.edu/GDead/AGDL/fotd.html&quot;&gt;Tonight&apos;s Song&lt;/a&gt;: &quot;If I get home before daylight I just might get some sleep tonight.&quot; </description>
+			<enclosure url="http://www.scripting.com/mp3s/friendOfTheDevil.mp3" length="3219742" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://arts.ucsc.edu/GDead/AGDL/uncle.html&quot;&gt;Tonight&apos;s song&lt;/a&gt;: &quot;Come hear Uncle John&apos;s Band by the river side. Got some things to talk about here beside the rising tide.&quot;</description>
+			<enclosure url="http://www.scripting.com/mp3s/uncleJohnsBand.mp3" length="4587102" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://www.cs.cmu.edu/~mleone/gdead/dead-lyrics/Me_and_My_Uncle.txt&quot;&gt;Me and My Uncle&lt;/a&gt;: &quot;I loved my uncle, God rest his soul, taught me good, Lord, taught me all I know. Taught me so well, I grabbed that gold and I left his dead ass there by the side of the road.&quot;
+</description>
+			<enclosure url="http://www.scripting.com/mp3s/meAndMyUncle.mp3" length="2949248" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>Truckin, like the doo-dah man, once told me gotta play your hand. Sometimes the cards ain&apos;t worth a dime, if you don&apos;t lay em down.</description>
+			<enclosure url="http://www.scripting.com/mp3s/truckin.mp3" length="4847908" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>Two-Way-Web: &lt;a href=&quot;http://www.thetwowayweb.com/payloadsForRss&quot;&gt;Payloads for RSS&lt;/a&gt;. &quot;When I started talking with Adam late last year, he wanted me to think about high quality video on the Internet, and I totally didn&apos;t want to hear about it.&quot;</description>
+			</item>
+		<item>
+			<description>A touch of gray, kinda suits you anyway..</description>
+			<enclosure url="http://www.scripting.com/mp3s/touchOfGrey.mp3" length="5588242" type="audio/mpeg"/>
+			</item>
+		<item>
+			<description>&lt;a href=&quot;http://www.sixties.com/html/garcia_stack_0.html&quot;&gt;&lt;img src=&quot;http://www.scripting.com/images/captainTripsSmall.gif&quot; height=&quot;51&quot; width=&quot;42&quot; border=&quot;0&quot; hspace=&quot;10&quot; vspace=&quot;10&quot; align=&quot;right&quot;&gt;&lt;/a&gt;In celebration of today&apos;s inauguration, after hearing all those great patriotic songs, America the Beautiful, even The Star Spangled Banner made my eyes mist up. It made my choice of Grateful Dead song of the night realllly easy. Here are the &lt;a href=&quot;http://searchlyrics2.homestead.com/gd_usblues.html&quot;&gt;lyrics&lt;/a&gt;. Click on the audio icon to the left to give it a listen. &quot;Red and white, blue suede shoes, I&apos;m Uncle Sam, how do you do?&quot; It&apos;s a different kind of patriotic music, but man I love my country and I love Jerry and the band. &lt;i&gt;I truly do!&lt;/i&gt;</description>
+			<enclosure url="http://www.scripting.com/mp3s/usBlues.mp3" length="5272510" type="audio/mpeg"/>
+			</item>
+		</channel>
+	</rss>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Atom.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Atom.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Atom.php	(revision 14676)
@@ -0,0 +1,365 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * Atom feed class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: Atom.php,v 1.25 2007/03/26 12:49:05 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+*/
+
+/**
+ * This is the class that determines how we manage Atom 1.0 feeds
+ * 
+ * How we deal with constructs:
+ *  date - return as unix datetime for use with the 'date' function unless specified otherwise
+ *  text - return as is. optional parameter will give access to attributes
+ *  person - defaults to name, but parameter based access
+ *
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_Atom extends XML_Feed_Parser_Type
+{
+    /**
+     * The URI of the RelaxNG schema used to (optionally) validate the feed 
+     * @var string
+     */
+    private $relax = 'atom.rnc';
+
+    /**
+     * We're likely to use XPath, so let's keep it global 
+     * @var DOMXPath
+     */
+    public $xpath;
+
+    /**
+     * When performing XPath queries we will use this prefix 
+     * @var string
+     */
+    private $xpathPrefix = '//';
+
+    /**
+     * The feed type we are parsing 
+     * @var string
+     */
+    public $version = 'Atom 1.0';
+
+    /** 
+     * The class used to represent individual items 
+     * @var string
+     */
+    protected $itemClass = 'XML_Feed_Parser_AtomElement';
+    
+    /** 
+     * The element containing entries 
+     * @var string
+     */
+    protected $itemElement = 'entry';
+
+    /**
+     * Here we map those elements we're not going to handle individually
+     * to the constructs they are. The optional second parameter in the array
+     * tells the parser whether to 'fall back' (not apt. at the feed level) or
+     * fail if the element is missing. If the parameter is not set, the function
+     * will simply return false and leave it to the client to decide what to do.
+     * @var array
+     */
+    protected $map = array(
+        'author' => array('Person'),
+        'contributor' => array('Person'),
+        'icon' => array('Text'),
+        'logo' => array('Text'),
+        'id' => array('Text', 'fail'),
+        'rights' => array('Text'),
+        'subtitle' => array('Text'),
+        'title' => array('Text', 'fail'),
+        'updated' => array('Date', 'fail'),
+        'link' => array('Link'),
+        'generator' => array('Text'),
+        'category' => array('Category'));
+
+    /**
+     * Here we provide a few mappings for those very special circumstances in
+     * which it makes sense to map back to the RSS2 spec. Key is RSS2 version
+     * value is an array consisting of the equivalent in atom and any attributes
+     * needed to make the mapping.
+     * @var array
+     */
+    protected $compatMap = array(
+        'guid' => array('id'),
+        'links' => array('link'),
+        'tags' => array('category'),
+        'contributors' => array('contributor'));
+
+    /**
+     * Our constructor does nothing more than its parent.
+     * 
+     * @param    DOMDocument    $xml    A DOM object representing the feed
+     * @param    bool (optional) $string    Whether or not to validate this feed
+     */
+    function __construct(DOMDocument $model, $strict = false)
+    {
+        $this->model = $model;
+
+        if ($strict) {
+            if (! $this->model->relaxNGValidateSource($this->relax)) {
+                throw new XML_Feed_Parser_Exception('Failed required validation');
+            }
+        }
+
+        $this->xpath = new DOMXPath($this->model);
+        $this->xpath->registerNamespace('atom', 'http://www.w3.org/2005/Atom');
+        $this->numberEntries = $this->count('entry');
+    }
+
+    /**
+     * Implement retrieval of an entry based on its ID for atom feeds.
+     *
+     * This function uses XPath to get the entry based on its ID. If DOMXPath::evaluate
+     * is available, we also use that to store a reference to the entry in the array
+     * used by getEntryByOffset so that method does not have to seek out the entry
+     * if it's requested that way.
+     * 
+     * @param    string    $id    any valid Atom ID.
+     * @return    XML_Feed_Parser_AtomElement
+     */
+    function getEntryById($id)
+    {
+        if (isset($this->idMappings[$id])) {
+            return $this->entries[$this->idMappings[$id]];
+        }
+
+        $entries = $this->xpath->query("//atom:entry[atom:id='$id']");
+
+        if ($entries->length > 0) {
+            $xmlBase = $entries->item(0)->baseURI;
+            $entry = new $this->itemElement($entries->item(0), $this, $xmlBase);
+            
+            if (in_array('evaluate', get_class_methods($this->xpath))) {
+                $offset = $this->xpath->evaluate("count(preceding-sibling::atom:entry)", $entries->item(0));
+                $this->entries[$offset] = $entry;
+            }
+
+            $this->idMappings[$id] = $entry;
+
+            return $entry;
+        }
+        
+    }
+
+    /**
+     * Retrieves data from a person construct.
+     *
+     * Get a person construct. We default to the 'name' element but allow
+     * access to any of the elements.
+     * 
+     * @param    string    $method    The name of the person construct we want
+     * @param    array     $arguments    An array which we hope gives a 'param'
+     * @return    string|false
+     */
+    protected function getPerson($method, $arguments)
+    {
+        $offset = empty($arguments[0]) ? 0 : $arguments[0];
+        $parameter = empty($arguments[1]['param']) ? 'name' : $arguments[1]['param'];
+        $section = $this->model->getElementsByTagName($method);
+        
+        if ($parameter == 'url') {
+            $parameter = 'uri';
+        }
+
+        if ($section->length <= $offset) {
+            return false;
+        }
+
+        $param = $section->item($offset)->getElementsByTagName($parameter);
+        if ($param->length == 0) {
+            return false;
+        }
+        return $param->item(0)->nodeValue;
+    }
+
+    /**
+     * Retrieves an element's content where that content is a text construct.
+     *
+     * Get a text construct. When calling this method, the two arguments
+     * allowed are 'offset' and 'attribute', so $parser->subtitle() would
+     * return the content of the element, while $parser->subtitle(false, 'type')
+     * would return the value of the type attribute.
+     *
+     * @todo    Clarify overlap with getContent()
+     * @param    string    $method    The name of the text construct we want
+     * @param    array     $arguments    An array which we hope gives a 'param'
+     * @return    string
+     */
+    protected function getText($method, $arguments)
+    {
+        $offset = empty($arguments[0]) ? 0: $arguments[0];
+        $attribute = empty($arguments[1]) ? false : $arguments[1];
+        $tags = $this->model->getElementsByTagName($method);
+
+        if ($tags->length <= $offset) {
+            return false;
+        }
+
+        $content = $tags->item($offset);
+
+        if (! $content->hasAttribute('type')) {
+            $content->setAttribute('type', 'text');
+        }
+        $type = $content->getAttribute('type');
+
+        if (! empty($attribute) and 
+            ! ($method == 'generator' and $attribute == 'name')) {
+            if ($content->hasAttribute($attribute)) {
+                return $content->getAttribute($attribute);
+            } else if ($attribute == 'href' and $content->hasAttribute('uri')) {
+                return $content->getAttribute('uri');
+            }
+            return false;
+        }
+        return $this->parseTextConstruct($content);
+    }
+    
+    /**
+     * Extract content appropriately from atom text constructs
+     *
+     * Because of different rules applied to the content element and other text
+     * constructs, they are deployed as separate functions, but they share quite
+     * a bit of processing. This method performs the core common process, which is
+     * to apply the rules for different mime types in order to extract the content.
+     *
+     * @param   DOMNode $content    the text construct node to be parsed
+     * @return String
+     * @author James Stewart
+     **/
+    protected function parseTextConstruct(DOMNode $content)
+    {
+        if ($content->hasAttribute('type')) {
+            $type = $content->getAttribute('type');
+        } else {
+            $type = 'text';
+        }
+
+        if (strpos($type, 'text/') === 0) {
+            $type = 'text';
+        }
+        switch ($type) {
+            case 'text':
+                return $content->nodeValue;
+                break;
+            case 'html':
+                return str_replace('&lt;', '<', $content->nodeValue);
+                break;
+            case 'xhtml':
+                $container = $content->getElementsByTagName('div');
+                if ($container->length == 0) {
+                    return false;
+                }
+                $contents = $container->item(0);
+                if ($contents->hasChildNodes()) {
+                    /* Iterate through, applying xml:base and store the result */
+                    $result = '';
+                    foreach ($contents->childNodes as $node) {
+                        $result .= $this->traverseNode($node);
+                    }
+                    return utf8_decode($result);
+                }
+                break;
+            case preg_match('@^[a-zA-Z]+/[a-zA-Z+]*xml@i', $type) > 0:
+                return $content;
+                break;
+            case 'application/octet-stream':
+            default:
+                return base64_decode(trim($content->nodeValue));
+                break;
+        }
+        return false;
+    }
+    /**
+     * Get a category from the entry.
+     *
+     * A feed or entry can have any number of categories. A category can have the
+     * attributes term, scheme and label.
+     * 
+     * @param    string    $method    The name of the text construct we want
+     * @param    array     $arguments    An array which we hope gives a 'param'
+     * @return    string
+     */
+    function getCategory($method, $arguments)
+    {
+        $offset = empty($arguments[0]) ? 0: $arguments[0];
+        $attribute = empty($arguments[1]) ? 'term' : $arguments[1];
+        $categories = $this->model->getElementsByTagName('category');
+        if ($categories->length <= $offset) {
+            $category = $categories->item($offset);
+            if ($category->hasAttribute($attribute)) {
+                return $category->getAttribute($attribute);
+            }
+        }
+        return false;
+    }
+
+    /**
+     * This element must be present at least once with rel="feed". This element may be 
+     * present any number of further times so long as there is no clash. If no 'rel' is 
+     * present and we're asked for one, we follow the example of the Universal Feed
+     * Parser and presume 'alternate'.
+     *
+     * @param    int    $offset    the position of the link within the container
+     * @param    string    $attribute    the attribute name required
+     * @param    array     an array of attributes to search by
+     * @return    string    the value of the attribute
+     */
+    function getLink($offset = 0, $attribute = 'href', $params = false)
+    {
+        if (is_array($params) and !empty($params)) {
+            $terms = array();
+            $alt_predicate = '';
+            $other_predicate = '';
+
+            foreach ($params as $key => $value) {
+                if ($key == 'rel' && $value == 'alternate') {
+                    $alt_predicate = '[not(@rel) or @rel="alternate"]';
+                } else {
+                    $terms[] = "@$key='$value'";
+                }
+            }
+            if (!empty($terms)) {
+                $other_predicate = '[' . join(' and ', $terms) . ']';
+            }
+            $query =  $this->xpathPrefix . 'atom:link' . $alt_predicate . $other_predicate;
+            $links = $this->xpath->query($query);
+        } else {
+            $links = $this->model->getElementsByTagName('link');
+        }
+        if ($links->length > $offset) {
+            if ($links->item($offset)->hasAttribute($attribute)) {
+                $value = $links->item($offset)->getAttribute($attribute);
+                if ($attribute == 'href') {
+                    $value = $this->addBase($value, $links->item($offset));
+                }
+                return $value;
+            } else if ($attribute == 'rel') {
+                return 'alternate';
+            }
+        }
+        return false;
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS09.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS09.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS09.php	(revision 14676)
@@ -0,0 +1,214 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * RSS0.9 class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS09.php,v 1.5 2006/07/26 21:18:46 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This class handles RSS0.9 feeds.
+ * 
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ * @todo    Find a Relax NG URI we can use
+ */
+class XML_Feed_Parser_RSS09 extends XML_Feed_Parser_Type
+{
+    /**
+     * The URI of the RelaxNG schema used to (optionally) validate the feed 
+     * @var string
+     */
+    private $relax = '';
+
+    /**
+     * We're likely to use XPath, so let's keep it global
+     * @var DOMXPath
+     */
+    protected $xpath;
+
+    /**
+     * The feed type we are parsing 
+     * @var string
+     */
+    public $version = 'RSS 0.9';
+
+    /**
+     * The class used to represent individual items 
+     * @var string
+     */
+    protected $itemClass = 'XML_Feed_Parser_RSS09Element';
+    
+    /**
+     * The element containing entries 
+     * @var string
+     */
+    protected $itemElement = 'item';
+
+    /**
+     * Here we map those elements we're not going to handle individually
+     * to the constructs they are. The optional second parameter in the array
+     * tells the parser whether to 'fall back' (not apt. at the feed level) or
+     * fail if the element is missing. If the parameter is not set, the function
+     * will simply return false and leave it to the client to decide what to do.
+     * @var array
+     */
+    protected $map = array(
+        'title' => array('Text'),
+        'link' => array('Text'),
+        'description' => array('Text'),
+        'image' => array('Image'),
+        'textinput' => array('TextInput'));
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS2.
+     * @var array
+     */
+    protected $compatMap = array(
+        'title' => array('title'),
+        'link' => array('link'),
+        'subtitle' => array('description'));
+
+    /**
+     * We will be working with multiple namespaces and it is useful to 
+     * keep them together 
+     * @var array
+     */
+    protected $namespaces = array(
+        'rdf' => 'http://www.w3.org/1999/02/22-rdf-syntax-ns#');
+
+    /**
+     * Our constructor does nothing more than its parent.
+     * 
+     * @todo    RelaxNG validation
+     * @param    DOMDocument    $xml    A DOM object representing the feed
+     * @param    bool (optional) $string    Whether or not to validate this feed
+     */
+    function __construct(DOMDocument $model, $strict = false)
+    {
+        $this->model = $model;
+
+        $this->xpath = new DOMXPath($model);
+        foreach ($this->namespaces as $key => $value) {
+            $this->xpath->registerNamespace($key, $value);
+        }            
+        $this->numberEntries = $this->count('item');
+    }
+
+    /**
+     * Included for compatibility -- will not work with RSS 0.9
+     *
+     * This is not something that will work with RSS0.9 as it does not have
+     * clear restrictions on the global uniqueness of IDs.
+     *
+     * @param    string    $id    any valid ID.
+     * @return    false
+     */
+    function getEntryById($id)
+    {
+        return false;        
+    }
+
+    /**
+     * Get details of the image associated with the feed.
+     *
+     * @return  array|false an array simply containing the child elements
+     */
+    protected function getImage()
+    {
+        $images = $this->model->getElementsByTagName('image');
+        if ($images->length > 0) {
+            $image = $images->item(0);
+            $details = array();
+            if ($image->hasChildNodes()) {
+                $details = array(
+                    'title' => $image->getElementsByTagName('title')->item(0)->value,
+                    'link' => $image->getElementsByTagName('link')->item(0)->value,
+                    'url' => $image->getElementsByTagName('url')->item(0)->value);
+            } else {
+                $details = array('title' => false,
+                    'link' => false,
+                    'url' => $image->attributes->getNamedItem('resource')->nodeValue);
+            }
+            $details = array_merge($details, 
+                array('description' => false, 'height' => false, 'width' => false));
+            if (! empty($details)) {
+                return $details;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * The textinput element is little used, but in the interests of
+     * completeness we will support it.
+     *
+     * @return  array|false
+     */
+    protected function getTextInput()
+    {
+        $inputs = $this->model->getElementsByTagName('textinput');
+        if ($inputs->length > 0) {
+            $input = $inputs->item(0);
+            $results = array();
+            $results['title'] = isset(
+                $input->getElementsByTagName('title')->item(0)->value) ? 
+                $input->getElementsByTagName('title')->item(0)->value : null;
+            $results['description'] = isset(
+                $input->getElementsByTagName('description')->item(0)->value) ? 
+                $input->getElementsByTagName('description')->item(0)->value : null;
+            $results['name'] = isset(
+                $input->getElementsByTagName('name')->item(0)->value) ? 
+                $input->getElementsByTagName('name')->item(0)->value : null;
+            $results['link'] = isset(
+                   $input->getElementsByTagName('link')->item(0)->value) ? 
+                   $input->getElementsByTagName('link')->item(0)->value : null;
+            if (empty($results['link']) && 
+                $input->attributes->getNamedItem('resource')) {
+                $results['link'] = $input->attributes->getNamedItem('resource')->nodeValue;
+            }
+            if (! empty($results)) {
+                return $results;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * Get details of a link from the feed.
+     *
+     * In RSS1 a link is a text element but in order to ensure that we resolve
+     * URLs properly we have a special function for them.
+     *
+     * @return  string
+     */
+    function getLink($offset = 0, $attribute = 'href', $params = false)
+    {
+        $links = $this->model->getElementsByTagName('link');
+        if ($links->length <= $offset) {
+            return false;
+        }
+        $link = $links->item($offset);
+        return $this->addBase($link->nodeValue, $link);
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Type.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Type.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Type.php	(revision 14676)
@@ -0,0 +1,441 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * Abstract class providing common methods for XML_Feed_Parser feeds.
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: Type.php,v 1.22 2006/08/15 13:02:36 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This abstract class provides some general methods that are likely to be
+ * implemented exactly the same way for all feed types.
+ *
+ * @package XML_Feed_Parser
+ * @author  James Stewart <james@jystewart.net>
+ * @version Release: 1.0.2
+ */
+abstract class XML_Feed_Parser_Type
+{
+    /**
+     * Where we store our DOM object for this feed 
+     * @var DOMDocument
+     */
+    public $model;
+
+    /**
+     * For iteration we'll want a count of the number of entries 
+     * @var int
+     */
+    public $numberEntries;
+
+    /**
+     * Where we store our entry objects once instantiated 
+     * @var array
+     */
+    public $entries = array();
+
+    /**
+     * Proxy to allow use of element names as method names
+     *
+     * We are not going to provide methods for every entry type so this
+     * function will allow for a lot of mapping. We rely pretty heavily
+     * on this to handle our mappings between other feed types and atom.
+     *
+     * @param   string  $call - the method attempted
+     * @param   array   $arguments - arguments to that method
+     * @return  mixed
+     */
+    function __call($call, $arguments = array())
+    {
+        if (! is_array($arguments)) {
+            $arguments = array();
+        }
+
+        if (isset($this->compatMap[$call])) {
+            $tempMap = $this->compatMap;
+            $tempcall = array_pop($tempMap[$call]);
+            if (! empty($tempMap)) {
+                $arguments = array_merge($arguments, $tempMap[$call]);
+            }
+            $call = $tempcall;
+        }
+
+        /* To be helpful, we allow a case-insensitive search for this method */
+        if (! isset($this->map[$call])) {
+            foreach (array_keys($this->map) as $key) {
+                if (strtoupper($key) == strtoupper($call)) {
+                    $call = $key;
+                    break;
+                }
+            }
+        }
+
+        if (empty($this->map[$call])) {
+            return false;
+        }
+
+        $method = 'get' . $this->map[$call][0];
+        if ($method == 'getLink') {
+            $offset = empty($arguments[0]) ? 0 : $arguments[0];
+            $attribute = empty($arguments[1]) ? 'href' : $arguments[1];
+            $params = isset($arguments[2]) ? $arguments[2] : array();
+            return $this->getLink($offset, $attribute, $params);
+        }
+        if (method_exists($this, $method)) {
+            return $this->$method($call, $arguments);
+        }
+
+        return false;
+    }
+
+    /**
+     * Proxy to allow use of element names as attribute names
+     *
+     * For many elements variable-style access will be desirable. This function
+     * provides for that.
+     *
+     * @param   string  $value - the variable required
+     * @return  mixed
+     */
+    function __get($value)
+    {
+        return $this->__call($value, array());
+    }
+
+    /**
+     * Utility function to help us resolve xml:base values
+     *
+     * We have other methods which will traverse the DOM and work out the different
+     * xml:base declarations we need to be aware of. We then need to combine them.
+     * If a declaration starts with a protocol then we restart the string. If it 
+     * starts with a / then we add on to the domain name. Otherwise we simply tag 
+     * it on to the end.
+     *
+     * @param   string  $base - the base to add the link to
+     * @param   string  $link
+     */
+    function combineBases($base, $link)
+    {
+        if (preg_match('/^[A-Za-z]+:\/\//', $link)) {
+            return $link;
+        } else if (preg_match('/^\//', $link)) {
+            /* Extract domain and suffix link to that */
+            preg_match('/^([A-Za-z]+:\/\/.*)?\/*/', $base, $results);
+            $firstLayer = $results[0];
+            return $firstLayer . "/" . $link;
+        } else if (preg_match('/^\.\.\//', $base)) {
+            /* Step up link to find place to be */
+            preg_match('/^((\.\.\/)+)(.*)$/', $link, $bases);
+            $suffix = $bases[3];
+            $count = preg_match_all('/\.\.\//', $bases[1], $steps);
+            $url = explode("/", $base);
+            for ($i = 0; $i <= $count; $i++) {
+                array_pop($url);
+            }
+            return implode("/", $url) . "/" . $suffix;
+        } else if (preg_match('/^(?!\/$)/', $base)) {
+            $base = preg_replace('/(.*\/).*$/', '$1', $base)  ;
+            return $base . $link;
+        } else {
+            /* Just stick it on the end */
+            return $base . $link;
+        }
+    }
+
+    /**
+     * Determine whether we need to apply our xml:base rules
+     *
+     * Gets us the xml:base data and then processes that with regard
+     * to our current link.
+     *
+     * @param   string
+     * @param   DOMElement
+     * @return  string
+     */
+    function addBase($link, $element)
+    {
+        if (preg_match('/^[A-Za-z]+:\/\//', $link)) {
+            return $link;
+        }
+
+        return $this->combineBases($element->baseURI, $link);
+    }
+
+    /**
+     * Get an entry by its position in the feed, starting from zero
+     *
+     * As well as allowing the items to be iterated over we want to allow
+     * users to be able to access a specific entry. This is one of two ways of
+     * doing that, the other being by ID.
+     * 
+     * @param   int $offset
+     * @return  XML_Feed_Parser_RSS1Element
+     */
+    function getEntryByOffset($offset)
+    {
+        if (! isset($this->entries[$offset])) {
+            $entries = $this->model->getElementsByTagName($this->itemElement);
+            if ($entries->length > $offset) {
+                $xmlBase = $entries->item($offset)->baseURI;
+                $this->entries[$offset] = new $this->itemClass(
+                    $entries->item($offset), $this, $xmlBase);
+                if ($id = $this->entries[$offset]->id) {
+                    $this->idMappings[$id] = $this->entries[$offset];
+                }
+            } else {
+                throw new XML_Feed_Parser_Exception('No entries found');
+            }
+        }
+
+        return $this->entries[$offset];
+    }
+
+    /**
+     * Return a date in seconds since epoch.
+     *
+     * Get a date construct. We use PHP's strtotime to return it as a unix datetime, which
+     * is the number of seconds since 1970-01-01 00:00:00.
+     * 
+     * @link    http://php.net/strtotime
+     * @param    string    $method        The name of the date construct we want
+     * @param    array     $arguments    Included for compatibility with our __call usage
+     * @return    int|false datetime
+     */
+    protected function getDate($method, $arguments)
+    {
+        $time = $this->model->getElementsByTagName($method);
+        if ($time->length == 0) {
+            return false;
+        }
+        return strtotime($time->item(0)->nodeValue);
+    }
+
+    /**
+     * Get a text construct. 
+     *
+     * @param    string    $method    The name of the text construct we want
+     * @param    array     $arguments    Included for compatibility with our __call usage
+     * @return    string
+     */
+    protected function getText($method, $arguments = array())
+    {
+        $tags = $this->model->getElementsByTagName($method);
+        if ($tags->length > 0) {
+            $value = $tags->item(0)->nodeValue;
+            return $value;
+        }
+        return false;
+    }
+
+    /**
+     * Apply various rules to retrieve category data.
+     *
+     * There is no single way of declaring a category in RSS1/1.1 as there is in RSS2 
+     * and  Atom. Instead the usual approach is to use the dublin core namespace to 
+     * declare  categories. For example delicious use both: 
+     * <dc:subject>PEAR</dc:subject> and: <taxo:topics><rdf:Bag>
+     * <rdf:li resource="http://del.icio.us/tag/PEAR" /></rdf:Bag></taxo:topics>
+     * to declare a categorisation of 'PEAR'.
+     *
+     * We need to be sensitive to this where possible.
+     *
+     * @param    string    $call    for compatibility with our overloading
+     * @param   array $arguments - arg 0 is the offset, arg 1 is whether to return as array
+     * @return  string|array|false
+     */
+    protected function getCategory($call, $arguments)
+    {
+        $categories = $this->model->getElementsByTagName('subject');
+        $offset = empty($arguments[0]) ? 0 : $arguments[0];
+        $array = empty($arguments[1]) ? false : true;
+        if ($categories->length <= $offset) {
+            return false;
+        }
+        if ($array) {
+            $list = array();
+            foreach ($categories as $category) {
+                array_push($list, $category->nodeValue);
+            }
+            return $list;
+        }
+        return $categories->item($offset)->nodeValue;
+    }
+
+    /**
+     * Count occurrences of an element
+     *
+     * This function will tell us how many times the element $type
+     * appears at this level of the feed.
+     * 
+     * @param    string    $type    the element we want to get a count of
+     * @return    int
+     */
+    protected function count($type)
+    {
+        if ($tags = $this->model->getElementsByTagName($type)) {
+            return $tags->length;
+        }
+        return 0;
+    }
+
+    /**
+     * Part of our xml:base processing code
+     *
+     * We need a couple of methods to access XHTML content stored in feeds. 
+     * This is because we dereference all xml:base references before returning
+     * the element. This method handles the attributes.
+     *
+     * @param   DOMElement $node    The DOM node we are iterating over
+     * @return  string
+     */
+    function processXHTMLAttributes($node) {
+        $return = '';
+        foreach ($node->attributes as $attribute) {
+            if ($attribute->name == 'src' or $attribute->name == 'href') {
+                $attribute->value = $this->addBase($attribute->value, $attribute);
+            }
+            if ($attribute->name == 'base') {
+                continue;
+            }
+            $return .= $attribute->name . '="' . $attribute->value .'" ';
+        }
+        if (! empty($return)) {
+            return ' ' . trim($return);
+        }
+        return '';
+    }
+
+    /**
+     * Part of our xml:base processing code
+     *
+     * We need a couple of methods to access XHTML content stored in feeds. 
+     * This is because we dereference all xml:base references before returning
+     * the element. This method recurs through the tree descending from the node
+     * and builds our string
+     *
+     * @param   DOMElement $node    The DOM node we are processing
+     * @return   string
+     */
+    function traverseNode($node)
+    {
+        $content = '';
+
+        /* Add the opening of this node to the content */
+        if ($node instanceof DOMElement) {
+            $content .= '<' . $node->tagName . 
+                $this->processXHTMLAttributes($node) . '>';
+        }
+
+        /* Process children */
+        if ($node->hasChildNodes()) {
+            foreach ($node->childNodes as $child) {
+                $content .= $this->traverseNode($child);
+            }
+        }
+
+        if ($node instanceof DOMText) {
+            $content .= htmlentities($node->nodeValue);
+        }
+
+        /* Add the closing of this node to the content */
+        if ($node instanceof DOMElement) {
+            $content .= '</' . $node->tagName . '>';
+        }
+
+        return $content;
+    }
+
+    /**
+     * Get content from RSS feeds (atom has its own implementation)
+     *
+     * The official way to include full content in an RSS1 entry is to use
+     * the content module's element 'encoded', and RSS2 feeds often duplicate that.
+     * Often, however, the 'description' element is used instead. We will offer that 
+     * as a fallback. Atom uses its own approach and overrides this method.
+     *
+     * @return  string|false
+     */
+    protected function getContent()
+    {
+        $options = array('encoded', 'description');
+        foreach ($options as $element) {
+            $test = $this->model->getElementsByTagName($element);
+            if ($test->length == 0) {
+                continue;
+            }
+            if ($test->item(0)->hasChildNodes()) {
+                $value = '';
+                foreach ($test->item(0)->childNodes as $child) {
+                    if ($child instanceof DOMText) {
+                        $value .= $child->nodeValue;
+                    } else {
+                        $simple = simplexml_import_dom($child);
+                        $value .= $simple->asXML();
+                    }
+                }
+                return $value;
+            } else if ($test->length > 0) {
+                return $test->item(0)->nodeValue;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Checks if this element has a particular child element.
+     *
+     * @param   String
+     * @param   Integer
+     * @return  bool
+     **/
+    function hasKey($name, $offset = 0)
+    {
+        $search = $this->model->getElementsByTagName($name);
+        return $search->length > $offset;
+    }
+
+    /**
+     * Return an XML serialization of the feed, should it be required. Most 
+     * users however, will already have a serialization that they used when 
+     * instantiating the object.
+     *
+     * @return    string    XML serialization of element
+     */    
+    function __toString()
+    {
+        $simple = simplexml_import_dom($this->model);
+        return $simple->asXML();
+    }
+    
+    /**
+     * Get directory holding RNG schemas. Method is based on that 
+     * found in Contact_AddressBook.
+     *
+     * @return string PEAR data directory.
+     * @access public
+     * @static
+     */
+    static function getSchemaDir()
+    {
+        require_once 'PEAR/Config.php';
+        $config = new PEAR_Config;
+        return $config->get('data_dir') . '/XML_Feed_Parser/schemas';
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS1Element.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS1Element.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS1Element.php	(revision 14676)
@@ -0,0 +1,116 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * RSS1 Element class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS1Element.php,v 1.6 2006/06/30 17:41:56 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/*
+ * This class provides support for RSS 1.0 entries. It will usually be called by
+ * XML_Feed_Parser_RSS1 with which it shares many methods.
+ *
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_RSS1Element extends XML_Feed_Parser_RSS1
+{
+    /**
+     * This will be a reference to the parent object for when we want
+     * to use a 'fallback' rule 
+     * @var XML_Feed_Parser_RSS1
+     */
+    protected $parent;
+
+    /**
+     * Our specific element map 
+     * @var array
+     */
+    protected $map = array(
+        'id' => array('Id'),
+        'title' => array('Text'),
+        'link' => array('Link'),
+        'description' => array('Text'), # or dc:description
+        'category' => array('Category'),
+        'rights' => array('Text'), # dc:rights
+        'creator' => array('Text'), # dc:creator
+        'publisher' => array('Text'), # dc:publisher
+        'contributor' => array('Text'), # dc:contributor
+        'date' => array('Date'), # dc:date
+        'content' => array('Content')
+        );
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS1.
+     * @var array
+     */
+    protected $compatMap = array(
+        'content' => array('content'),
+        'updated' => array('lastBuildDate'),
+        'published' => array('pubdate'),
+        'subtitle' => array('description'),
+        'updated' => array('date'),
+        'author' => array('creator'),
+        'contributor' => array('contributor')
+    );
+
+    /**
+     * Store useful information for later.
+     *
+     * @param   DOMElement  $element - this item as a DOM element
+     * @param   XML_Feed_Parser_RSS1 $parent - the feed of which this is a member
+     */
+    function __construct(DOMElement $element, $parent, $xmlBase = '')
+    {
+        $this->model = $element;
+        $this->parent = $parent;
+    }
+
+    /**
+     * If an rdf:about attribute is specified, return it as an ID
+     *
+     * There is no established way of showing an ID for an RSS1 entry. We will 
+     * simulate it using the rdf:about attribute of the entry element. This cannot
+     * be relied upon for unique IDs but may prove useful.
+     *
+     * @return  string|false
+     */
+    function getId()
+    {
+        if ($this->model->attributes->getNamedItem('about')) {
+            return $this->model->attributes->getNamedItem('about')->nodeValue;
+        }
+        return false;
+    }
+
+    /**
+     * How RSS1 should support for enclosures is not clear. For now we will return
+     * false.
+     *
+     * @return  false
+     */
+    function getEnclosure()
+    {
+        return false;
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS11Element.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS11Element.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS11Element.php	(revision 14676)
@@ -0,0 +1,151 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * RSS1 Element class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS11Element.php,v 1.4 2006/06/30 17:41:56 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/*
+ * This class provides support for RSS 1.1 entries. It will usually be called by
+ * XML_Feed_Parser_RSS11 with which it shares many methods.
+ *
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_RSS11Element extends XML_Feed_Parser_RSS11
+{
+    /**
+     * This will be a reference to the parent object for when we want
+     * to use a 'fallback' rule 
+     * @var XML_Feed_Parser_RSS1
+     */
+    protected $parent;
+
+    /**
+     * Our specific element map 
+     * @var array
+     */
+    protected $map = array(
+        'id' => array('Id'),
+        'title' => array('Text'),
+        'link' => array('Link'),
+        'description' => array('Text'), # or dc:description
+        'category' => array('Category'),
+        'rights' => array('Text'), # dc:rights
+        'creator' => array('Text'), # dc:creator
+        'publisher' => array('Text'), # dc:publisher
+        'contributor' => array('Text'), # dc:contributor
+        'date' => array('Date'), # dc:date
+        'content' => array('Content')
+        );
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS1.
+     * @var array
+     */
+    protected $compatMap = array(
+        'content' => array('content'),
+        'updated' => array('lastBuildDate'),
+        'published' => array('pubdate'),
+        'subtitle' => array('description'),
+        'updated' => array('date'),
+        'author' => array('creator'),
+        'contributor' => array('contributor')
+    );
+
+    /**
+     * Store useful information for later.
+     *
+     * @param   DOMElement  $element - this item as a DOM element
+     * @param   XML_Feed_Parser_RSS1 $parent - the feed of which this is a member
+     */
+    function __construct(DOMElement $element, $parent, $xmlBase = '')
+    {
+        $this->model = $element;
+        $this->parent = $parent;
+    }
+
+    /**
+     * If an rdf:about attribute is specified, return that as an ID
+     *
+     * There is no established way of showing an ID for an RSS1 entry. We will 
+     * simulate it using the rdf:about attribute of the entry element. This cannot
+     * be relied upon for unique IDs but may prove useful.
+     *
+     * @return  string|false
+     */
+    function getId()
+    {
+        if ($this->model->attributes->getNamedItem('about')) {
+            return $this->model->attributes->getNamedItem('about')->nodeValue;
+        }
+        return false;
+    }
+
+    /**
+     * Return the entry's content
+     *
+     * The official way to include full content in an RSS1 entry is to use
+     * the content module's element 'encoded'. Often, however, the 'description'
+     * element is used instead. We will offer that as a fallback.
+     *
+     * @return  string|false
+     */
+    function getContent()
+    {
+        $options = array('encoded', 'description');
+        foreach ($options as $element) {
+            $test = $this->model->getElementsByTagName($element);
+            if ($test->length == 0) {
+                continue;
+            }
+            if ($test->item(0)->hasChildNodes()) {
+                $value = '';
+                foreach ($test->item(0)->childNodes as $child) {
+                    if ($child instanceof DOMText) {
+                        $value .= $child->nodeValue;
+                    } else {
+                        $simple = simplexml_import_dom($child);
+                        $value .= $simple->asXML();
+                    }
+                }
+                return $value;
+            } else if ($test->length > 0) {
+                return $test->item(0)->nodeValue;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * How RSS1.1 should support for enclosures is not clear. For now we will return
+     * false.
+     *
+     * @return  false
+     */
+    function getEnclosure()
+    {
+        return false;
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS2Element.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS2Element.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS2Element.php	(revision 14676)
@@ -0,0 +1,171 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * Class representing entries in an RSS2 feed.
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS2Element.php,v 1.11 2006/07/26 21:18:47 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This class provides support for RSS 2.0 entries. It will usually be 
+ * called by XML_Feed_Parser_RSS2 with which it shares many methods.
+ *
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_RSS2Element extends XML_Feed_Parser_RSS2
+{
+    /**
+     * This will be a reference to the parent object for when we want
+     * to use a 'fallback' rule
+     * @var XML_Feed_Parser_RSS2
+     */
+    protected $parent;
+
+    /**
+     * Our specific element map 
+     * @var array
+     */
+    protected $map = array(
+        'title' => array('Text'),
+        'guid' => array('Guid'),
+        'description' => array('Text'),
+        'author' => array('Text'),
+        'comments' => array('Text'),
+        'enclosure' => array('Enclosure'),
+        'pubDate' => array('Date'),
+        'source' => array('Source'),
+        'link' => array('Text'),
+        'content' => array('Content'));
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS2.
+     * @var array
+     */
+    protected $compatMap = array(
+        'id' => array('guid'),
+        'updated' => array('lastBuildDate'),
+        'published' => array('pubdate'),
+        'guidislink' => array('guid', 'ispermalink'),
+        'summary' => array('description'));
+
+    /**
+     * Store useful information for later.
+     *
+     * @param   DOMElement  $element - this item as a DOM element
+     * @param   XML_Feed_Parser_RSS2    $parent - the feed of which this is a member
+     */
+    function __construct(DOMElement $element, $parent, $xmlBase = '')
+    {
+        $this->model = $element;
+        $this->parent = $parent;
+    }
+
+    /**
+     * Get the value of the guid element, if specified
+     *
+     * guid is the closest RSS2 has to atom's ID. It is usually but not always a
+     * URI. The one attribute that RSS2 can posess is 'ispermalink' which specifies
+     * whether the guid is itself dereferencable. Use of guid is not obligatory,
+     * but is advisable. To get the guid you would call $item->id() (for atom
+     * compatibility) or $item->guid(). To check if this guid is a permalink call
+     * $item->guid("ispermalink").
+     *
+     * @param   string  $method - the method name being called
+     * @param   array   $params - parameters required
+     * @return  string  the guid or value of ispermalink
+     */
+    protected function getGuid($method, $params)
+    {
+        $attribute = (isset($params[0]) and $params[0] == 'ispermalink') ? 
+            true : false;
+        $tag = $this->model->getElementsByTagName('guid');
+        if ($tag->length > 0) {
+            if ($attribute) {
+                if ($tag->hasAttribute("ispermalink")) {
+                    return $tag->getAttribute("ispermalink");
+                }
+            }
+            return $tag->item(0)->nodeValue;
+        }
+        return false;
+    }
+
+    /**
+     * Access details of file enclosures
+     *
+     * The RSS2 spec is ambiguous as to whether an enclosure element must be
+     * unique in a given entry. For now we will assume it needn't, and allow
+     * for an offset.
+     *
+     * @param   string $method - the method being called
+     * @param   array   $parameters - we expect the first of these to be our offset
+     * @return  array|false
+     */
+    protected function getEnclosure($method, $parameters)
+    {
+        $encs = $this->model->getElementsByTagName('enclosure');
+        $offset = isset($parameters[0]) ? $parameters[0] : 0;
+        if ($encs->length > $offset) {
+            try {
+                if (! $encs->item($offset)->hasAttribute('url')) {
+                    return false;
+                }
+                $attrs = $encs->item($offset)->attributes;
+                return array(
+                    'url' => $attrs->getNamedItem('url')->value,
+                    'length' => $attrs->getNamedItem('length')->value,
+                    'type' => $attrs->getNamedItem('type')->value);
+            } catch (Exception $e) {
+                return false;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Get the entry source if specified
+     *
+     * source is an optional sub-element of item. Like atom:source it tells
+     * us about where the entry came from (eg. if it's been copied from another
+     * feed). It is not a rich source of metadata in the same way as atom:source
+     * and while it would be good to maintain compatibility by returning an
+     * XML_Feed_Parser_RSS2 element, it makes a lot more sense to return an array.
+     *
+     * @return array|false
+     */
+    protected function getSource()
+    {
+        $get = $this->model->getElementsByTagName('source');
+        if ($get->length) {
+            $source = $get->item(0);
+            $array = array(
+                'content' => $source->nodeValue);
+            foreach ($source->attributes as $attribute) {
+                $array[$attribute->name] = $attribute->value;
+            }
+            return $array;
+        }
+        return false;
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS1.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS1.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS1.php	(revision 14676)
@@ -0,0 +1,277 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * RSS1 class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS1.php,v 1.10 2006/07/27 13:52:05 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This class handles RSS1.0 feeds.
+ * 
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ * @todo    Find a Relax NG URI we can use
+ */
+class XML_Feed_Parser_RSS1 extends XML_Feed_Parser_Type
+{
+    /**
+     * The URI of the RelaxNG schema used to (optionally) validate the feed 
+     * @var string
+     */
+    private $relax = 'rss10.rnc';
+
+    /**
+     * We're likely to use XPath, so let's keep it global
+     * @var DOMXPath
+     */
+    protected $xpath;
+
+    /**
+     * The feed type we are parsing 
+     * @var string
+     */
+    public $version = 'RSS 1.0';
+
+    /**
+     * The class used to represent individual items 
+     * @var string
+     */
+    protected $itemClass = 'XML_Feed_Parser_RSS1Element';
+    
+    /**
+     * The element containing entries 
+     * @var string
+     */
+    protected $itemElement = 'item';
+
+    /**
+     * Here we map those elements we're not going to handle individually
+     * to the constructs they are. The optional second parameter in the array
+     * tells the parser whether to 'fall back' (not apt. at the feed level) or
+     * fail if the element is missing. If the parameter is not set, the function
+     * will simply return false and leave it to the client to decide what to do.
+     * @var array
+     */
+    protected $map = array(
+        'title' => array('Text'),
+        'link' => array('Text'),
+        'description' => array('Text'),
+        'image' => array('Image'),
+        'textinput' => array('TextInput'),
+        'updatePeriod' => array('Text'),
+        'updateFrequency' => array('Text'),
+        'updateBase' => array('Date'),
+        'rights' => array('Text'), # dc:rights
+        'description' => array('Text'), # dc:description
+        'creator' => array('Text'), # dc:creator
+        'publisher' => array('Text'), # dc:publisher
+        'contributor' => array('Text'), # dc:contributor
+        'date' => array('Date') # dc:contributor
+        );
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS2.
+     * @var array
+     */
+    protected $compatMap = array(
+        'title' => array('title'),
+        'link' => array('link'),
+        'subtitle' => array('description'),
+        'author' => array('creator'),
+        'updated' => array('date'));
+
+    /**
+     * We will be working with multiple namespaces and it is useful to 
+     * keep them together 
+     * @var array
+     */
+    protected $namespaces = array(
+        'rdf' => 'http://www.w3.org/1999/02/22-rdf-syntax-ns#',
+        'rss' => 'http://purl.org/rss/1.0/',
+        'dc' => 'http://purl.org/rss/1.0/modules/dc/',
+        'content' => 'http://purl.org/rss/1.0/modules/content/',
+        'sy' => 'http://web.resource.org/rss/1.0/modules/syndication/');
+
+    /**
+     * Our constructor does nothing more than its parent.
+     * 
+     * @param    DOMDocument    $xml    A DOM object representing the feed
+     * @param    bool (optional) $string    Whether or not to validate this feed
+     */
+    function __construct(DOMDocument $model, $strict = false)
+    {
+        $this->model = $model;
+        if ($strict) {
+            $validate = $this->model->relaxNGValidate(self::getSchemaDir . 
+                DIRECTORY_SEPARATOR . $this->relax);
+            if (! $validate) {
+                throw new XML_Feed_Parser_Exception('Failed required validation');
+            }
+        }
+
+        $this->xpath = new DOMXPath($model);
+        foreach ($this->namespaces as $key => $value) {
+            $this->xpath->registerNamespace($key, $value);
+        }
+        $this->numberEntries = $this->count('item');
+    }
+
+    /**
+     * Allows retrieval of an entry by ID where the rdf:about attribute is used
+     *
+     * This is not really something that will work with RSS1 as it does not have
+     * clear restrictions on the global uniqueness of IDs. We will employ the
+     * _very_ hit and miss method of selecting entries based on the rdf:about
+     * attribute. If DOMXPath::evaluate is available, we also use that to store 
+     * a reference to the entry in the array used by getEntryByOffset so that 
+     * method does not have to seek out the entry if it's requested that way.
+     *
+     * @param    string    $id    any valid ID.
+     * @return    XML_Feed_Parser_RSS1Element
+     */
+    function getEntryById($id)
+    {
+        if (isset($this->idMappings[$id])) {
+            return $this->entries[$this->idMappings[$id]];
+        }
+
+        $entries = $this->xpath->query("//rss:item[@rdf:about='$id']");
+        if ($entries->length > 0) {
+            $classname = $this->itemClass;
+            $entry = new $classname($entries->item(0), $this);
+            if (in_array('evaluate', get_class_methods($this->xpath))) {
+                $offset = $this->xpath->evaluate("count(preceding-sibling::rss:item)", $entries->item(0));
+                $this->entries[$offset] = $entry;
+            }
+            $this->idMappings[$id] = $entry;
+            return $entry;
+        }
+        return false;
+    }
+
+    /**
+     * Get details of the image associated with the feed.
+     *
+     * @return  array|false an array simply containing the child elements
+     */
+    protected function getImage()
+    {
+        $images = $this->model->getElementsByTagName('image');
+        if ($images->length > 0) {
+            $image = $images->item(0);
+            $details = array();
+            if ($image->hasChildNodes()) {
+                $details = array(
+                    'title' => $image->getElementsByTagName('title')->item(0)->value,
+                    'link' => $image->getElementsByTagName('link')->item(0)->value,
+                    'url' => $image->getElementsByTagName('url')->item(0)->value);
+            } else {
+                $details = array('title' => false,
+                    'link' => false,
+                    'url' => $image->attributes->getNamedItem('resource')->nodeValue);
+            }
+            $details = array_merge($details, array('description' => false, 'height' => false, 'width' => false));
+            if (! empty($details)) {
+                return $details;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * The textinput element is little used, but in the interests of
+     * completeness we will support it.
+     *
+     * @return  array|false
+     */
+    protected function getTextInput()
+    {
+        $inputs = $this->model->getElementsByTagName('textinput');
+        if ($inputs->length > 0) {
+            $input = $inputs->item(0);
+            $results = array();
+            $results['title'] = isset(
+                $input->getElementsByTagName('title')->item(0)->value) ? 
+                $input->getElementsByTagName('title')->item(0)->value : null;
+            $results['description'] = isset(
+                $input->getElementsByTagName('description')->item(0)->value) ? 
+                $input->getElementsByTagName('description')->item(0)->value : null;
+            $results['name'] = isset(
+                $input->getElementsByTagName('name')->item(0)->value) ? 
+                $input->getElementsByTagName('name')->item(0)->value : null;
+            $results['link'] = isset(
+                   $input->getElementsByTagName('link')->item(0)->value) ? 
+                   $input->getElementsByTagName('link')->item(0)->value : null;
+            if (empty($results['link']) and 
+                $input->attributes->getNamedItem('resource')) {
+                $results['link'] = 
+                    $input->attributes->getNamedItem('resource')->nodeValue;
+            }
+            if (! empty($results)) {
+                return $results;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Employs various techniques to identify the author
+     *
+     * Dublin Core provides the dc:creator, dc:contributor, and dc:publisher
+     * elements for defining authorship in RSS1. We will try each of those in
+     * turn in order to simulate the atom author element and will return it
+     * as text.
+     *
+     * @return  array|false
+     */
+    function getAuthor()
+    {
+        $options = array('creator', 'contributor', 'publisher');
+        foreach ($options as $element) {
+            $test = $this->model->getElementsByTagName($element);
+            if ($test->length > 0) {
+                return $test->item(0)->value;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * Retrieve a link
+     * 
+     * In RSS1 a link is a text element but in order to ensure that we resolve
+     * URLs properly we have a special function for them.
+     *
+     * @return  string
+     */
+    function getLink($offset = 0, $attribute = 'href', $params = false)
+    {
+        $links = $this->model->getElementsByTagName('link');
+        if ($links->length <= $offset) {
+            return false;
+        }
+        $link = $links->item($offset);
+        return $this->addBase($link->nodeValue, $link);
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS11.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS11.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS11.php	(revision 14676)
@@ -0,0 +1,276 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * RSS1.1 class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS11.php,v 1.6 2006/07/27 13:52:05 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This class handles RSS1.1 feeds. RSS1.1 is documented at:
+ * http://inamidst.com/rss1.1/
+ * 
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ * @todo    Support for RDF:List
+ * @todo    Ensure xml:lang is accessible to users
+ */
+class XML_Feed_Parser_RSS11 extends XML_Feed_Parser_Type
+{
+    /**
+     * The URI of the RelaxNG schema used to (optionally) validate the feed 
+     * @var string
+     */
+    private $relax = 'rss11.rnc';
+
+    /**
+     * We're likely to use XPath, so let's keep it global
+     * @var DOMXPath
+     */
+    protected $xpath;
+
+    /**
+     * The feed type we are parsing 
+     * @var string
+     */
+    public $version = 'RSS 1.0';
+
+    /**
+     * The class used to represent individual items 
+     * @var string
+     */
+    protected $itemClass = 'XML_Feed_Parser_RSS1Element';
+    
+    /**
+     * The element containing entries 
+     * @var string
+     */
+    protected $itemElement = 'item';
+
+    /**
+     * Here we map those elements we're not going to handle individually
+     * to the constructs they are. The optional second parameter in the array
+     * tells the parser whether to 'fall back' (not apt. at the feed level) or
+     * fail if the element is missing. If the parameter is not set, the function
+     * will simply return false and leave it to the client to decide what to do.
+     * @var array
+     */
+    protected $map = array(
+        'title' => array('Text'),
+        'link' => array('Text'),
+        'description' => array('Text'),
+        'image' => array('Image'),
+        'updatePeriod' => array('Text'),
+        'updateFrequency' => array('Text'),
+        'updateBase' => array('Date'),
+        'rights' => array('Text'), # dc:rights
+        'description' => array('Text'), # dc:description
+        'creator' => array('Text'), # dc:creator
+        'publisher' => array('Text'), # dc:publisher
+        'contributor' => array('Text'), # dc:contributor
+        'date' => array('Date') # dc:contributor
+        );
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS2.
+     * @var array
+     */
+    protected $compatMap = array(
+        'title' => array('title'),
+        'link' => array('link'),
+        'subtitle' => array('description'),
+        'author' => array('creator'),
+        'updated' => array('date'));
+
+    /**
+     * We will be working with multiple namespaces and it is useful to 
+     * keep them together. We will retain support for some common RSS1.0 modules
+     * @var array
+     */
+    protected $namespaces = array(
+        'rdf' => 'http://www.w3.org/1999/02/22-rdf-syntax-ns#',
+        'rss' => 'http://purl.org/net/rss1.1#',
+        'dc' => 'http://purl.org/rss/1.0/modules/dc/',
+        'content' => 'http://purl.org/rss/1.0/modules/content/',
+        'sy' => 'http://web.resource.org/rss/1.0/modules/syndication/');
+
+    /**
+     * Our constructor does nothing more than its parent.
+     * 
+     * @param    DOMDocument    $xml    A DOM object representing the feed
+     * @param    bool (optional) $string    Whether or not to validate this feed
+     */
+    function __construct(DOMDocument $model, $strict = false)
+    {
+        $this->model = $model;
+
+        if ($strict) {
+            $validate = $this->model->relaxNGValidate(self::getSchemaDir . 
+                DIRECTORY_SEPARATOR . $this->relax);
+            if (! $validate) {
+                throw new XML_Feed_Parser_Exception('Failed required validation');
+            }
+        }
+
+        $this->xpath = new DOMXPath($model);
+        foreach ($this->namespaces as $key => $value) {
+            $this->xpath->registerNamespace($key, $value);
+        }            
+        $this->numberEntries = $this->count('item');
+    }
+
+    /**
+     * Attempts to identify an element by ID given by the rdf:about attribute
+     *
+     * This is not really something that will work with RSS1.1 as it does not have
+     * clear restrictions on the global uniqueness of IDs. We will employ the
+     * _very_ hit and miss method of selecting entries based on the rdf:about
+     * attribute. Please note that this is even more hit and miss with RSS1.1 than
+     * with RSS1.0 since RSS1.1 does not require the rdf:about attribute for items.
+     *
+     * @param    string    $id    any valid ID.
+     * @return    XML_Feed_Parser_RSS1Element
+     */
+    function getEntryById($id)
+    {
+        if (isset($this->idMappings[$id])) {
+            return $this->entries[$this->idMappings[$id]];
+        }
+
+        $entries = $this->xpath->query("//rss:item[@rdf:about='$id']");
+        if ($entries->length > 0) {
+            $classname = $this->itemClass;
+            $entry = new $classname($entries->item(0), $this);
+            return $entry;
+        }
+        return false;
+    }
+
+    /**
+     * Get details of the image associated with the feed.
+     *
+     * @return  array|false an array simply containing the child elements
+     */
+    protected function getImage()
+    {
+        $images = $this->model->getElementsByTagName('image');
+        if ($images->length > 0) {
+            $image = $images->item(0);
+            $details = array();
+            if ($image->hasChildNodes()) {
+                $details = array(
+                    'title' => $image->getElementsByTagName('title')->item(0)->value,
+                    'url' => $image->getElementsByTagName('url')->item(0)->value);
+                if ($image->getElementsByTagName('link')->length > 0) {
+                    $details['link'] = 
+                        $image->getElementsByTagName('link')->item(0)->value;
+                }
+            } else {
+                $details = array('title' => false,
+                    'link' => false,
+                    'url' => $image->attributes->getNamedItem('resource')->nodeValue);
+            }
+            $details = array_merge($details, 
+                array('description' => false, 'height' => false, 'width' => false));
+            if (! empty($details)) {
+                return $details;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * The textinput element is little used, but in the interests of
+     * completeness we will support it.
+     *
+     * @return  array|false
+     */
+    protected function getTextInput()
+    {
+        $inputs = $this->model->getElementsByTagName('textinput');
+        if ($inputs->length > 0) {
+            $input = $inputs->item(0);
+            $results = array();
+            $results['title'] = isset(
+                $input->getElementsByTagName('title')->item(0)->value) ? 
+                $input->getElementsByTagName('title')->item(0)->value : null;
+            $results['description'] = isset(
+                $input->getElementsByTagName('description')->item(0)->value) ? 
+                $input->getElementsByTagName('description')->item(0)->value : null;
+            $results['name'] = isset(
+                $input->getElementsByTagName('name')->item(0)->value) ? 
+                $input->getElementsByTagName('name')->item(0)->value : null;
+            $results['link'] = isset(
+                   $input->getElementsByTagName('link')->item(0)->value) ? 
+                   $input->getElementsByTagName('link')->item(0)->value : null;
+            if (empty($results['link']) and 
+                $input->attributes->getNamedItem('resource')) {
+                $results['link'] = $input->attributes->getNamedItem('resource')->nodeValue;
+            }
+            if (! empty($results)) {
+                return $results;
+            }
+        }
+        return false;
+    }
+
+    /**
+     * Attempts to discern authorship
+     *
+     * Dublin Core provides the dc:creator, dc:contributor, and dc:publisher
+     * elements for defining authorship in RSS1. We will try each of those in
+     * turn in order to simulate the atom author element and will return it
+     * as text.
+     *
+     * @return  array|false
+     */
+    function getAuthor()
+    {
+        $options = array('creator', 'contributor', 'publisher');
+        foreach ($options as $element) {
+            $test = $this->model->getElementsByTagName($element);
+            if ($test->length > 0) {
+                return $test->item(0)->value;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * Retrieve a link
+     *
+     * In RSS1 a link is a text element but in order to ensure that we resolve
+     * URLs properly we have a special function for them.
+     *
+     * @return  string
+     */
+    function getLink($offset = 0, $attribute = 'href', $params = false)
+    {
+        $links = $this->model->getElementsByTagName('link');
+        if ($links->length <= $offset) {
+            return false;
+        }
+        $link = $links->item($offset);
+        return $this->addBase($link->nodeValue, $link);
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS2.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS2.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS2.php	(revision 14676)
@@ -0,0 +1,334 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * Class representing feed-level data for an RSS2 feed
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS2.php,v 1.11 2006/07/27 13:52:05 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This class handles RSS2 feeds.
+ * 
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_RSS2 extends XML_Feed_Parser_Type
+{
+    /**
+     * The URI of the RelaxNG schema used to (optionally) validate the feed
+     * @var string
+     */
+    private $relax = 'rss20.rnc';
+
+    /**
+     * We're likely to use XPath, so let's keep it global
+     * @var DOMXPath
+     */
+    protected $xpath;
+
+    /**
+     * The feed type we are parsing
+     * @var string
+     */
+    public $version = 'RSS 2.0';
+
+    /**
+     * The class used to represent individual items
+     * @var string
+     */     
+    protected $itemClass = 'XML_Feed_Parser_RSS2Element';
+    
+    /**
+     * The element containing entries 
+     * @var string
+     */
+    protected $itemElement = 'item';
+
+    /**
+     * Here we map those elements we're not going to handle individually
+     * to the constructs they are. The optional second parameter in the array
+     * tells the parser whether to 'fall back' (not apt. at the feed level) or
+     * fail if the element is missing. If the parameter is not set, the function
+     * will simply return false and leave it to the client to decide what to do.
+     * @var array
+     */
+    protected $map = array(
+        'ttl' => array('Text'),
+        'pubDate' => array('Date'),
+        'lastBuildDate' => array('Date'),
+        'title' => array('Text'),
+        'link' => array('Link'),
+        'description' => array('Text'),
+        'language' => array('Text'),
+        'copyright' => array('Text'),
+        'managingEditor' => array('Text'),
+        'webMaster' => array('Text'),
+        'category' => array('Text'),
+        'generator' => array('Text'),
+        'docs' => array('Text'),
+        'ttl' => array('Text'),
+        'image' => array('Image'),
+        'skipDays' => array('skipDays'),
+        'skipHours' => array('skipHours'));
+
+    /**
+     * Here we map some elements to their atom equivalents. This is going to be
+     * quite tricky to pull off effectively (and some users' methods may vary)
+     * but is worth trying. The key is the atom version, the value is RSS2.
+     * @var array
+     */
+    protected $compatMap = array(
+        'title' => array('title'),
+        'rights' => array('copyright'),
+        'updated' => array('lastBuildDate'),
+        'subtitle' => array('description'),
+        'date' => array('pubDate'),
+        'author' => array('managingEditor'));
+
+    protected $namespaces = array(
+        'dc' => 'http://purl.org/rss/1.0/modules/dc/',
+        'content' => 'http://purl.org/rss/1.0/modules/content/');
+
+    /**
+     * Our constructor does nothing more than its parent.
+     * 
+     * @param    DOMDocument    $xml    A DOM object representing the feed
+     * @param    bool (optional) $string    Whether or not to validate this feed
+     */
+    function __construct(DOMDocument $model, $strict = false)
+    {
+        $this->model = $model;
+
+        if ($strict) {
+            if (! $this->model->relaxNGValidate($this->relax)) {
+                throw new XML_Feed_Parser_Exception('Failed required validation');
+            }
+        }
+
+        $this->xpath = new DOMXPath($this->model);
+        foreach ($this->namespaces as $key => $value) {
+            $this->xpath->registerNamespace($key, $value);
+        }
+        $this->numberEntries = $this->count('item');
+    }
+
+    /**
+     * Retrieves an entry by ID, if the ID is specified with the guid element
+     *
+     * This is not really something that will work with RSS2 as it does not have
+     * clear restrictions on the global uniqueness of IDs. But we can emulate
+     * it by allowing access based on the 'guid' element. If DOMXPath::evaluate
+     * is available, we also use that to store a reference to the entry in the array
+     * used by getEntryByOffset so that method does not have to seek out the entry
+     * if it's requested that way.
+     *
+     * @param    string    $id    any valid ID.
+     * @return    XML_Feed_Parser_RSS2Element
+     */
+    function getEntryById($id)
+    {
+        if (isset($this->idMappings[$id])) {
+            return $this->entries[$this->idMappings[$id]];
+        }
+
+        $entries = $this->xpath->query("//item[guid='$id']");
+        if ($entries->length > 0) {
+            $entry = new $this->itemElement($entries->item(0), $this);
+            if (in_array('evaluate', get_class_methods($this->xpath))) {
+                $offset = $this->xpath->evaluate("count(preceding-sibling::item)", $entries->item(0));
+                $this->entries[$offset] = $entry;
+            }
+            $this->idMappings[$id] = $entry;
+            return $entry;
+        }        
+    }
+
+    /**
+     * Get a category from the element
+     *
+     * The category element is a simple text construct which can occur any number
+     * of times. We allow access by offset or access to an array of results.
+     *
+     * @param    string    $call    for compatibility with our overloading
+     * @param   array $arguments - arg 0 is the offset, arg 1 is whether to return as array
+     * @return  string|array|false
+     */
+    function getCategory($call, $arguments = array())
+    {
+        $categories = $this->model->getElementsByTagName('category');
+        $offset = empty($arguments[0]) ? 0 : $arguments[0];
+        $array = empty($arguments[1]) ? false : true;
+        if ($categories->length <= $offset) {
+            return false;
+        }
+        if ($array) {
+            $list = array();
+            foreach ($categories as $category) {
+                array_push($list, $category->nodeValue);
+            }
+            return $list;
+        }
+        return $categories->item($offset)->nodeValue;
+    }
+
+    /**
+     * Get details of the image associated with the feed.
+     *
+     * @return  array|false an array simply containing the child elements
+     */
+    protected function getImage()
+    {
+        $images = $this->model->getElementsByTagName('image');
+        if ($images->length > 0) {
+            $image = $images->item(0);
+            $desc = $image->getElementsByTagName('description');
+            $description = $desc->length ? $desc->item(0)->nodeValue : false;
+            $heigh = $image->getElementsByTagName('height'); 
+            $height = $heigh->length ? $heigh->item(0)->nodeValue : false;
+            $widt = $image->getElementsByTagName('width'); 
+            $width = $widt->length ? $widt->item(0)->nodeValue : false;
+            return array(
+                'title' => $image->getElementsByTagName('title')->item(0)->nodeValue,
+                'link' => $image->getElementsByTagName('link')->item(0)->nodeValue,
+                'url' => $image->getElementsByTagName('url')->item(0)->nodeValue,
+                'description' => $description,
+                'height' => $height,
+                'width' => $width);
+        }
+        return false;
+    }
+
+    /**
+     * The textinput element is little used, but in the interests of
+     * completeness...
+     *
+     * @return  array|false
+     */
+    function getTextInput()
+    {
+        $inputs = $this->model->getElementsByTagName('input');
+        if ($inputs->length > 0) {
+            $input = $inputs->item(0);
+            return array(
+                'title' => $input->getElementsByTagName('title')->item(0)->value,
+                'description' => 
+                    $input->getElementsByTagName('description')->item(0)->value,
+                'name' => $input->getElementsByTagName('name')->item(0)->value,
+                'link' => $input->getElementsByTagName('link')->item(0)->value);
+        }
+        return false;
+    }
+
+    /**
+     * Utility function for getSkipDays and getSkipHours
+     *
+     * This is a general function used by both getSkipDays and getSkipHours. It simply
+     * returns an array of the values of the children of the appropriate tag.
+     *
+     * @param   string      $tagName    The tag name (getSkipDays or getSkipHours)
+     * @return  array|false
+     */
+    protected function getSkips($tagName)
+    {
+        $hours = $this->model->getElementsByTagName($tagName);
+        if ($hours->length == 0) {
+            return false;
+        }
+        $skipHours = array();
+        foreach($hours->item(0)->childNodes as $hour) {
+            if ($hour instanceof DOMElement) {
+                array_push($skipHours, $hour->nodeValue);
+            }
+        }
+        return $skipHours;
+    }
+
+    /**
+     * Retrieve skipHours data
+     *
+     * The skiphours element provides a list of hours on which this feed should
+     * not be checked. We return an array of those hours (integers, 24 hour clock)
+     *
+     * @return  array
+     */    
+    function getSkipHours()
+    {
+        return $this->getSkips('skipHours');
+    }
+
+    /**
+     * Retrieve skipDays data
+     *
+     * The skipdays element provides a list of days on which this feed should
+     * not be checked. We return an array of those days.
+     *
+     * @return  array
+     */
+    function getSkipDays()
+    {
+        return $this->getSkips('skipDays');
+    }
+
+    /**
+     * Return content of the little-used 'cloud' element
+     *
+     * The cloud element is rarely used. It is designed to provide some details
+     * of a location to update the feed.
+     *
+     * @return  array   an array of the attributes of the element
+     */
+    function getCloud()
+    {
+        $cloud = $this->model->getElementsByTagName('cloud');
+        if ($cloud->length == 0) {
+            return false;
+        }
+        $cloudData = array();
+        foreach ($cloud->item(0)->attributes as $attribute) {
+            $cloudData[$attribute->name] = $attribute->value;
+        }
+        return $cloudData;
+    }
+    
+    /**
+     * Get link URL
+     *
+     * In RSS2 a link is a text element but in order to ensure that we resolve
+     * URLs properly we have a special function for them. We maintain the 
+     * parameter used by the atom getLink method, though we only use the offset
+     * parameter.
+     *
+     * @param   int     $offset The position of the link within the feed. Starts from 0
+     * @param   string  $attribute  The attribute of the link element required
+     * @param   array   $params An array of other parameters. Not used.
+     * @return  string
+     */
+    function getLink($offset, $attribute = 'href', $params = array())
+    {
+        $links = $this->model->getElementsByTagName('link');
+
+        if ($links->length <= $offset) {
+            return false;
+        }
+        $link = $links->item($offset);
+        return $this->addBase($link->nodeValue, $link);
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/AtomElement.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/AtomElement.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/AtomElement.php	(revision 14676)
@@ -0,0 +1,261 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * AtomElement class for XML_Feed_Parser package
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: AtomElement.php,v 1.19 2007/03/26 12:43:11 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/**
+ * This class provides support for atom entries. It will usually be called by
+ * XML_Feed_Parser_Atom with which it shares many methods.
+ *
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_AtomElement extends XML_Feed_Parser_Atom
+{
+    /**
+     * This will be a reference to the parent object for when we want
+     * to use a 'fallback' rule 
+     * @var XML_Feed_Parser_Atom
+     */
+    protected $parent;
+
+    /**
+     * When performing XPath queries we will use this prefix 
+     * @var string
+     */
+    private $xpathPrefix = '';
+    
+    /**
+     * xml:base values inherited by the element 
+     * @var string
+     */
+    protected $xmlBase;
+
+    /**
+     * Here we provide a few mappings for those very special circumstances in
+     * which it makes sense to map back to the RSS2 spec or to manage other
+     * compatibilities (eg. with the Univeral Feed Parser). Key is the other version's
+     * name for the command, value is an array consisting of the equivalent in our atom 
+     * api and any attributes needed to make the mapping.
+     * @var array
+     */
+    protected $compatMap = array(
+        'guid' => array('id'),
+        'links' => array('link'),
+        'tags' => array('category'),
+        'contributors' => array('contributor'));
+        
+    /**
+     * Our specific element map 
+     * @var array
+     */
+    protected $map = array(
+        'author' => array('Person', 'fallback'),
+        'contributor' => array('Person'),
+        'id' => array('Text', 'fail'),
+        'published' => array('Date'),
+        'updated' => array('Date', 'fail'),
+        'title' => array('Text', 'fail'),
+        'rights' => array('Text', 'fallback'),
+        'summary' => array('Text'),
+        'content' => array('Content'),
+        'link' => array('Link'),
+        'enclosure' => array('Enclosure'),
+        'category' => array('Category'));
+
+    /**
+     * Store useful information for later.
+     *
+     * @param   DOMElement  $element - this item as a DOM element
+     * @param   XML_Feed_Parser_Atom    $parent - the feed of which this is a member
+     */
+    function __construct(DOMElement $element, $parent, $xmlBase = '')
+    {
+        $this->model = $element;
+        $this->parent = $parent;
+        $this->xmlBase = $xmlBase;
+        $this->xpathPrefix = "//atom:entry[atom:id='" . $this->id . "']/";
+        $this->xpath = $this->parent->xpath;
+    }
+
+    /**
+     * Provides access to specific aspects of the author data for an atom entry
+     *
+     * Author data at the entry level is more complex than at the feed level.
+     * If atom:author is not present for the entry we need to look for it in
+     * an atom:source child of the atom:entry. If it's not there either, then
+     * we look to the parent for data.
+     *
+     * @param   array
+     * @return  string
+     */
+    function getAuthor($arguments)
+    {
+        /* Find out which part of the author data we're looking for */
+        if (isset($arguments['param'])) {
+            $parameter = $arguments['param'];
+        } else {
+            $parameter = 'name';
+        }
+        
+        $test = $this->model->getElementsByTagName('author');
+        if ($test->length > 0) {
+            $item = $test->item(0);
+            return $item->getElementsByTagName($parameter)->item(0)->nodeValue;
+        }
+        
+        $source = $this->model->getElementsByTagName('source');
+        if ($source->length > 0) {
+            $test = $this->model->getElementsByTagName('author');
+            if ($test->length > 0) {
+                $item = $test->item(0);
+                return $item->getElementsByTagName($parameter)->item(0)->nodeValue;
+            }
+        }
+        return $this->parent->getAuthor($arguments);
+    }
+
+    /**
+     * Returns the content of the content element or info on a specific attribute
+     *
+     * This element may or may not be present. It cannot be present more than
+     * once. It may have a 'src' attribute, in which case there's no content
+     * If not present, then the entry must have link with rel="alternate".
+     * If there is content we return it, if not and there's a 'src' attribute
+     * we return the value of that instead. The method can take an 'attribute'
+     * argument, in which case we return the value of that attribute if present.
+     * eg. $item->content("type") will return the type of the content. It is
+     * recommended that all users check the type before getting the content to
+     * ensure that their script is capable of handling the type of returned data.
+     * (data carried in the content element can be either 'text', 'html', 'xhtml', 
+     * or any standard MIME type).
+     *
+     * @return  string|false
+     */
+    protected function getContent($method, $arguments = array())
+    {
+        $attribute = empty($arguments[0]) ? false : $arguments[0];
+        $tags = $this->model->getElementsByTagName('content');
+
+        if ($tags->length == 0) {
+            return false;
+        }
+
+        $content = $tags->item(0);
+
+        if (! $content->hasAttribute('type')) {
+            $content->setAttribute('type', 'text');
+        }
+        if (! empty($attribute)) {
+            return $content->getAttribute($attribute);
+        }
+
+        $type = $content->getAttribute('type');
+
+        if (! empty($attribute)) {
+            if ($content->hasAttribute($attribute))
+            {
+                return $content->getAttribute($attribute);
+            }
+            return false;
+        }
+
+        if ($content->hasAttribute('src')) {
+            return $content->getAttribute('src');
+        }
+
+        return $this->parseTextConstruct($content);
+     }
+
+    /**
+     * For compatibility, this method provides a mapping to access enclosures.
+     *
+     * The Atom spec doesn't provide for an enclosure element, but it is
+     * generally supported using the link element with rel='enclosure'.
+     *
+     * @param   string  $method - for compatibility with our __call usage
+     * @param   array   $arguments - for compatibility with our __call usage
+     * @return  array|false
+     */
+    function getEnclosure($method, $arguments = array())
+    {
+        $offset = isset($arguments[0]) ? $arguments[0] : 0;
+        $query = "//atom:entry[atom:id='" . $this->getText('id', false) . 
+            "']/atom:link[@rel='enclosure']";
+
+        $encs = $this->parent->xpath->query($query);
+        if ($encs->length > $offset) {
+            try {
+                if (! $encs->item($offset)->hasAttribute('href')) {
+                    return false;
+                }
+                $attrs = $encs->item($offset)->attributes;
+                $length = $encs->item($offset)->hasAttribute('length') ? 
+                    $encs->item($offset)->getAttribute('length') : false;
+                return array(
+                    'url' => $attrs->getNamedItem('href')->value,
+                    'type' => $attrs->getNamedItem('type')->value,
+                    'length' => $length);
+            } catch (Exception $e) {
+                return false;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * Get details of this entry's source, if available/relevant
+     *
+     * Where an atom:entry is taken from another feed then the aggregator
+     * is supposed to include an atom:source element which replicates at least
+     * the atom:id, atom:title, and atom:updated metadata from the original
+     * feed. Atom:source therefore has a very similar structure to atom:feed
+     * and if we find it we will return it as an XML_Feed_Parser_Atom object.
+     *
+     * @return  XML_Feed_Parser_Atom|false
+     */
+    function getSource()
+    {
+        $test = $this->model->getElementsByTagName('source');
+        if ($test->length == 0) {
+            return false;
+        }
+        $source = new XML_Feed_Parser_Atom($test->item(0));
+    }
+
+    /**
+     * Get the entry as an XML string
+     *
+     * Return an XML serialization of the feed, should it be required. Most 
+     * users however, will already have a serialization that they used when 
+     * instantiating the object.
+     *
+     * @return    string    XML serialization of element
+     */    
+    function __toString()
+    {
+        $simple = simplexml_import_dom($this->model);
+        return $simple->asXML();
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS09Element.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS09Element.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/RSS09Element.php	(revision 14676)
@@ -0,0 +1,62 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * RSS0.9 Element class for XML_Feed_Parser
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL 2.1
+ * @version    CVS: $Id: RSS09Element.php,v 1.4 2006/06/30 17:41:56 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+
+/*
+ * This class provides support for RSS 0.9 entries. It will usually be called by
+ * XML_Feed_Parser_RSS09 with which it shares many methods.
+ *
+ * @author    James Stewart <james@jystewart.net>
+ * @version    Release: 1.0.2
+ * @package XML_Feed_Parser
+ */
+class XML_Feed_Parser_RSS09Element extends XML_Feed_Parser_RSS09
+{
+    /**
+     * This will be a reference to the parent object for when we want
+     * to use a 'fallback' rule 
+     * @var XML_Feed_Parser_RSS09
+     */
+    protected $parent;
+
+    /**
+     * Our specific element map 
+     * @var array
+     */
+    protected $map = array(
+        'title' => array('Text'),
+        'link' => array('Link'));
+
+    /**
+     * Store useful information for later.
+     *
+     * @param   DOMElement  $element - this item as a DOM element
+     * @param   XML_Feed_Parser_RSS1 $parent - the feed of which this is a member
+     */
+    function __construct(DOMElement $element, $parent, $xmlBase = '')
+    {
+        $this->model = $element;
+        $this->parent = $parent;
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Exception.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Exception.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/Lib/XML/Feed/Parser/Exception.php	(revision 14676)
@@ -0,0 +1,42 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * Keeps the exception class for XML_Feed_Parser.
+ *
+ * PHP versions 5
+ *
+ * LICENSE: This source file is subject to version 3.0 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   XML
+ * @package    XML_Feed_Parser
+ * @author     James Stewart <james@jystewart.net>
+ * @copyright  2005 James Stewart <james@jystewart.net>
+ * @license    http://www.gnu.org/copyleft/lesser.html  GNU LGPL
+ * @version    CVS: $Id: Exception.php,v 1.3 2005/11/07 01:52:35 jystewart Exp $
+ * @link       http://pear.php.net/package/XML_Feed_Parser/
+ */
+ 
+/**
+ * We are extending PEAR_Exception
+ */
+require_once 'PEAR/Exception.php';
+
+/**
+ * XML_Feed_Parser_Exception is a simple extension of PEAR_Exception, existing
+ * to help with identification of the source of exceptions.
+ *
+ * @author  James Stewart <james@jystewart.net>
+ * @version Release: 1.0.2
+ * @package XML_Feed_Parser
+ */ 
+class XML_Feed_Parser_Exception extends PEAR_Exception
+{
+
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Subscription/Simple.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Subscription/Simple.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Subscription/Simple.php	(revision 14676)
@@ -0,0 +1,32 @@
+<?php
+
+require_once('LLReader/Plugin.php');
+require_once('LLReader/Feed.php');
+
+class LLReader_Plugin_Subscription_Simple extends LLReader_Plugin {
+    public function execute ($llr) {
+        $config = $this->get_config();
+        $urls   = array();
+        
+        if ( is_array($config['urls']) ) {
+            $urls = $config['urls'];
+        }
+        else {
+            $urls = array($config['urls']);
+        }
+        
+        foreach ( $urls as $url ) {
+            $xml = file_get_contents($url);
+            
+            try {
+                $feed = new LLReader_Feed($xml);
+                $llr->add_feed($feed);
+            }
+            catch ( XML_Feed_Parser_Exception $e ) {
+                $llr->log('[Warning] Feed invalid: ' . $e->getMessage());
+            }
+        }
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Filter/SearchEntry2Feed.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Filter/SearchEntry2Feed.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Filter/SearchEntry2Feed.php	(revision 14676)
@@ -0,0 +1,63 @@
+<?php
+
+require_once('LLReader/Plugin.php');
+
+class LLReader_Plugin_Filter_SearchEntry2Feed extends LLReader_Plugin {
+    public function execute ($llr) {
+        $config = $this->get_config();
+        $maches_entries = array();
+        
+        $feeds = $llr->get_feeds();
+        foreach ( $feeds as $feed ) {
+            
+            $err_rep = ini_get('error_reporting');
+            error_reporting(E_ALL ^ E_NOTICE);
+            
+            foreach ( $feed as $entry ) {
+                
+                $pattern = mb_convert_encoding($config['regex'], 'UTF-8', 'EUC-JP, SJIS, UTF-8');
+                if ( preg_match_all($pattern , $entry->title, $maches) ) {
+                    $maches_entries[] = $entry;
+                    $llr->log(mb_convert_encoding($feed->title,  'EUC-JP', 'UTF-8')
+                             . ':' . mb_convert_encoding($entry->title, 'EUC-JP', 'UTF-8'));
+                }
+                else {
+                    
+                } 
+            }
+            
+            error_reporting($err_rep);
+        }
+        //new LLReader_Feed($maches_entries[0]->__toString());
+        //$llr->p(mb_convert_encoding($maches_entries[0]->title, 'EUC-JP', 'UTF-8'));
+    }
+    
+    private function entry2feed ($llr, $feed, $entries) {
+        $output = "<?xml version=\"1.0\"?>
+                    <rss version=\"2.0\">
+                        <channel>
+                            <title>{$feed->title}</title>
+                            <link>http://www.tracypeterson.com/RSS/RSS.php</link>
+                            <description>$feed->description</description>
+                            <language>$feed->language</language>
+                            <pubDate>$feed->date</pubDate>
+                            <lastBuildDate>$feed->lastBuildDate</lastBuildDate>
+                            <docs>http://someurl.com</docs>
+                            <managingEditor>you@youremail.com</managingEditor>
+                            <webMaster>you@youremail.com</webMaster>
+                    ";
+                    
+        foreach ($entries as $entry)
+        {
+            $output .= "<item><title>" . $entry->title . "</title>
+                            <link>" . $entry->link . "</link>
+                            
+        <description>".htmlentities(strip_tags($line['description']))."</description>
+                        </item>";
+        }
+        
+        return new LLReader_Feed($output);
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Publish/Debug.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Publish/Debug.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader/Plugin/Publish/Debug.php	(revision 14676)
@@ -0,0 +1,12 @@
+<?php
+
+require_once('LLReader/Plugin.php');
+
+class LLReader_Plugin_Publish_Debug extends LLReader_Plugin {
+    public function execute ($llr) {
+        $config = $this->get_config();
+        //$llr->p($llr->get_feeds());
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader/Util.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader/Util.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader/Util.php	(revision 14676)
@@ -0,0 +1,23 @@
+<?php
+
+class LLReader_Util {
+    public static function log ($msg) {
+        echo $msg . "\n";
+    }
+
+    public static function p ($var, $var_dump = true) {
+        echo "++++++++ debug start ++++++++\n";
+
+        if ($var_dump) {
+            var_dump($var);
+        }
+        else {
+            print_r($var);
+        }
+
+        echo "++++++++ debug end ++++++++\n";
+    }
+
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader/Plugin.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader/Plugin.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader/Plugin.php	(revision 14676)
@@ -0,0 +1,18 @@
+<?php
+
+abstract class LLReader_Plugin {
+    protected $config;
+    
+    public function __construct ($llr, $config) {
+        $this->config = $config;
+    }
+    
+    abstract public function execute ($llr);
+    
+    protected function get_config () {
+        return $this->config;
+    }
+    
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader/Feed.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader/Feed.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader/Feed.php	(revision 14676)
@@ -0,0 +1,12 @@
+<?php
+
+require_once('XML/Feed/Parser.php');
+ 
+class LLReader_Feed extends XML_Feed_Parser {
+    public static function entries2feed ($entries, $feed = null, $feed_info = array()) {
+        $xml = '';
+        return new LLReader_Feed($xml);
+    }
+}
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/pless_release.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/pless_release.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/pless_release.php	(revision 14676)
@@ -0,0 +1,31 @@
+<?php
+
+$_path1 = '/home/web/dev.ec-cube.net/html/test/adachi/LLReader';
+$_path2 = '/home/web/dev.ec-cube.net/html/test/adachi/LLReader/Lib';
+
+$_ps = PATH_SEPARATOR;
+$_include_path = ini_get('include_path') . $_ps . $_path1 . $_ps . $_path2;
+
+ini_set('include_path', $_include_path);
+
+require_once('LLReader.php');
+
+$config = array(
+    'plugins' => array(
+        'Subscription_Simple' => array(
+            'urls' => array(
+                'http://feeds.feedburner.jp/cnet/rss', //cnet
+                'http://rss.rssad.jp/rss/itm/rss.xml', //@IT
+                'http://rss.rssad.jp/rss/itm/1.0/topstory.xml' //ITmedia
+            )
+        ),
+        'Filter_SearchEntry2Feed' => array(
+            'regex' => '/google/i'
+        ),
+    )
+);
+ 
+$LLR = new LLReader($config);
+$LLR->run();
+
+?>
Index: /branches/beta/html/test/adachi/LLReader/LLReader.php
===================================================================
--- /branches/beta/html/test/adachi/LLReader/LLReader.php	(revision 14676)
+++ /branches/beta/html/test/adachi/LLReader/LLReader.php	(revision 14676)
@@ -0,0 +1,97 @@
+<?php
+require_once('LLReader/Util.php');
+//require_once('LLReader/Constant.php');
+
+class LLReader {
+    private $config;
+    private $plugins;
+    private $feeds;
+    private $update_feeds;
+    
+    public function __construct($config){
+        $this->config  = $config;
+        $this->plugins = array();
+        $this->feeds   = array();
+        $this->update_feeds = array();
+    }
+    
+    public function run () {
+        $this->load_plugins();
+        
+        $phases = array(
+            'Subscription',
+            'Filter',
+            'Publish'
+        );
+        
+        foreach ( $phases as $phase ) {
+            $plugins = $this->get_plugins($phase);
+            
+            foreach ( $plugins as $plugin ) {
+                $plugin->execute($this);
+            }
+        }
+    }
+    
+    private function load_plugins () {
+        foreach ($this->config['plugins'] as $name => $config) {
+            $class   = 'LLReader_Plugin_' . $name;
+            $include = preg_replace('/_/', '/', $class) . '.php';
+            $ret     = include_once($include);
+            
+            $err = 0;
+            
+            if ($ret) {
+                if ( preg_match("/^(.+?)_/", $name, $matches) ) {
+                    $phase = $matches[1];
+                    $this->plugins[$phase][] = new $class($this, $config);
+                    $this->log('[OK] ' . $class . ' loaded');
+                }
+                else {
+                    $this->log('[ERR] ' . 'class name is invalid: ' . $class);
+                    $err++;
+                }
+            }
+            else {
+                $this->log('[ERR] ' . $class . ' not found');
+                $err++;
+            }
+        }
+        
+        if ($err) {
+            $this->_die('function load_plugins()');
+        }
+    }
+    
+    public function log ($msg) {
+        LLReader_Util::log($msg);
+    }
+    
+    public function p ($var) {
+        LLReader_Util::p($var);
+    }
+    
+    public function _die ($msg) {
+        $this->log('[DIE] ' . $msg);
+        exit();
+    }
+    
+    private function get_plugins ($phase) {
+        if ( empty($this->plugins[$phase]) ) {
+            return array();
+        }
+        return $this->plugins[$phase];
+    }
+    
+    public function get_feeds () {
+        if ( count($this->update_feeds) > 0 ) {
+            return $this->update_feeds;
+        }
+        return $this->feeds;
+    }
+    
+    public function add_feed ($feed) {
+        $this->feeds[] = $feed;
+    }
+}
+?>
Index: /branches/beta/html/test/adachi/SC_Param.php
===================================================================
--- /branches/beta/html/test/adachi/SC_Param.php	(revision 14676)
+++ /branches/beta/html/test/adachi/SC_Param.php	(revision 14676)
@@ -0,0 +1,55 @@
+<?php
+/**
+ * ¸Ä¡¹¤Î¥Ñ¥é¥á¡¼¥¿¤ò´ÉÍý¤¹¤ë¥¯¥é¥¹
+ */
+class SC_Param {
+    var $_keyname;
+    var $_dispname;
+    var $_value;
+    var $_group;
+    var $_parent;
+    var $_file;
+    var $_convert;
+    var $_validate;
+    var $_javascript;
+    
+    function SC_Param($arrParamInfo){
+        $this->_init($arrParamInfo);
+    }
+    
+    function _init($arrParamInfo){
+        $arrProperties = array_keys(get_object_vars($this));
+        
+        foreach ($arrProperties as $property) {
+            $this->$property = isset($arrParamInfo[$property])
+                ? $this->$property = $arrParamInfo[preg_replace('/^_/', '', $property)]
+                : $this->$property = null;
+        }
+    }
+    
+    function getEscapeValue($CHAR_CODE = CHAR_CODE){
+        return htmlspecialchars($this->_value, ENT_QUOTES, $CHAR_CODE);
+    }
+    
+    function getValue(){
+        return $this->_value;
+    }
+    
+    function convert(){
+        $this->_value = mb_convert_kana($this->_value, $this->$_convert);
+    }
+    
+    function getKeyName(){
+        return $this->_keyname;
+    }
+    
+    function getDispName(){
+        return $this->_dispname;
+    }
+    
+    function is_file(){
+        return $this->_file == true ? true : false;
+    }
+    
+}
+?>
Index: /branches/beta/html/test/adachi/SC_FormParamsManager.php
===================================================================
--- /branches/beta/html/test/adachi/SC_FormParamsManager.php	(revision 14676)
+++ /branches/beta/html/test/adachi/SC_FormParamsManager.php	(revision 14676)
@@ -0,0 +1,209 @@
+<?php
+
+require_once('SC_Param.php');
+require_once('SC_Validator.php');
+/**
+ * Form¥Ñ¥é¥á¡¼¥¿´ÉÍý¥¯¥é¥¹
+ */
+class SC_FormParamsManager {
+    var $_arrObjParams;
+    var $_arrErrorMessage;
+    var $_arrGropus;
+    
+    function SC_FormParamsManager($arrParams = array(), $arrParamsInfo = array()){
+        $this->_arrObjParams    = array();
+        $this->_arrErrorMessage = array();
+        $this->_arrGropus       = array();
+        
+        $this->setParams($arrParams, $arrParamsInfo);
+    }
+    
+    function setParams($arrParams, $arrParamsInfo, $useRawParams = false){
+        foreach ($arrParamsInfo as $_key => $_value) {
+            $arrParamsInfo[$_key]['value'] = $arrParams[$_key];
+            $this->_arrObjParams[] = new SC_Param($arrParamsInfo[$_key]);
+        }
+        // $_POST¡¢$_GET¤Ï¸¶Â§»ÈÍÑ¶Ø»ß(ÊÌ¥á¥½¥Ã¥É¤Ë¤¹¤ë¡©)
+        if ($useRawParams === true) { return; }
+        unset($_POST, $_GET);
+    }
+    
+    function serGroups($groupName, $arrTargetName, $arrValidateMethod){
+        foreach ($arrTargetName as $targetName) {
+            $this->_arrObjParams['group'] = $groupName:
+        );
+        $this->_arrGroups[$groupName]['validateMethd'] = $arrValidateMethod
+    }
+    
+    function validate(){
+        $arrErrorMessage = array();  // ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸³ÊÇ¼ÍÑÇÛÎó
+        $arrGroups = $this->_arrGroups;        // Ê£¿ô¹àÌÜ¸¡¾ÚÍÑÇÛÎó
+        
+        foreach ($this->_arrObjParams as $objParam) {
+            $keyname = $objParam->getKeyName();
+            
+            // Ê£¿ô¹àÌÜ¸¡¾ÚÍÑÇÛÎó¤ò¹½ÃÛ
+            /*
+            if ($objParam->has_group() === true) {
+                $arrGroups[$objParam->getGroupName()][] = $objParam;
+            }
+            */
+            
+            $arrValidateMethod = $objParam->getValidateMethod();
+            
+            // Ã±ÂÎ¹àÌÜ¤Î¸¡¾Ú
+            foreach ($arrValidateMethod as $method => $args) {
+                $objValidator = SC_Validator::factory($method, $args);
+                
+                if ($objValidator->validate($objParam) === false) {
+                    $arrErrorMessage[$keyname] = $objValidator->getErrorMessage();
+                }
+            }
+        }
+        
+        // Ê£¿ô¹àÌÜ¤Î¸¡¾Ú
+        foreach ($arrGroups as $groupname => $objParam) {
+            $keyname = $objParam->getKeyName();
+            
+            // ´û¤Ë¥¨¥é¡¼¤¬¤¢¤ë¾ì¹ç¤Ïvalidation¤ò¹Ô¤ï¤Ê¤¤
+            if (array_key_exists($keyname, $arrErrorMessage)) {
+                continue;
+            }
+            
+            $arrValidateMethod = $objParam->getGroupValidateMethod();
+            $objValidator = SC_Validate::factory('GROUP');
+            if ($objValidator->validate($arrGroups[$group]) === true) {
+                $this->arrErr[$group] = $objValidator->getErrorMessage();
+            }
+        }
+        
+        return $arrErrorMessage;
+    }
+    
+    function convert(){
+        foreach ($this->_arrObjParams as &$objParams) {
+            $objParams->convert();
+        }
+    }
+    function is_error(){
+        if (count($this->_arrErrorMessage) > 0) {
+            return true;
+        } else {
+            return false;
+        }
+    }
+    
+    function getEM(){
+        return $this->getErrorMessage();
+    }
+    
+    function getErrorMessage(){
+        $arrErr = array();
+        foreach ($this->_arrParamsInfo as $_key => $objParam) {
+            if ($onjParam->isRelation === true) {
+                $arrErr[$_key] = $objParam->getRelateErrorMessage();
+            } else {
+                $arrErr[$_key] = $objParam->getErrorMessage();
+            }
+        }
+        return $arrErr;
+    }
+    /**
+     *  static method
+     *  SC_Form::getMode();
+     */
+    function getMode(){
+        $mode = '';
+        
+        if (isset($_POST['mode'])) {
+            $mode = $_POST['mode'];
+        }
+        elseif (isset($_GET['mode'])) {
+            $mode = $_GET['mode'];
+        }
+        
+        return $mode;
+    }
+    
+    function &getObjQuery(){
+        return $this->_objQuery;
+    }
+    
+    function &initObjQuery(){
+        $this->_objQuery = new SC_Query();
+        return $this->_objQuery;
+    }
+    
+    function valiadte(){
+        return $this->objValidate->validate($this->_arrParamsInfo);
+    }
+    
+    function insert($table, $arrAddInsertData = array()){
+        $this->_setDBData($this->arrParams);
+        $this->_objQuery->insert($table, $this->_arrDBData);
+    }
+    
+    function update($table, $arrAddUpdateData = array()) {
+        
+    }
+    
+
+    
+    /**
+     *  ¥Ñ¥é¥á¡¼¥¿¤ò¼èÆÀ¤¹¤ë
+     *
+     *  @access  public
+     *  @param   boolean $escape  true:¥¨¥¹¥±¡¼¥×¤¹¤ë false:¥¨¥¹¥±¡¼¥×¤·¤Ê¤¤
+     *  @param   array   $arrNonEscape ¥¨¥¹¥±¡¼¥×¤·¤Ê¤¤ÃÍ¤òÇÛÎó¤Ç»ØÄê
+     *  
+     *  @return  array | string
+     */
+    function getParams($arrNonEscape = array()){
+        $arrParams = array();
+        if (!is_array($arrNonEscape)) { $arrNonEscape = (array)$arrNonEscape; }
+        
+        foreach ($this->_arrParams as $_key => $_value) {
+            if (isset($arrNonEscape[$_key]) && $arrNonEscape[$_key] == $_key) {
+                $arrRet[$key] = $objParam->getValue();
+            }
+            else {
+                $arrRet[$key] = $objParam->getEscapeValue();
+                
+            }
+        }
+            
+        return $arrParams;
+    }
+    
+    function getParamByKeyName($keyName, $escape = true){
+        if ($escape === true) {
+            return $this->_arrParams[$keyName]->getValue();
+        }
+        else {
+            return $this->_arrParams[$keyName]->getEscapedValue();
+        }
+    }
+    
+    function _setDBData($arrData = array()){
+        foreach ($arrData as $key => $value) {
+            if (is_array($value['value'])) {
+                $count = 1;
+                foreach ($value['value'] as $val) {
+                    $this->_arrDBData[$key . $count] = $val;
+                    $count++;
+                }
+            }
+            else {
+                $this->_arrDBData[$key] = $value['value'];
+            }
+        }
+    }
+    function _addDBData(){
+        
+    }
+    
+    function _getEscapeParams($string){
+        
+    }
+}
+?>
Index: /branches/beta/html/test/adachi/templates/test2.tpl
===================================================================
--- /branches/beta/html/test/adachi/templates/test2.tpl	(revision 14676)
+++ /branches/beta/html/test/adachi/templates/test2.tpl	(revision 14676)
@@ -0,0 +1,1 @@
+test
Index: /branches/beta/html/test/adachi/templates/test3.tpl
===================================================================
--- /branches/beta/html/test/adachi/templates/test3.tpl	(revision 14676)
+++ /branches/beta/html/test/adachi/templates/test3.tpl	(revision 14676)
@@ -0,0 +1,10 @@
+<html>
+<body>
+<!--{$test1}-->
+<!--{$test2|escape}-->
+<!--{foreach from=$arr item=int}-->
+<!--{$int}-->
+<!--{/foreach}-->
+< script >alert('hello')< /script >
+</body>
+<html>
Index: /branches/beta/html/test/adachi/SC_Validator.php
===================================================================
--- /branches/beta/html/test/adachi/SC_Validator.php	(revision 14676)
+++ /branches/beta/html/test/adachi/SC_Validator.php	(revision 14676)
@@ -0,0 +1,48 @@
+<?php
+/**
+ *  validation¥¯¥é¥¹
+ */
+class SC_Validator {
+    var $_error;
+    var $_errorMessage;
+    
+    /**
+     *  
+     *  
+     *  @param string $method ¼Â»Ü¤¹¤ëvalidationÌ¾
+     *  @param mixed  $args   validation¤ËÉ¬Í×¤Ê°ú¿ô
+     *  
+     *  @return object SC_Validator_$method
+     *  @example $objValidator = SC_Validator::factory('MAX', 20);
+     */
+    function factory($method, $args = null){
+        $class = 'SC_Validator_' . $method;
+        require_once('SC_Validator/' . $method . '.php');
+        
+        return new $class($args);
+    }
+    
+    /**
+     *  
+     *  
+     *  @param object SC_Param
+     *  
+     *  @return void
+     */
+    function validate($objParam){}
+    
+    function is_error(){
+        return $this->_error;
+    }
+    
+    function is_ok(){
+        $bool = true;
+        if ($this->is_error()) { $bool = false; }
+        
+        return $bool;
+    }
+    
+    
+    function getErrorMessage(){}
+}
+?>
Index: /branches/beta/html/test/adachi/zen2cube.php
===================================================================
--- /branches/beta/html/test/adachi/zen2cube.php	(revision 14676)
+++ /branches/beta/html/test/adachi/zen2cube.php	(revision 14676)
@@ -0,0 +1,33 @@
+<?php
+/**
+ *  zencart¤«¤éec-cube¤Ø¤Î¾¦ÉÊ¥Ç¡¼¥¿°Ü¹Ô¥¹¥¯¥ê¥×¥È(»ÃÄê)
+ */
+
+require_once("../../require.php");
+
+// zencart¤ÎDSN¤òÀßÄê
+$zen_db_dsn = 'mysql://root:password@localhost/zencart_db';
+
+lfConvertProducts();
+
+function lfGetObjQuery($dsn = ''){
+    global $zen_db_dsn;
+    if (strtolower($dsn) == 'zen') {
+        $dsn = $zen_db_dsn;
+    }
+    return new SC_Query($dsn, true, true);
+}
+
+function lfConvertProducts(){
+    $arrError = 0;
+    
+    $ZenQuery  = lfGetObjQuery('zen');
+    $CubeQuery = lfGetObjQuery();
+    
+    $z_tbl_products = 'products';
+    $z_tbl_customers_info = 'customers_info';
+    $z_tbl_customers_wishlist = 'customers_wishlist';
+    
+    $arrRet = $CubeQuery->select('*', 'vw_products_allclass_detail');
+    sfprintr($arrRet);
+}
Index: /branches/beta/html/test/kakinaka/templates/index.tpl
===================================================================
--- /branches/beta/html/test/kakinaka/templates/index.tpl	(revision 17)
+++ /branches/beta/html/test/kakinaka/templates/index.tpl	(revision 14676)
@@ -9,5 +9,5 @@
 	<tr>
 		<td bgcolor="#ffffff" align="left">
-			<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$smarty.const.IMAGE_TEMP_DIR}-->kaki.jpg" alt="¥°¥é¥Õ">
+			<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$smarty.const.IMAGE_TEMP_DIR}-->kaki.jpg" alt="¥°¥é¥Õ">
 		</td>
 	</tr>
Index: /branches/beta/html/test/kakinaka/templates/utf.tpl
===================================================================
--- /branches/beta/html/test/kakinaka/templates/utf.tpl	(revision 377)
+++ /branches/beta/html/test/kakinaka/templates/utf.tpl	(revision 14676)
@@ -38,5 +38,5 @@
 	<tr>
 		<td bgcolor="#ffffff" align="left">
-			<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$smarty.const.IMAGE_TEMP_DIR}-->kaki.jpg" alt="¥°¥é¥Õ">
+			<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$smarty.const.IMAGE_TEMP_DIR}-->kaki.jpg" alt="¥°¥é¥Õ">
 		</td>
 	</tr>
Index: /branches/beta/html/test/naka/info.php
===================================================================
--- /branches/beta/html/test/naka/info.php	(revision 12172)
+++ /branches/beta/html/test/naka/info.php	(revision 14676)
@@ -2,4 +2,10 @@
     require_once("../../require.php");
     phpinfo();
+      
+    
+    
+    
+    
+    
     
 ?>
Index: /branches/beta/html/test/naka/test.php
===================================================================
--- /branches/beta/html/test/naka/test.php	(revision 8)
+++ /branches/beta/html/test/naka/test.php	(revision 14676)
@@ -1,27 +1,8 @@
-<html lang="ja">
-<head>
-<meta http-equiv=Content-Type content="text/html; charset=EUC-JP">
-</head>
+<?php
 
-<body>
-
-<table>
-<form name="form1" action="test.php" method="POST">
-<tr>
-	<td>Ê¸»ú¤òÆþÎÏ¤·¤Æ¤¯¤À¤µ¤¤</td>
-	<td><input type="text" name="string"></td>
-	<td><input type="submit" value="Á÷¿®"></td>
-</tr>
-</form>
-</table>
-
-<?php
 require_once("../../require.php");
 
-    if(isset($_POST['string'])) {
-        print("string is " . $_POST['string']);
-    }
+gfDebugLog($_GET);
+
+
 ?>
-
-</body>
-</html>
Index: /branches/beta/html/test/naka/conf.php
===================================================================
--- /branches/beta/html/test/naka/conf.php	(revision 14676)
+++ /branches/beta/html/test/naka/conf.php	(revision 14676)
@@ -0,0 +1,1081 @@
+<?php
+/**
+ * 
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ * 
+ */
+
+$CONF_PHP_PATH = realpath( dirname( __FILE__) );
+require_once($CONF_PHP_PATH ."/../install.php");
+require_once($CONF_PHP_PATH ."/core.php" );
+
+//--------------------------------------------------------------------------------------------------------
+/** ¥¨¥é¡¼¥ì¥Ù¥ëÀßÄê
+/*
+ *	'E_ERROR'             => Âç¤Ê¼Â¹Ô»þ¥¨¥é¡¼¡£¤³¤ì¤Ï¡¢¥á¥â¥ê³ÎÊÝ¤Ë´Ø¤¹¤ëÌäÂê¤Î¤è¤¦¤ËÉüµ¢¤Ç ¤­¤Ê¤¤¥¨¥é¡¼¤ò¼¨¤·¤Þ¤¹¡£¥¹¥¯¥ê¥×¥È¤Î¼Â¹Ô¤ÏÃæÃÇ¤µ¤ì¤Þ¤¹¡£ 
+ *	'E_WARNING'           => ¼Â¹Ô»þ¤Î·Ù¹ð (Ã×Ì¿Åª¤Ê¥¨¥é¡¼¤Ç¤Ï¤Ê¤¤)¡£¥¹¥¯¥ê¥×¥È¤Î¼Â¹Ô¤ÏÃæÃÇ¤µ ¤ì¤Þ¤»¤ó
+ *	'E_PARSE'             => ¥³¥ó¥Ñ¥¤¥ë»þ¤Î¥Ñ¡¼¥¹¥¨¥é¡¼¡£¥Ñ¡¼¥¹¥¨¥é¡¼¤Ï¥Ñ¡¼¥µ¤Ç¤Î¤ßÀ¸À®¤µ¤ì¤Þ ¤¹¡£ 
+ *	'E_NOTICE'            => ¼Â¹Ô»þ¤Î·Ù¹ð¡£¥¨¥é¡¼¤òÈ¯¤·¤¦¤ë¾õ¶·¤ËÁø¶ø¤·¤¿¤³¤È¤ò¼¨¤¹¡£ ¤¿¤À¤·ÄÌ¾ï¤Î¥¹¥¯¥ê¥×¥È¼Â¹Ô¤Î¾ì¹ç¤Ë¤â¤³¤Î·Ù¹ð¤òÈ¯¤¹¤ë¤³¤È¤¬¤¢¤ê¤¦¤ë¡£
+ *	'E_CORE_ERROR'        => PHP¤Î½é´ü»ÏÆ°»þÅÀ¤Ç¤ÎÃ×Ì¿Åª¤Ê¥¨¥é¡¼¡£E_ERROR¤Ë »÷¤Æ¤¤¤ë¤¬PHP¤Î¥³¥¢¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ëÅÀ¤¬°ã¤¦¡£ 
+ *	'E_CORE_WARNING'      => ¡ÊÃ×Ì¿Åª¤Ç¤Ï¤Ê¤¤¡Ë·Ù¹ð¡£PHP¤Î½é´ü»ÏÆ°»þ¤ËÈ¯À¸¤¹¤ë¡£ E_WARNING¤Ë»÷¤Æ¤¤¤ë¤¬PHP¤Î¥³¥¢¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ë ÅÀ¤¬°ã¤¦¡£ 
+ *	'E_COMPILE_ERROR'     => ¥³¥ó¥Ñ¥¤¥ë»þ¤ÎÃ×Ì¿Åª¤Ê¥¨¥é¡¼¡£E_ERROR¤Ë »÷¤Æ¤¤¤ë¤¬Zend¥¹¥¯¥ê¥×¥Æ¥£¥ó¥°¥¨¥ó¥¸¥ó¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ëÅÀ¤¬°ã¤¦¡£ 
+ *	'E_COMPILE_WARNING'   => ¥³¥ó¥Ñ¥¤¥ë»þ¤Î·Ù¹ð¡ÊÃ×Ì¿Åª¤Ç¤Ï¤Ê¤¤¡Ë¡£E_WARNING¤Ë »÷¤Æ¤¤¤ë¤¬Zend¥¹¥¯¥ê¥×¥Æ¥£¥ó¥°¥¨¥ó¥¸¥ó¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ëÅÀ¤¬°ã¤¦¡£ 
+ *	'E_USER_ERROR'        => ¥æ¡¼¥¶¡¼¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ë¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¡£E_ERROR ¤Ë»÷¤Æ¤¤¤ë¤¬PHP¥³¡¼¥É¾å¤Çtrigger_error()´Ø¿ô¤ò »ÈÍÑ¤·¤¿¾ì¹ç¤ËÈ¯¹Ô¤µ¤ì¤ëÅÀ¤¬°ã¤¦¡£ 
+ *	'E_USER_WARNING'      => ¥æ¡¼¥¶¡¼¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ë·Ù¹ð¥á¥Ã¥»¡¼¥¸¡£E_WARNING ¤Ë»÷¤Æ¤¤¤ë¤¬PHP¥³¡¼¥É¾å¤Çtrigger_error()´Ø¿ô¤ò »ÈÍÑ¤·¤¿¾ì¹ç¤ËÈ¯¹Ô¤µ¤ì¤ëÅÀ¤¬°ã¤¦¡£ 
+ *	'E_USER_NOTICE'       => ¥æ¡¼¥¶¡¼¤Ë¤è¤Ã¤ÆÈ¯¹Ô¤µ¤ì¤ëÃí°Õ¥á¥Ã¥»¡¼¥¸¡£E_NOTICE¤Ë ¤Ë»÷¤Æ¤¤¤ë¤¬PHP¥³¡¼¥É¾å¤Çtrigger_error()´Ø¿ô¤ò »ÈÍÑ¤·¤¿¾ì¹ç¤ËÈ¯¹Ô¤µ¤ì¤ëÅÀ¤¬°ã¤¦¡£ 
+ *	'E_ALL'               => ¥µ¥Ý¡¼¥È¤µ¤ì¤ëÁ´¤Æ¤Î¥¨¥é¡¼¤È·Ù¹ð¡£PHP < 6 ¤Ç¤Ï E_STRICT ¥ì¥Ù¥ë¤Î¥¨¥é¡¼¤Ï½ü¤¯¡£ 
+ *	'E_STRICT'            => ¢¨PHP5¤«¤é¥µ¥Ý¡¼¥È ¼Â¹Ô»þ¤ÎÃí°Õ¡£¥³¡¼¥É¤ÎÁê¸ß±¿ÍÑÀ­¤ä¸ß´¹À­¤ò°Ý»ý¤¹¤ë¤¿¤á¤Ë PHP ¤¬¥³¡¼¥É¤ÎÊÑ¹¹¤òÄó°Æ¤¹¤ë¡£
+ *	'E_RECOVERABLE_ERROR' => ¢¨PHP5¤«¤é¥µ¥Ý¡¼¥È ¥­¥ã¥Ã¥Á¤Ç¤­¤ëÃ×Ì¿Åª¤Ê¥¨¥é¡¼¡£´í¸±¤Ê¥¨¥é¡¼¤¬È¯À¸¤·¤¿¤¬¡¢ ¥¨¥ó¥¸¥ó¤¬ÉÔ°ÂÄê¤Ê¾õÂÖ¤Ë¤Ê¤ë¤Û¤É¤Ç¤Ï¤Ê¤¤¤³¤È¤òÉ½¤¹¡£ ¥æ¡¼¥¶ÄêµÁ¤Î¥Ï¥ó¥É¥é¤Ç¥¨¥é¡¼¤¬¥­¥ã¥Ã¥Á¤µ¤ì¤Ê¤«¤Ã¤¿¾ì¹ç (set_error_handler() ¤â»²¾È¤¯¤À¤µ¤¤) ¤Ï¡¢ E_ERROR ¤È¤·¤Æ°Û¾ï½ªÎ»¤¹¤ë¡£ 
+ */
+error_reporting(E_ALL & ~E_NOTICE);
+//error_reporting(E_ALL);
+
+//--------------------------------------------------------------------------------------------------------
+
+//--------------------------------------------------------------------------------------------------------
+/** ¥Õ¥í¥ó¥ÈÉ½¼¨´ØÏ¢ **/
+define("SAMPLE_ADDRESS1", "»Ô¶èÄ®Â¼Ì¾¡ÊÎã¡§ÅìµþÅÔÀéÂåÅÄ¶è¿ÀÅÄ¿ÀÊÝÄ®¡Ë");
+define("SAMPLE_ADDRESS2", "ÈÖÃÏ¡¦¥Ó¥ëÌ¾¡ÊÎã¡§1-3-5¡Ë");
+//--------------------------------------------------------------------------------------------------------
+
+//--------------------------------------------------------------------------------------------------------
+/** ¥Ñ¥¹´ØÏ¢ **/
+// ¥æ¡¼¥¶¥Õ¥¡¥¤¥ëÊÝÂ¸Àè
+define("USER_DIR", "user_data/");
+define("USER_PATH", HTML_PATH . USER_DIR);
+
+// ¥æ¡¼¥¶¥¤¥ó¥¯¥ë¡¼¥É¥Õ¥¡¥¤¥ëÊÝÂ¸Àè
+define("USER_INC_PATH", USER_PATH . "include/");
+
+// ¥Ö¥í¥Ã¥¯¥Õ¥¡¥¤¥ëÊÝÂ¸Àè
+define("BLOC_DIR", "include/bloc/");
+define("BLOC_PATH", USER_PATH . BLOC_DIR);
+
+// ¥­¥ã¥ó¥Ú¡¼¥ó¥Õ¥¡¥¤¥ëÊÝÂ¸Àè
+define("CAMPAIGN_DIR", "cp/");
+define("CAMPAIGN_URL", URL_DIR . CAMPAIGN_DIR);
+define("CAMPAIGN_PATH", HTML_PATH . CAMPAIGN_DIR);
+define("CAMPAIGN_TEMPLATE_DIR", "include/campaign/");
+define("CAMPAIGN_TEMPLATE_PATH", USER_PATH . CAMPAIGN_TEMPLATE_DIR);
+define("CAMPAIGN_BLOC_DIR", "bloc/");
+define("CAMPAIGN_BLOC_PATH", CAMPAIGN_TEMPLATE_PATH . CAMPAIGN_BLOC_DIR);
+define("CAMPAIGN_TEMPLATE_ACTIVE", "active/");
+define("CAMPAIGN_TEMPLATE_END", "end/");
+
+// ¥Æ¥ó¥×¥ì¡¼¥È¥Õ¥¡¥¤¥ëÊÝÂ¸Àè
+define("USER_TEMPLATE_DIR", "templates/");
+define("USER_TEMPLATE_PATH", USER_PATH . USER_TEMPLATE_DIR);
+// ¥Æ¥ó¥×¥ì¡¼¥È¥Õ¥¡¥¤¥ë°ì»þÊÝÂ¸Àè
+define("TEMPLATE_TEMP_DIR", HTML_PATH . "upload/temp_template/");
+
+// ¥æ¡¼¥¶¡¼ºîÀ®²èÌÌ¤Î¥Ç¥Õ¥©¥ë¥ÈPHP¥Õ¥¡¥¤¥ë
+define("USER_DEF_PHP", HTML_PATH . "__default.php");
+
+// ¤½¤ÎÂ¾²èÌÌ¤Î¥Ç¥Õ¥©¥ë¥È¥Ú¡¼¥¸¥ì¥¤¥¢¥¦¥È
+define("DEF_LAYOUT", "products/list.php");
+
+// ¥À¥¦¥ó¥í¡¼¥É¥â¥¸¥å¡¼¥ëÊÝÂ¸¥Ç¥£¥ì¥¯¥È¥ê
+define("MODULE_DIR", "downloads/module/");
+define("MODULE_PATH", DATA_PATH . MODULE_DIR);
+
+// HotFixÊÝÂ¸¥Ç¥£¥ì¥¯¥È¥ê
+define("UPDATE_DIR", "downloads/update/");
+define("UPDATE_PATH", DATA_PATH . UPDATE_DIR);
+//--------------------------------------------------------------------------------------------------------
+
+//--------------------------------------------------------------------------------------------------------
+/** ¥¢¥Ã¥×¥Ç¡¼¥È´ÉÍýÍÑ **/
+// ¥¢¥Ã¥×¥Ç¡¼¥È´ÉÍýÍÑ¥Õ¥¡¥¤¥ë³ÊÇ¼¾ì½ê¡¡
+define("UPDATE_HTTP", "http://www.lockon.co.jp/share/");
+
+// ¥¢¥Ã¥×¥Ç¡¼¥È´ÉÍýÍÑCSV1¹ÔÊÕ¤ê¤ÎºÇÂçÊ¸»ú¿ô
+define("UPDATE_CSV_LINE_MAX", 4096);
+// ¥¢¥Ã¥×¥Ç¡¼¥È´ÉÍýÍÑCSV¥«¥é¥à¿ô
+define("UPDATE_CSV_COL_MAX", 13);
+// ¥â¥¸¥å¡¼¥ë´ÉÍýÍÑCSV¥«¥é¥à¿ô
+define("MODULE_CSV_COL_MAX", 16);
+//--------------------------------------------------------------------------------------------------------
+
+//--------------------------------------------------------------------------------------------------------
+/** ¥â¥¸¥å¡¼¥ë´ÉÍýÍÑ **/
+// ¥¨¥Ó¥¹¥¿¥°µ¡Ç½¤Î¥â¥¸¥å¡¼¥ëID
+define("EBIS_TAG_MID", 1);
+// ¥¢¥Õ¥£¥ê¥¨¥¤¥È¥¿¥°µ¡Ç½¤Î¥â¥¸¥å¡¼¥ëID
+define("AFF_TAG_MID", 3);
+// ¾¦ÉÊ¹ØÆþ´°Î»
+define("AFF_SHOPPING_COMPLETE", 1);
+// ¥æ¡¼¥¶ÅÐÏ¿´°Î»
+define("AFF_ENTRY_COMPLETE", 2);
+// ·èºÑ¼õ¿®ÍÑURL
+define("CREDIT_HTTP_DOMAIN", "http://rcv.ec-cube.net/");
+define("CREDIT_HTTP_ANALYZE_PROGRAM", "rcv_credit.php");
+define("CREDIT_HTTP_ANALYZE_URL", CREDIT_HTTP_DOMAIN . CREDIT_HTTP_ANALYZE_PROGRAM);
+//--------------------------------------------------------------------------------------------------------
+
+// Ê¸»ú¥³¡¼¥É
+define("CHAR_CODE", "EUC-JP");
+
+// EC-CUBE¥Ð¡¼¥¸¥ç¥ó¾ðÊó
+define("ECCUBE_VERSION", "1.3.0");
+
+// ·èºÑ¥â¥¸¥å¡¼¥ëÉÕÍ¿Ê¸¸À
+define("ECCUBE_PAYMENT", "EC-CUBE");
+
+// PEAR::DB¤Î¥Ç¥Ð¥Ã¥°¥â¡¼¥É
+define('PEAR_DB_DEBUG', 9);
+
+//¥Ð¥Ã¥Á¤ò¼Â¹Ô¤¹¤ëºÇÃ»¤Î´Ö³Ö(ÉÃ)
+define("LOAD_BATCH_PASS", 3600);
+
+define("CLOSE_DAY", 31);	// Äù¤áÆü¤Î»ØÄê(ËöÆü¤Î¾ì¹ç¤Ï¡¢31¤ò»ØÄê¤·¤Æ¤¯¤À¤µ¤¤¡£)
+
+//°ìÈÌ¥µ¥¤¥È¥¨¥é¡¼
+define("FAVORITE_ERROR", 13);
+
+/** ¥°¥é¥Õ´ØÏ¢ **/
+	
+define("LIB_DIR", DATA_PATH . "lib/");						// ¥é¥¤¥Ö¥é¥ê¤Î¥Ñ¥¹
+define("TTF_DIR", DATA_PATH . "fonts/");					// ¥Õ¥©¥ó¥È¤Î¥Ñ¥¹
+define("GRAPH_DIR", HTML_PATH . "upload/graph_image/");		// ¥°¥é¥Õ³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥ê
+define("GRAPH_URL", URL_DIR . "upload/graph_image/");		// ¥°¥é¥ÕURL
+define("GRAPH_PIE_MAX", 10);								// ±ß¥°¥é¥ÕºÇÂçÉ½¼¨¿ô
+define("GRAPH_LABEL_MAX", 40);								// ¥°¥é¥Õ¤Î¥é¥Ù¥ë¤ÎÊ¸»ú¿ô
+
+/** ¥Ñ¥¹´ØÏ¢ **/
+
+define("PDF_DIR", DATA_PATH . "pdf/");	// PDF³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥ê
+
+/** Çä¾å¤²½¸·× **/
+
+define("BAT_ORDER_AGE", 70);		// ²¿ºÐ¤Þ¤Ç½¸·×¤ÎÂÐ¾Ý¤È¤¹¤ë¤«
+define("PRODUCTS_TOTAL_MAX", 15);	// ¾¦ÉÊ½¸·×¤Ç²¿°Ì¤Þ¤ÇÉ½¼¨¤¹¤ë¤«
+
+/** ¥Ç¥Õ¥©¥ë¥ÈÃÍ **/
+define("DEFAULT_PRODUCT_DISP", 2);	// 1:¸ø³« 2:Èó¸ø³«
+
+/** ¥ª¥×¥·¥ç¥óÀßÄê **/
+define("DELIV_FREE_AMOUNT", 0);				// Á÷ÎÁÌµÎÁ¹ØÆþ¸Ä¿ô¡Ê0¤Î¾ì¹ç¤Ï¡¢²¿¸ÄÇã¤Ã¤Æ¤âÌµÎÁ¤Ë¤Ê¤é¤Ê¤¤)
+define("INPUT_DELIV_FEE", 1);				// ÇÛÁ÷ÎÁ¤ÎÀßÄê²èÌÌÉ½¼¨(Í­¸ú:1 Ìµ¸ú:0)
+define("OPTION_PRODUCT_DELIV_FEE", 0);		// ¾¦ÉÊ¤´¤È¤ÎÁ÷ÎÁÀßÄê(Í­¸ú:1 Ìµ¸ú:0)
+define("OPTION_DELIV_FEE", 1);				// ÇÛÁ÷¶È¼Ô¤´¤È¤ÎÇÛÁ÷ÎÁ¤ò²Ã»»¤¹¤ë(Í­¸ú:1 Ìµ¸ú:0)
+define("OPTION_RECOMMEND", 1);		// ¤ª¤¹¤¹¤á¾¦ÉÊÅÐÏ¿(Í­¸ú:1 Ìµ¸ú:0)
+define("OPTION_CLASS_REGIST", 1);	// ¾¦ÉÊµ¬³ÊÅÐÏ¿(Í­¸ú:1 Ìµ¸ú:0)
+
+define("TV_IMAGE_WIDTH",170);		//TVÏ¢Æ°¾¦ÉÊ²èÁü²£
+define("TV_IMAGE_HEIGHT",95);		//TVÏ¢Æ°¾¦ÉÊ²èÁü½Ä
+define("TV_PRODUCTS_MAX",10);		//TVÏ¢Æ°¾¦ÉÊºÇÂçÅÐÏ¿¿ô
+
+/** ¥ª¥×¥·¥ç¥óÀßÄê **/
+//²ñ°÷ÅÐÏ¿ÊÑ¹¹(¥Þ¥¤¥Ú¡¼¥¸)¥Ñ¥¹¥ï¡¼¥ÉÍÑ
+define("DEFAULT_PASSWORD", "UAhgGR3L");
+//¤ª¤¹¤¹¤á¾¦ÉÊ¿ô
+define ("RECOMMEND_PRODUCT_MAX", 5);
+
+//ÊÌ¤Î¤ªÆÏ¤±ÀèºÇÂçÅÐÏ¿¿ô
+define("DELIV_ADDR_MAX", 20);
+//±ÜÍ÷ÍúÎòÊÝÂ¸¿ô
+define("CUSTOMER_READING_MAX",30);
+//SSLURLÈ½Äê
+define("SSLURL_CHECK", 0);
+//´ÉÍý²èÌÌ¥¹¥Æ¡¼¥¿¥¹°ìÍ÷É½¼¨·ï¿ô
+define("ORDER_STATUS_MAX", 50);
+//¥Õ¥í¥ó¥È¥ì¥Ó¥å¡¼½ñ¤­¹þ¤ßºÇÂç¿ô
+define("REVIEW_REGIST_MAX", 5);
+
+/*
+ * ¥µ¥¤¥ÈÄêµÁÄê¿ô
+ */
+/* ¥·¥¹¥Æ¥à´ØÏ¢ */
+define ("ADMIN_ID", "1");								// ´ÉÍý¥æ¡¼¥¶ID(¥á¥ó¥Æ¥Ê¥ó¥¹ÍÑÉ½¼¨¤µ¤ì¤Ê¤¤¡£)
+define ("CUSTOMER_CONFIRM_MAIL", false);				// ²ñ°÷ÅÐÏ¿»þ¤Ë²¾²ñ°÷³ÎÇ§¥á¡¼¥ë¤òÁ÷¿®¤¹¤ë¤«¡Êtrue:²¾²ñ°÷¡¢false:ËÜ²ñ°÷¡Ë
+define ("MELMAGA_SEND", true);							// ¥á¥ë¥Þ¥¬ÇÛ¿®ÍÞÀ©(false:OFF¡¢true:ON)
+define ("MELMAGA_BATCH_MODE", false);					// ¥á¥¤¥ë¥Þ¥¬¥¸¥ó¥Ð¥Ã¥Á¥â¡¼¥É(true:¥Ð¥Ã¥Á¤ÇÁ÷¿®¤¹¤ë ¢¨Í×cronÀßÄê¡¢false:¥ê¥¢¥ë¥¿¥¤¥à¤ÇÁ÷¿®¤¹¤ë)
+define ("LOGIN_FRAME", "login_frame.tpl");				// ¥í¥°¥¤¥ó²èÌÌ¥Õ¥ì¡¼¥à
+define ("MAIN_FRAME", "main_frame.tpl");				// ´ÉÍý²èÌÌ¥Õ¥ì¡¼¥à
+define ("SITE_FRAME", "site_frame.tpl");				// °ìÈÌ¥µ¥¤¥È²èÌÌ¥Õ¥ì¡¼¥à
+define ("CERT_STRING", "7WDhcBTF");						// Ç§¾ÚÊ¸»úÎó
+define ("DUMMY_PASS", "########");						// ¥À¥ß¡¼¥Ñ¥¹¥ï¡¼¥É
+define ("UNLIMITED", "++");								// ºß¸Ë¿ô¡¢ÈÎÇäÀ©¸ÂÌµ¸Â¤ò¼¨¤¹¡£
+define ("BIRTH_YEAR", 1901);							// À¸Ç¯·îÆüÅÐÏ¿³«»ÏÇ¯
+define ("RELEASE_YEAR", 2005);							// ËÜ¥·¥¹¥Æ¥à¤Î²ÔÆ¯³«»ÏÇ¯
+define ("CREDIT_ADD_YEAR", 10);							// ¥¯¥ì¥¸¥Ã¥È¥«¡¼¥É¤Î´ü¸Â¡Ü²¿Ç¯
+define ("PARENT_CAT_MAX", 12);							// ¿Æ¥«¥Æ¥´¥ê¤Î¥«¥Æ¥´¥êID¤ÎºÇÂç¿ô¡Ê¤³¤ì°Ê²¼¤Ï¿Æ¥«¥Æ¥´¥ê¤È¤¹¤ë¡£)
+define ("NUMBER_MAX", 1000000000);						// GETÃÍÊÑ¹¹¤Ê¤É¤Î¤¤¤¿¤º¤é¤òËÉ¤°¤¿¤áºÇÂç¿ôÀ©¸Â¤òÀß¤±¤ë¡£
+define ("POINT_RULE", 2);								// ¥Ý¥¤¥ó¥È¤Î·×»»¥ë¡¼¥ë(1:»Í¼Î¸ÞÆþ¡¢2:ÀÚ¤ê¼Î¤Æ¡¢3:ÀÚ¤ê¾å¤²)
+define ("POINT_VALUE", 1);								// 1¥Ý¥¤¥ó¥ÈÅö¤¿¤ê¤ÎÃÍÃÊ(±ß)
+define ("ADMIN_MODE", 0);								// ´ÉÍý¥â¡¼¥É 1:Í­¸ú¡¡0:Ìµ¸ú(Ç¼ÉÊ»þ)
+define ("DAILY_BATCH_MODE", false);						// Çä¾å½¸·×¥Ð¥Ã¥Á¥â¡¼¥É(true:¥Ð¥Ã¥Á¤Ç½¸·×¤¹¤ë ¢¨Í×cronÀßÄê¡¢false:¥ê¥¢¥ë¥¿¥¤¥à¤Ç½¸·×¤¹¤ë)
+define ("MAX_LOG_QUANTITY", 5);							// ¥í¥°¥Õ¥¡¥¤¥ëºÇÂç¿ô(¥í¥°¥Æ¡¼¥·¥ç¥ó)
+define ("MAX_LOG_SIZE", "1000000");						// 1¤Ä¤Î¥í¥°¥Õ¥¡¥¤¥ë¤ËÊÝÂ¸¤¹¤ëºÇÂçÍÆÎÌ(byte)
+
+define ("FORGOT_MAIL", 0);								// ¥Ñ¥¹¥ï¡¼¥ÉËº¤ì¤Î³ÎÇ§¥á¡¼¥ë¤òÁ÷ÉÕ¤¹¤ë¤«ÈÝ¤«¡£(0:Á÷¿®¤·¤Ê¤¤¡¢1:Á÷¿®¤¹¤ë)
+define ("HTML_TEMPLATE_SUB_MAX", 12);					// ÅÐÏ¿¤Ç¤­¤ë¥µ¥Ö¾¦ÉÊ¤Î¿ô
+define ("LINE_LIMIT_SIZE", 60);							// Ê¸»ú¿ô¤¬Â¿¤¹¤®¤ë¤È¤­¤Ë¶¯À©²þ¹Ô¤¹¤ë¥µ¥¤¥º(È¾³Ñ)
+define ("BIRTH_MONTH_POINT", 0);						// ÃÂÀ¸Æü·î¥Ý¥¤¥ó¥È
+
+/* ¥¯¥ì¥¸¥Ã¥È¥í¡¼¥ó(¥»¥ó¥È¥é¥ë¥Õ¥¡¥¤¥Ê¥ó¥¹) */
+define ("CF_HOMEADDR", "https://cf.ufit.ne.jp/dotcredit");					// ¥Û¡¼¥à¥¢¥É¥ì¥¹
+define ("CF_STORECODE", "");												// ²ÃÌÁÅ¹¥³¡¼¥É(¥Ï¥¤¥Õ¥ó¤Ê¤·¤Ç¡Ë
+// define ("CF_HOMEADDR", "https://cf.ufit.ne.jp/dotcredittest");				// ¥Û¡¼¥à¥¢¥É¥ì¥¹(¥Æ¥¹¥ÈÍÑ)
+// define ("CF_STORECODE", "111111111111111");									// ²ÃÌÁÅ¹¥³¡¼¥É(¥Æ¥¹¥ÈÍÑ)
+
+define ("CF_SIMULATE", "/simulate/simulate.cgi");							// ¥·¥å¥ß¥ì¡¼¥·¥ç¥ó¸Æ¤Ó½Ð¤·
+// define ("CF_RETURNURL", SSL_URL . "shopping/loan.php");					// Ìá¤êÀè ¥·¥ç¥Ã¥Ô¥ó¥°¥í¡¼¥ó¤Ï¼¡´ü³«È¯
+// define ("CF_CANCELURL", SSL_URL . "shopping/loan_cancel.php");			// Ìá¤êÀè ¥·¥ç¥Ã¥Ô¥ó¥°¥í¡¼¥ó¤Ï¼¡´ü³«È¯
+define ("CF_CONTINUE", "1");												// ¸Æ¤Ó½Ð¤·¶èÊ¬(0:¥·¥å¥ß¥ì¡¼¥·¥ç¥ó¤Î¤ß¡¢1:¥·¥å¥ß¥ì¡¼¥·¥ç¥ó+¿½¹þ)
+define ("CF_LABOR", "0");													// ÌòÌ³Í­Ìµ¶èÊ¬(0:Ìµ¡¢1:Í­)
+define ("CF_RESULT", "1");													// ·ë²Ì±þÅú(1:·ë²Ì¤¢¤ê¡¢2:·ë²Ì¤Ê¤·)
+
+/* ¥¯¥ì¥¸¥Ã¥È¥«¡¼¥É(¥Ù¥ê¥È¥é¥ó¥¹) */
+define ("CGI_DIR", HTML_PATH . "../cgi-bin/");									// ¥â¥¸¥å¡¼¥ë³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥ê
+define ("CGI_FILE", "mauthonly.cgi");										// ¥³¥¢CGI
+
+// ¥ë¡¼¥È¥«¥Æ¥´¥êID
+define ("ROOT_CATEGORY_1", 2);
+define ("ROOT_CATEGORY_2", 3);
+define ("ROOT_CATEGORY_3", 4);
+define ("ROOT_CATEGORY_4", 5);
+define ("ROOT_CATEGORY_5", 6);
+define ("ROOT_CATEGORY_6", 7);
+define ("ROOT_CATEGORY_7", 8);
+
+// ¤ª»ÙÊ§¤¤ÊýË¡ÆÃ¼ìID
+//define ("PAYMENT_DAIBIKI_ID",1);		// Âå¶â°ú´¹
+//define ("PAYMENT_GINFURI_ID", 2);		// ¶ä¹Ô¿¶¹þ
+//define ("PAYMENT_KAKITOME_ID", 3);		// ¸½¶â½ñÎ±
+//define ("PAYMENT_LOAN_ID", 5);			// ¥·¥ç¥Ã¥Ô¥ó¥°¥í¡¼¥ó
+define ("PAYMENT_CREDIT_ID",1);			// ¥¯¥ì¥¸¥Ã¥È¥«¡¼¥É
+define ("PAYMENT_CONVENIENCE_ID", 2);	// ¥³¥ó¥Ó¥Ë·èºÑ
+
+define("LARGE_IMAGE_WIDTH",  500);						// ³ÈÂç²èÁü²£
+define("LARGE_IMAGE_HEIGHT", 500);						// ³ÈÂç²èÁü½Ä
+define("SMALL_IMAGE_WIDTH",  130);						// °ìÍ÷²èÁü²£
+define("SMALL_IMAGE_HEIGHT", 130);						// °ìÍ÷²èÁü½Ä
+define("NORMAL_IMAGE_WIDTH",  260);						// ÄÌ¾ï²èÁü²£
+define("NORMAL_IMAGE_HEIGHT", 260);						// ÄÌ¾ï²èÁü½Ä
+define("NORMAL_SUBIMAGE_WIDTH", 200);					// ÄÌ¾ï¥µ¥Ö²èÁü²£
+define("NORMAL_SUBIMAGE_HEIGHT", 200);					// ÄÌ¾ï¥µ¥Ö²èÁü½Ä
+define("LARGE_SUBIMAGE_WIDTH", 500);					// ³ÈÂç¥µ¥Ö²èÁü²£
+define("LARGE_SUBIMAGE_HEIGHT", 500);					// ³ÈÂç¥µ¥Ö²èÁü½Ä
+define("DISP_IMAGE_WIDTH",  65);						// °ìÍ÷É½¼¨²èÁü²£
+define("DISP_IMAGE_HEIGHT", 65);						// °ìÍ÷É½¼¨²èÁü½Ä
+define("OTHER_IMAGE1_WIDTH", 500);						// ¤½¤ÎÂ¾¤Î²èÁü1
+define("OTHER_IMAGE1_HEIGHT", 500);						// ¤½¤ÎÂ¾¤Î²èÁü1
+define("HTMLMAIL_IMAGE_WIDTH",  110);					// HTML¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È¥á¡¼¥ëÃ´Åö²èÁü²£
+define("HTMLMAIL_IMAGE_HEIGHT", 120);					// HTML¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È¥á¡¼¥ëÃ´Åö²èÁü½Ä
+
+define("IMAGE_SIZE", 1000);								// ²èÁü¥µ¥¤¥ºÀ©¸Â(KB)
+define("CSV_SIZE", 2000);								// CSV¥µ¥¤¥ºÀ©¸Â(KB)
+define("CSV_LINE_MAX", 10000);							// CSV¥¢¥Ã¥×¥í¡¼¥É1¹Ô¤¢¤¿¤ê¤ÎºÇÂçÊ¸»ú¿ô
+define("PDF_SIZE", 5000);								// PDF¥µ¥¤¥ºÀ©¸Â(KB):¾¦ÉÊ¾ÜºÙ¥Õ¥¡¥¤¥ëÅù
+define("FILE_SIZE", 10000);								// ¥Õ¥¡¥¤¥ë´ÉÍý²èÌÌ¥¢¥Ã¥×À©¸Â(KB)
+define("TEMPLATE_SIZE", 10000);							// ¥¢¥Ã¥×¤Ç¤­¤ë¥Æ¥ó¥×¥ì¡¼¥È¥Õ¥¡¥¤¥ëÀ©¸Â(KB)
+define("LEVEL_MAX", 5);									// ¥«¥Æ¥´¥ê¤ÎºÇÂç³¬ÁØ
+define("CATEGORY_MAX", 1000);							// ºÇÂç¥«¥Æ¥´¥êÅÐÏ¿¿ô
+
+/* É½¼¨´ØÏ¢ */
+define ("ADMIN_TITLE", "EC¥µ¥¤¥È´ÉÍý¥Ú¡¼¥¸");			// ´ÉÍý¥Ú¡¼¥¸¥¿¥¤¥È¥ë
+define ("SELECT_RGB", "#ffffdf");						// ÊÔ½¸»þ¶¯Ä´É½¼¨¿§
+define ("DISABLED_RGB", "#C9C9C9");						// ÆþÎÏ¹àÌÜÌµ¸ú»þ¤ÎÉ½¼¨¿§
+define ("ERR_COLOR", "#ffe8e8");						// ¥¨¥é¡¼»þÉ½¼¨¿§
+define ("CATEGORY_HEAD", ">");							// ¿Æ¥«¥Æ¥´¥êÉ½¼¨Ê¸»ú
+define ("START_BIRTH_YEAR", 1901);						// À¸Ç¯·îÆüÁªÂò³«»ÏÇ¯
+// ²Á³ÊÌ¾¾Î
+define("NORMAL_PRICE_TITLE","ÄÌ¾ï²Á³Ê");
+define("SALE_PRICE_TITLE","ÈÎÇä²Á³Ê");
+
+/* ¥·¥¹¥Æ¥à¥Ñ¥¹ */
+define ("LOG_PATH", DATA_PATH . "logs/site.log");							// ¥í¥°¥Õ¥¡¥¤¥ë
+define ("CUSTOMER_LOG_PATH", DATA_PATH . "logs/customer.log");				// ²ñ°÷¥í¥°¥¤¥ó ¥í¥°¥Õ¥¡¥¤¥ë
+define ("TEMPLATE_ADMIN_DIR", DATA_PATH . "Smarty/templates/admin");		// SMARTY¥Æ¥ó¥×¥ì¡¼¥È
+define ("TEMPLATE_DIR", DATA_PATH . "Smarty/templates");					// SMARTY¥Æ¥ó¥×¥ì¡¼¥È
+define ("COMPILE_ADMIN_DIR", DATA_PATH . "Smarty/templates_c/admin");		// SMARTY¥³¥ó¥Ñ¥¤¥ë
+define ("COMPILE_DIR", DATA_PATH . "Smarty/templates_c");					// SMARTY¥³¥ó¥Ñ¥¤¥ë
+
+define ("TEMPLATE_FTP_DIR", USER_PATH . "templates/");			// SMARTY¥Æ¥ó¥×¥ì¡¼¥È(FTPµö²Ä)
+define ("COMPILE_FTP_DIR", DATA_PATH . "Smarty/templates_c/user_data/");	// SMARTY¥³¥ó¥Ñ¥¤¥ë
+
+define ("IMAGE_TEMP_DIR", HTML_PATH . "upload/temp_image/");				// ²èÁü°ì»þÊÝÂ¸
+define ("IMAGE_SAVE_DIR", HTML_PATH . "upload/save_image/");				// ²èÁüÊÝÂ¸Àè
+define ("IMAGE_TEMP_URL", URL_DIR . "upload/temp_image/");					// ²èÁü°ì»þÊÝÂ¸URL
+define ("IMAGE_SAVE_URL", URL_DIR . "upload/save_image/");					// ²èÁüÊÝÂ¸ÀèURL
+define ("IMAGE_TEMP_URL_RSS", SITE_URL . "upload/temp_image/");				// RSSÍÑ²èÁü°ì»þÊÝÂ¸URL
+define ("IMAGE_SAVE_URL_RSS", SITE_URL . "upload/save_image/");				// RSSÍÑ²èÁüÊÝÂ¸ÀèURL
+define ("CSV_TEMP_DIR", HTML_PATH . "upload/csv/");							// ¥¨¥ó¥³¡¼¥ÉCSV¤Î°ì»þÊÝÂ¸Àè
+define ("NO_IMAGE_URL", URL_DIR . "misc/blank.gif");						// ²èÁü¤¬¤Ê¤¤¾ì¹ç¤ËÉ½¼¨
+define ("NO_IMAGE_DIR", HTML_PATH . "misc/blank.gif");						// ²èÁü¤¬¤Ê¤¤¾ì¹ç¤ËÉ½¼¨
+
+/* URL¥Ñ¥¹ */
+define ("URL_SYSTEM_TOP", URL_DIR . "admin/system/index.php");			// ¥·¥¹¥Æ¥à´ÉÍý¥È¥Ã¥×
+define ("URL_CLASS_REGIST", URL_DIR . "admin/products/class.php");		// µ¬³ÊÅÐÏ¿
+define ("URL_INPUT_ZIP", URL_DIR . "input_zip.php");					// Í¹ÊØÈÖ¹æÆþÎÏ
+define ("URL_DELIVERY_TOP", URL_DIR . "admin/basis/delivery.php");		// ÇÛÁ÷¶È¼ÔÅÐÏ¿
+define ("URL_PAYMENT_TOP", URL_DIR . "admin/basis/payment.php");		// »ÙÊ§¤¤ÊýË¡ÅÐÏ¿
+define ("URL_CONTROL_TOP", URL_DIR . "admin/basis/control.php");		// ¥µ¥¤¥È´ÉÍý¾ðÊóÅÐÏ¿
+define ("URL_HOME", URL_DIR . "admin/home.php");						// ¥Û¡¼¥à
+define ("URL_LOGIN", URL_DIR . "admin/index.php");						// ¥í¥°¥¤¥ó¥Ú¡¼¥¸
+define ("URL_SEARCH_TOP", URL_DIR . "admin/products/index.php");		// ¾¦ÉÊ¸¡º÷¥Ú¡¼¥¸
+define ("URL_ORDER_EDIT", URL_DIR . "admin/order/edit.php");			// ÃíÊ¸ÊÔ½¸¥Ú¡¼¥¸
+define ("URL_SEARCH_ORDER", URL_DIR . "admin/order/index.php");			// ÃíÊ¸ÊÔ½¸¥Ú¡¼¥¸
+define ("URL_ORDER_MAIL", URL_DIR . "admin/order/mail.php");			// ÃíÊ¸ÊÔ½¸¥Ú¡¼¥¸
+define ("URL_LOGOUT", URL_DIR . "admin/logout.php");					// ¥í¥°¥¢¥¦¥È¥Ú¡¼¥¸
+define ("URL_SYSTEM_CSV", URL_DIR . "admin/system/member_csv.php");		// ¥·¥¹¥Æ¥à´ÉÍýCSV½ÐÎÏ¥Ú¡¼¥¸
+define ("URL_ADMIN_CSS", URL_DIR . "admin/css/");						// ´ÉÍý¥Ú¡¼¥¸ÍÑCSSÊÝ´É¥Ç¥£¥ì¥¯¥È¥ê
+define ("URL_CAMPAIGN_TOP", URL_DIR . "admin/contents/campaign.php");	// ¥­¥ã¥ó¥Ú¡¼¥óÅÐÏ¿¥Ú¡¼¥¸
+define ("URL_CAMPAIGN_DESIGN", URL_DIR . "admin/contents/campaign_design.php");		// ¥­¥ã¥ó¥Ú¡¼¥ó¥Ç¥¶¥¤¥óÀßÄê¥Ú¡¼¥¸
+
+/* Ç§¾Ú¥¨¥é¡¼ */
+define ("SUCCESS", 0);			// ¥¢¥¯¥»¥¹À®¸ù
+define ("LOGIN_ERROR", 1);		// ¥í¥°¥¤¥ó¼ºÇÔ
+define ("ACCESS_ERROR", 2);		// ¥¢¥¯¥»¥¹¼ºÇÔ¡Ê¥¿¥¤¥à¥¢¥¦¥ÈÅù¡Ë
+define ("AUTH_ERROR", 3);		// ¥¢¥¯¥»¥¹¸¢¸Â°ãÈ¿
+
+/* É½¼¨¿ôÀ©¸Â */
+define ("PRODUCTS_LIST_MAX", 15);	// ¾¦ÉÊ°ìÍ÷É½¼¨¿ô
+define ("MEMBER_PMAX", 10);			// ¥á¥ó¥Ð¡¼´ÉÍý¥Ú¡¼¥¸É½¼¨¹Ô¿ô
+define ("SEARCH_PMAX", 10);			// ¸¡º÷¥Ú¡¼¥¸É½¼¨¹Ô¿ô
+define ("NAVI_PMAX", 5);			// ¥Ú¡¼¥¸ÈÖ¹æ¤ÎºÇÂçÉ½¼¨¸Ä¿ô
+define ("PRODUCTSUB_MAX", 5);		// ¾¦ÉÊ¥µ¥Ö¾ðÊóºÇÂç¿ô
+define ("DELIVTIME_MAX", 16);		// ÇÛÁ÷»þ´Ö¤ÎºÇÂçÉ½¼¨¿ô
+define ("DELIVFEE_MAX", 47);		// ÇÛÁ÷ÎÁ¶â¤ÎºÇÂçÉ½¼¨¿ô
+
+/* Ê¸»ú¿ôÀ©¸Â */
+define ("STEXT_LEN", 50);		// Ã»¤¤¹àÌÜ¤ÎÊ¸»ú¿ô¡ÊÌ¾Á°¤Ê¤É)
+define ("SMTEXT_LEN", 100);
+define ("MTEXT_LEN", 200);		// Ä¹¤¤¹àÌÜ¤ÎÊ¸»ú¿ô¡Ê½»½ê¤Ê¤É¡Ë
+define ("MLTEXT_LEN", 1000);	// Ä¹ÃæÊ¸¤ÎÊ¸»ú¿ô¡ÊÌä¤¤¹ç¤ï¤»¤Ê¤É¡Ë
+define ("LTEXT_LEN", 3000);		// Ä¹Ê¸¤ÎÊ¸»ú¿ô
+define ("LLTEXT_LEN", 99999);	// Ä¶Ä¹Ê¸¤ÎÊ¸»ú¿ô¡Ê¥á¥ë¥Þ¥¬¤Ê¤É¡Ë
+define ("URL_LEN", 300);		// URL¤ÎÊ¸»úÄ¹
+define ("ID_MAX_LEN", 15);		// ID¡¦¥Ñ¥¹¥ï¡¼¥É¤ÎÊ¸»ú¿ôÀ©¸Â
+define ("ID_MIN_LEN", 4);		// ID¡¦¥Ñ¥¹¥ï¡¼¥É¤ÎÊ¸»ú¿ôÀ©¸Â
+define ("PRICE_LEN", 8);		// ¶â³Û·å¿ô
+define ("PERCENTAGE_LEN", 3);	// Î¨·å¿ô
+define ("AMOUNT_LEN", 6);		// ºß¸Ë¿ô¡¢ÈÎÇäÀ©¸Â¿ô
+define ("ZIP01_LEN", 3);		// Í¹ÊØÈÖ¹æ1
+define ("ZIP02_LEN", 4);		// Í¹ÊØÈÖ¹æ2
+define ("TEL_ITEM_LEN", 6);		// ÅÅÏÃÈÖ¹æ³Æ¹àÌÜÀ©¸Â
+define ("TEL_LEN", 12);			// ÅÅÏÃÈÖ¹æÁí¿ô
+define ("PASSWORD_LEN1", 4);	// ¥Ñ¥¹¥ï¡¼¥É1
+define ("PASSWORD_LEN2", 10);	// ¥Ñ¥¹¥ï¡¼¥É2
+define ("INT_LEN", 8);			// ¸¡ºº¿ôÃÍÍÑ·å¿ô(INT)
+define ("CREDIT_NO_LEN", 4);		// ¥¯¥ì¥¸¥Ã¥È¥«¡¼¥É¤ÎÊ¸»ú¿ô
+define ("SEARCH_CATEGORY_LEN", 18);	// ¸¡º÷¥«¥Æ¥´¥êºÇÂçÉ½¼¨Ê¸»ú¿ô(byte)
+define ("FILE_NAME_LEN", 10);		// ¥Õ¥¡¥¤¥ëÌ¾É½¼¨Ê¸»ú¿ô
+
+/** ¥Õ¥í¥ó¥È¥Ú¡¼¥¸ **/
+
+/* ¥·¥¹¥Æ¥à´ØÏ¢ */
+define ("SALE_LIMIT_MAX", 10);		// ¹ØÆþÀ©¸Â¤Ê¤·¤Î¾ì¹ç¤ÎºÇÂç¹ØÆþ¸Ä¿ô
+define ("SITE_TITLE", "£Å£Ã-£Ã£Õ£Â£Å  ¥Æ¥¹¥È¥µ¥¤¥È");	// HTML¥¿¥¤¥È¥ë
+define ("COOKIE_EXPIRE", 365);		// ¥¯¥Ã¥­¡¼ÊÝ»ý´ü¸Â(Æü)
+define ("FREE_DIAL", "");
+
+/* °ìÈÌ¥µ¥¤¥È¥¨¥é¡¼ */
+define ("PRODUCT_NOT_FOUND", 1);	// »ØÄê¾¦ÉÊ¥Ú¡¼¥¸¤¬¤Ê¤¤
+define ("CART_EMPTY", 2);			// ¥«¡¼¥ÈÆâ¤¬¶õ
+define ("PAGE_ERROR", 3);			// ¥Ú¡¼¥¸¿ä°Ü¥¨¥é¡¼
+define ("CART_ADD_ERROR", 4);		// ¹ØÆþ½èÍýÃæ¤Î¥«¡¼¥È¾¦ÉÊÄÉ²Ã¥¨¥é¡¼
+define ("CANCEL_PURCHASE", 5);		// Â¾¤Ë¤â¹ØÆþ¼êÂ³¤­¤¬¹Ô¤ï¤ì¤¿¾ì¹ç
+define ("CATEGORY_NOT_FOUND", 6);	// »ØÄê¥«¥Æ¥´¥ê¥Ú¡¼¥¸¤¬¤Ê¤¤
+define ("SITE_LOGIN_ERROR", 7);		// ¥í¥°¥¤¥ó¤Ë¼ºÇÔ
+define ("CUSTOMER_ERROR", 8);		// ²ñ°÷ÀìÍÑ¥Ú¡¼¥¸¤Ø¤Î¥¢¥¯¥»¥¹¥¨¥é¡¼
+define ("SOLD_OUT", 9);				// ¹ØÆþ»þ¤ÎÇä¤êÀÚ¤ì¥¨¥é¡¼
+define ("CART_NOT_FOUND", 10);		// ¥«¡¼¥ÈÆâ¾¦ÉÊ¤ÎÆÉ¹þ¥¨¥é¡¼
+define ("LACK_POINT", 11);			// ¥Ý¥¤¥ó¥È¤ÎÉÔÂ­
+define ("TEMP_LOGIN_ERROR", 12);	// ²¾ÅÐÏ¿¼Ô¤¬¥í¥°¥¤¥ó¤Ë¼ºÇÔ
+define ("URL_ERROR", 13);			// URL¥¨¥é¡¼
+define ("EXTRACT_ERROR", 14);		// ¥Õ¥¡¥¤¥ë²òÅà¥¨¥é¡¼
+define ("FTP_DOWNLOAD_ERROR", 15);	// FTP¥À¥¦¥ó¥í¡¼¥É¥¨¥é¡¼
+define ("FTP_LOGIN_ERROR", 16);		// FTP¥í¥°¥¤¥ó¥¨¥é¡¼
+define ("FTP_CONNECT_ERROR", 17);	// FTPÀÜÂ³¥¨¥é¡¼
+define ("CREATE_DB_ERROR", 18);		// DBºîÀ®¥¨¥é¡¼
+define ("DB_IMPORT_ERROR", 19);		// DB¥¤¥ó¥Ý¡¼¥È¥¨¥é¡¼
+define ("FILE_NOT_FOUND", 20);		// ÀßÄê¥Õ¥¡¥¤¥ëÂ¸ºß¥¨¥é¡¼
+define ("WRITE_FILE_ERROR", 21);	// ½ñ¤­¹þ¤ß¥¨¥é¡¼
+define ("FREE_ERROR_MSG", 999);		// ¥Õ¥ê¡¼¥á¥Ã¥»¡¼¥¸
+
+/* É½¼¨´ØÏ¢ */
+define ("SEPA_CATNAVI", " > ");	// ¥«¥Æ¥´¥ê¶èÀÚ¤êÊ¸»ú
+define ("SEPA_CATLIST", " | ");	// ¥«¥Æ¥´¥ê¶èÀÚ¤êÊ¸»ú
+
+/* URL */
+define ("URL_SHOP_TOP", SSL_URL . "shopping/index.php");						// ²ñ°÷¾ðÊóÆþÎÏ
+define ("URL_ENTRY_TOP", SSL_URL . "entry/index.php");	 						// ²ñ°÷ÅÐÏ¿¥Ú¡¼¥¸TOP
+define ("URL_SITE_TOP", URL_DIR . "index.php");									// ¥µ¥¤¥È¥È¥Ã¥×
+define ("URL_CART_TOP", URL_DIR . "cart/index.php");							// ¥«¡¼¥È¥È¥Ã¥×
+define ("URL_DELIV_TOP", URL_DIR . "shopping/deliv.php");						// ÇÛÁ÷»þ´ÖÀßÄê 
+define ("URL_MYPAGE_TOP", SSL_URL . "mypage/login.php");						// My¥Ú¡¼¥¸¥È¥Ã¥×
+define ("URL_SHOP_CONFIRM", URL_DIR . "shopping/confirm.php");					// ¹ØÆþ³ÎÇ§¥Ú¡¼¥¸
+define ("URL_SHOP_PAYMENT", URL_DIR . "shopping/payment.php");					// ¤ª»ÙÊ§¤¤ÊýË¡ÁªÂò¥Ú¡¼¥¸
+define ("URL_SHOP_COMPLETE", URL_DIR . "shopping/complete.php");				// ¹ØÆþ´°Î»²èÌÌ
+define ("URL_SHOP_CREDIT", URL_DIR . "shopping/card.php");						// ¥«¡¼¥É·èºÑ²èÌÌ
+define ("URL_SHOP_LOAN", URL_DIR . "shopping/loan.php");						// ¥í¡¼¥ó·èºÑ²èÌÌ
+define ("URL_SHOP_CONVENIENCE", URL_DIR . "shopping/convenience.php");			// ¥³¥ó¥Ó¥Ë·èºÑ²èÌÌ
+define ("URL_SHOP_MODULE", URL_DIR . "shopping/load_payment_module.php");		// ¥â¥¸¥å¡¼¥ëÄÉ²ÃÍÑ²èÌÌ
+define ("URL_PRODUCTS_TOP", URL_DIR . "products/top.php");						// ¾¦ÉÊ¥È¥Ã¥×
+define ("LIST_P_HTML", URL_DIR . "products/list-p");							// ¾¦ÉÊ°ìÍ÷(HTML½ÐÎÏ)
+define ("LIST_C_HTML", URL_DIR . "products/list.php?mode=search&category_id=");	// ¾¦ÉÊ°ìÍ÷(HTML½ÐÎÏ)
+define ("DETAIL_P_HTML", URL_DIR . "products/detail.php?product_id=");			// ¾¦ÉÊ¾ÜºÙ(HTML½ÐÎÏ)
+define ("MYPAGE_DELIVADDR_URL", URL_DIR . "mypage/delivery.php");				// ¥Þ¥¤¥Ú¡¼¥¸¤ªÆÏ¤±ÀèURL
+
+/*
+ * ¥µ¥¤¥ÈÄêµÁÊÑ¿ô
+ */
+ 
+// ¥¢¥¯¥»¥¹¸¢¸Â
+// 0:´ÉÍý¼Ô¤Î¤ß¥¢¥¯¥»¥¹²ÄÇ½
+// 1:°ìÈÌ°Ê¾å¤¬¥¢¥¯¥»¥¹²ÄÇ½
+$arrPERMISSION[URL_SYSTEM_TOP] = 0;
+$arrPERMISSION["/admin/system/delete.php"] = 0;
+$arrPERMISSION["/admin/system/index.php"] = 0;
+$arrPERMISSION["/admin/system/input.php"] = 0;
+$arrPERMISSION["/admin/system/master.php"] = 0;
+$arrPERMISSION["/admin/system/master_delete.php"] = 0;
+$arrPERMISSION["/admin/system/master_rank.php"] = 0;
+$arrPERMISSION["/admin/system/mastercsv.php"] = 0;
+$arrPERMISSION["/admin/system/rank.php"] = 0;
+$arrPERMISSION["/admin/entry/index.php"] = 1;
+$arrPERMISSION["/admin/entry/delete.php"] = 1;
+$arrPERMISSION["/admin/entry/inputzip.php"] = 1;
+$arrPERMISSION["/admin/search/delete_note.php"] = 1;
+
+// ¥í¥°¥¢¥¦¥ÈÉÔ²Ä¥Ú¡¼¥¸
+$arrDISABLE_LOGOUT = array(
+	1 => "/shopping/deliv.php",
+	2 => "/shopping/payment.php",
+	3 => "/shopping/confirm.php",
+	4 => "/shopping/card.php",
+	5 => "/shopping/loan.php",
+);
+
+// ¥á¥ó¥Ð¡¼´ÉÍý-¸¢¸Â
+$arrAUTHORITY[0] = "´ÉÍý¼Ô";
+//$arrAUTHORITY[1] = "°ìÈÌ";
+// $arrAUTHORITY[2] = "±ÜÍ÷";
+
+// ¥á¥ó¥Ð¡¼´ÉÍý-²ÔÆ¯¾õ¶·
+$arrWORK[0] = "Èó²ÔÆ¯";
+$arrWORK[1] = "²ÔÆ¯";
+
+// ¾¦ÉÊÅÐÏ¿-É½¼¨
+$arrDISP[1] = "¸ø³«";
+$arrDISP[2] = "Èó¸ø³«";
+
+// ¾¦ÉÊÅÐÏ¿-µ¬³Ê
+$arrCLASS[1] = "µ¬³ÊÌµ¤·";
+$arrCLASS[2] = "µ¬³ÊÍ­¤ê";
+
+// ¸¡º÷¥é¥ó¥¯
+$arrSRANK[1] = 1;
+$arrSRANK[2] = 2;
+$arrSRANK[3] = 3;
+$arrSRANK[4] = 4;
+$arrSRANK[5] = 5;
+
+// ¾¦ÉÊÅÐÏ¿-¥¹¥Æ¡¼¥¿¥¹
+$arrSTATUS[1] = "NEW";
+$arrSTATUS[2] = "»Ä¤ê¤ï¤º¤«";
+$arrSTATUS[3] = "¥Ý¥¤¥ó¥È£²ÇÜ";
+$arrSTATUS[4] = "¥ª¥¹¥¹¥á";
+$arrSTATUS[5] = "¸ÂÄêÉÊ";
+
+// ¾¦ÉÊÅÐÏ¿-¥¹¥Æ¡¼¥¿¥¹²èÁü
+$arrSTATUS_IMAGE[1] = URL_DIR . "img/right_product/icon01.gif";
+$arrSTATUS_IMAGE[2] = URL_DIR . "img/right_product/icon02.gif";
+$arrSTATUS_IMAGE[3] = URL_DIR . "img/right_product/icon03.gif";
+$arrSTATUS_IMAGE[4] = URL_DIR . "img/right_product/icon04.gif";
+$arrSTATUS_IMAGE[5] = URL_DIR . "img/right_product/icon05.gif";
+
+// ÆþÎÏµö²Ä¤¹¤ë¥¿¥°
+$arrAllowedTag = array(
+	"table",
+	"tr",
+	"td",
+	"a",
+	"b",
+	"blink",
+	"br",
+	"center",
+	"font",
+	"h",
+	"hr",
+	"img",
+	"li",
+	"strong",
+	"p",
+	"div",
+	"i",
+	"u",
+	"s",
+	"/table",
+	"/tr",
+	"/td",
+	"/a",
+	"/b",
+	"/blink",
+	"/br",
+	"/center",
+	"/font",
+	"/h",
+	"/hr",
+	"/img",
+	"/li",
+	"/strong",
+	"/p",
+	"/div",
+	"/i",
+	"/u",
+	"/s"
+);
+
+// £±¥Ú¡¼¥¸É½¼¨¹Ô¿ô
+$arrPageMax = array(
+	10 => "10",
+	20 => "20",
+	30 => "30",
+	40 => "40",
+	50 => "50",
+	60 => "60",
+	70 => "70",
+	80 => "80",
+	90 => "90",
+	100 => "100",
+);	
+	
+// ¥á¥ë¥Þ¥¬¼ïÊÌ
+$arrMagazineType["1"] = "HTML";
+$arrMagazineType["2"] = "¥Æ¥­¥¹¥È";
+
+$arrMagazineTypeAll = $arrMagazineType;
+$arrMagazineTypeAll["3"] = "HTML¥Æ¥ó¥×¥ì¡¼¥È";
+
+
+/* ¥á¥ë¥Þ¥¬¼ïÊÌ */
+$arrMAILMAGATYPE = array(
+	1 => "HTML¥á¡¼¥ë",
+	2 => "¥Æ¥­¥¹¥È¥á¡¼¥ë",
+	3 => "´õË¾¤·¤Ê¤¤"
+);
+
+/* ¤ª¤¹¤¹¤á¥ì¥Ù¥ë */
+$arrRECOMMEND = array(
+	5 => "¡ú¡ú¡ú¡ú¡ú",
+	4 => "¡ú¡ú¡ú¡ú",
+	3 => "¡ú¡ú¡ú",
+	2 => "¡ú¡ú",
+	1 => "¡ú"
+);
+
+$arrTAXRULE = array(
+	1 => "»Í¼Î¸ÞÆþ",
+	2 => "ÀÚ¤ê¼Î¤Æ",
+	3 => "ÀÚ¤ê¾å¤²"
+);
+
+
+// ¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È¤Î¼ïÎà
+$arrMAILTEMPLATE = array(
+	 1 => "ÃíÊ¸¼õÉÕ¥á¡¼¥ë"
+	,2 => "ÃíÊ¸¥­¥ã¥ó¥»¥ë¼õÉÕ¥á¡¼¥ë"
+	,3 => "¼è¤ê´ó¤»³ÎÇ§¥á¡¼¥ë"
+);
+
+// ³Æ¥Æ¥ó¥×¥ì¡¼¥È¤Î¥Ñ¥¹
+$arrMAILTPLPATH = array(
+	1 => "mail_templates/order_mail.tpl",
+	2 => "mail_templates/order_mail.tpl",
+	3 => "mail_templates/order_mail.tpl",
+	4 => "mail_templates/contact_mail.tpl",
+);
+
+/* ÅÔÆ»ÉÜ¸©ÇÛÎó */
+$arrPref = array(
+					1 => "ËÌ³¤Æ»",
+					2 => "ÀÄ¿¹¸©",
+					3 => "´ä¼ê¸©",
+					4 => "µÜ¾ë¸©",
+					5 => "½©ÅÄ¸©",
+					6 => "»³·Á¸©",
+					7 => "Ê¡Åç¸©",
+					8 => "°ñ¾ë¸©",
+					9 => "ÆÊÌÚ¸©",
+					10 => "·²ÇÏ¸©",
+					11 => "ºë¶Ì¸©",
+					12 => "ÀéÍÕ¸©",
+					13 => "ÅìµþÅÔ",
+					14 => "¿ÀÆàÀî¸©",
+					15 => "¿·³ã¸©",
+					16 => "ÉÙ»³¸©",
+					17 => "ÀÐÀî¸©",
+					18 => "Ê¡°æ¸©",
+					19 => "»³Íü¸©",
+					20 => "Ä¹Ìî¸©",
+					21 => "´ôÉì¸©",
+					22 => "ÀÅ²¬¸©",
+					23 => "°¦ÃÎ¸©",
+					24 => "»°½Å¸©",
+					25 => "¼¢²ì¸©",
+					26 => "µþÅÔÉÜ",
+					27 => "ÂçºåÉÜ",
+					28 => "Ê¼¸Ë¸©",
+					29 => "ÆàÎÉ¸©",
+					30 => "ÏÂ²Î»³¸©",
+					31 => "Ä»¼è¸©",
+					32 => "Åçº¬¸©",
+					33 => "²¬»³¸©",
+					34 => "¹­Åç¸©",
+					35 => "»³¸ý¸©",
+					36 => "ÆÁÅç¸©",
+					37 => "¹áÀî¸©",
+					38 => "°¦É²¸©",
+					39 => "¹âÃÎ¸©",
+					40 => "Ê¡²¬¸©",
+					41 => "º´²ì¸©",
+					42 => "Ä¹ºê¸©",
+					43 => "·§ËÜ¸©",
+					44 => "ÂçÊ¬¸©",
+					45 => "µÜºê¸©",
+					46 => "¼¯»ùÅç¸©",
+					47 => "²­Æì¸©"
+				);
+				
+/* ¿¦¶ÈÇÛÎó */
+$arrJob = array(
+					1 => "¸øÌ³°÷",
+					2 => "¥³¥ó¥µ¥ë¥¿¥ó¥È",
+					3 => "¥³¥ó¥Ô¥å¡¼¥¿´ØÏ¢µ»½Ñ¿¦",
+					4 => "¥³¥ó¥Ô¥å¡¼¥¿´ØÏ¢°Ê³°¤Îµ»½Ñ¿¦",
+					5 => "¶âÍ»´Ø·¸",
+					6 => "°å»Õ",
+					7 => "ÊÛ¸î»Î",
+					8 => "ÁíÌ³¡¦¿Í»ö¡¦»öÌ³",
+					9 => "±Ä¶È¡¦ÈÎÇä",
+					10 => "¸¦µæ¡¦³«È¯",
+					11 => "¹­Êó¡¦ÀëÅÁ",
+					12 => "´ë²è¡¦¥Þ¡¼¥±¥Æ¥£¥ó¥°",
+					13 => "¥Ç¥¶¥¤¥ó´Ø·¸",
+					14 => "²ñ¼Ò·Ð±Ä¡¦Ìò°÷",
+					15 => "½ÐÈÇ¡¦¥Þ¥¹¥³¥ß´Ø·¸",
+					16 => "³ØÀ¸¡¦¥Õ¥ê¡¼¥¿¡¼",
+					17 => "¼çÉØ",
+					18 => "¤½¤ÎÂ¾"
+				);
+
+/* ¥Ñ¥¹¥ï¡¼¥É¤ÎÅú¤¨ÇÛÎó */
+$arrReminder = array(
+						1 => "¿Æ¤ÎµìÀ«¤Ï¡©",
+						2 => "¤ªµ¤¤ËÆþ¤ê¤Î¥Þ¥ó¥¬¤Ï¡©",
+						3 => "Âç¹¥¤­¤Ê¥Ú¥Ã¥È¤ÎÌ¾Á°¤Ï¡©",
+						4 => "½éÎø¤Î¿Í¤ÎÌ¾Á°¤Ï¡©",
+						5 => "ÌÌÇò¤«¤Ã¤¿±Ç²è¤Ï¡©",
+						6 => "Âº·É¤·¤Æ¤¤¤¿ÀèÀ¸¤ÎÌ¾Á°¤Ï¡©",
+						7 => "¹¥¤­¤Ê¿©¤ÙÊª¤Ï¡©"
+					);
+/*¡¡À­ÊÌÇÛÎó¡¡*/
+$arrSex = array(
+					1 => "ÃËÀ­",
+					2 => "½÷À­"
+				);
+
+/*¡¡¥á¡¼¥ë¥¢¥É¥ì¥¹¼ïÊÌ¡¡*/
+define ("MAIL_TYPE_PC",1);
+define ("MAIL_TYPE_MOBILE",2);
+$arrMailType = array(
+					MAIL_TYPE_PC => "¥Ñ¥½¥³¥óÍÑ¥¢¥É¥ì¥¹",
+					MAIL_TYPE_MOBILE => "·ÈÂÓÍÑ¥¢¥É¥ì¥¹"
+				);	
+
+/*  ·ÈÂÓ¥É¥á¥¤¥ó»ØÄê¡¡*/
+$arrDomain = array(
+                        1 => "»ØÄê¤·¤Ê¤¤",
+                        2 => "£Ð£Ã¥É¥á¥¤¥ó",
+                        3 => "¥â¥Ð¥¤¥ë¥É¥á¥¤¥ó"
+                    );
+				
+
+$arrDomainType = array(
+                      1 => "docomo.ne.jp",
+                      2 => "ezweb.ne.jp",
+                      3 => "softbank.ne.jp",
+                      4 => "vodafone.ne.jp"
+                  );				
+				
+/*¡¡1¹Ô¿ô¡¡*/		
+$arrPageRows = array(
+						10 => 10,
+						20 => 20,
+						30 => 30,
+						40 => 40,
+						50 => 50,
+						60 => 60,
+						70 => 70,
+						80 => 80,
+						90 => 90,
+						100 => 100,
+					);
+
+/* ¼õÃí¥¹¥Æ¡¼¥¿¥¹ */
+define ("ORDER_NEW",1);	 		// ¿·µ¬ÃíÊ¸
+define ("ORDER_PAY_WAIT",2);	// Æþ¶âÂÔ¤Á
+define ("ORDER_PRE_END",6);		// Æþ¶âºÑ¤ß
+define ("ORDER_CANCEL",3);		// ¥­¥ã¥ó¥»¥ë
+define ("ORDER_BACK_ORDER",4);	// ¼è¤ê´ó¤»Ãæ
+define ("ORDER_DELIV",5);		// È¯Á÷ºÑ¤ß
+
+/* ¼õÃí¥¹¥Æ¡¼¥¿¥¹ */
+$arrORDERSTATUS = array(
+	ORDER_NEW        => "¿·µ¬¼õÉÕ",
+	ORDER_PAY_WAIT   => "Æþ¶âÂÔ¤Á",
+	ORDER_PRE_END    => "Æþ¶âºÑ¤ß",
+	ORDER_CANCEL     => "¥­¥ã¥ó¥»¥ë",
+	ORDER_BACK_ORDER => "¼è¤ê´ó¤»Ãæ",
+	ORDER_DELIV      => "È¯Á÷ºÑ¤ß"
+);
+
+// ¼õÃí¥¹¥Æ¡¼¥¿¥¹ÊÑ¹¹¤ÎºÝ¤Ë¥Ý¥¤¥ó¥ÈÅù¤ò²Ã»»¤¹¤ë¥¹¥Æ¡¼¥¿¥¹ÈÖ¹æ¡ÊÈ¯Á÷ºÑ¤ß¡Ë
+define("ODERSTATUS_COMMIT", ORDER_DELIV);
+
+/* ¾¦ÉÊ¼ïÊÌ¤ÎÉ½¼¨¿§ */
+$arrPRODUCTSTATUS_COLOR = array(
+	1 => "#FFFFFF",
+	2 => "#C9C9C9",
+	3 => "#DDE6F2"
+);
+
+$arrORDERSTATUS_COLOR = array(
+	1 => "#FFFFFF",
+	2 => "#FFDE9B",
+	3 => "#C9C9C9",
+	4 => "#FFD9D9",
+	5 => "#BFDFFF",
+	6 => "#FFFFAB"
+);
+
+// ÍËÆü
+$arrWDAY = array(
+	0 => "Æü",
+	1 => "·î",
+	2 => "²Ð",
+	3 => "¿å",
+	4 => "ÌÚ",
+	5 => "¶â",
+	6 => "ÅÚ"
+);			
+		
+/* ¿·Ãå¾ðÊó´ÉÍý²èÌÌ */
+define ("ADMIN_NEWS_STARTYEAR", 2005);	// ³«»ÏÇ¯(À¾Îñ)
+
+/* ²ñ°÷ÅÐÏ¿ */
+define("ENTRY_CUSTOMER_TEMP_SUBJECT", "²ñ°÷²¾ÅÐÏ¿¤¬´°Î»¤¤¤¿¤·¤Þ¤·¤¿¡£");
+define("ENTRY_CUSTOMER_REGIST_SUBJECT", "ËÜ²ñ°÷ÅÐÏ¿¤¬´°Î»¤¤¤¿¤·¤Þ¤·¤¿¡£");
+define("ENTRY_LIMIT_HOUR", 1);		//ºÆÆþ²ñÀ©¸Â»þ´Ö¡ÊÃ±°Ì: »þ´Ö)
+
+// ¥ª¥¹¥¹¥á¾¦ÉÊÉ½¼¨¿ô
+define("RECOMMEND_NUM", 8);			// ¥ª¥¹¥¹¥á¾¦ÉÊ
+define ("BEST_MAX", 5);				// ¥Ù¥¹¥È¾¦ÉÊ¤ÎºÇÂçÅÐÏ¿¿ô
+define ("BEST_MIN", 3);				// ¥Ù¥¹¥È¾¦ÉÊ¤ÎºÇ¾®ÅÐÏ¿¿ô¡ÊÅÐÏ¿¿ô¤¬Ëþ¤¿¤Ê¤¤¾ì¹ç¤ÏÉ½¼¨¤·¤Ê¤¤¡£)
+
+//È¯Á÷ÆüÌÜ°Â
+$arrDELIVERYDATE = array(
+	1 => "Â¨Æü",
+	2 => "1¡Á2Æü¸å",
+	3 => "3¡Á4Æü¸å",
+	4 => "1½µ´Ö°Ê¹ß",
+	5 => "2½µ´Ö°Ê¹ß",
+	6 => "3½µ´Ö°Ê¹ß",
+	7 => "1¥ö·î°Ê¹ß",
+	8 => "2¥ö·î°Ê¹ß",
+	9 => "¤ª¼è¤ê´ó¤»(¾¦ÉÊÆþ²Ù¸å)"
+);
+
+/* ÇÛÃ£²ÄÇ½¤ÊÆüÉÕ°Ê¹ß¤Î¥×¥ë¥À¥¦¥óÉ½¼¨ºÇÂçÆü¿ô */
+define("DELIV_DATE_END_MAX", 21);
+
+/* ¹ØÆþ»þ¶¯À©²ñ°÷ÅÐÏ¿ */
+define("PURCHASE_CUSTOMER_REGIST", 0);	//1:Í­¸ú¡¡0:Ìµ¸ú
+
+/* ¾¦ÉÊ¥ê¥¹¥ÈÉ½¼¨·ï¿ô */
+$arrPRODUCTLISTMAX = array(
+	15 => '15·ï',
+	30 => '30·ï',
+	50 => '50·ï'
+);
+
+/* ¤³¤Î¾¦ÉÊ¤òÇã¤Ã¤¿¿Í¤Ï¤³¤ó¤Ê¾¦ÉÊ¤âÇã¤Ã¤Æ¤¤¤Þ¤¹¡¡É½¼¨·ï¿ô */
+define("RELATED_PRODUCTS_MAX", 3);
+
+/*--------- ¢§¥³¥ó¥Ó¥Ë·èºÑÍÑ ---------*/
+
+//¥³¥ó¥Ó¥Ë¤Î¼ïÎà
+$arrCONVENIENCE = array(
+	1 => '¥»¥Ö¥ó¥¤¥ì¥Ö¥ó',
+	2 => '¥Õ¥¡¥ß¥ê¡¼¥Þ¡¼¥È',
+	3 => '¥µ¡¼¥¯¥ëK¥µ¥ó¥¯¥¹',
+	4 => '¥í¡¼¥½¥ó¡¦¥»¥¤¥³¡¼¥Þ¡¼¥È',
+	5 => '¥ß¥Ë¥¹¥È¥Ã¥×¡¦¥Ç¥¤¥ê¡¼¥ä¥Þ¥¶¥­¡¦¥ä¥Þ¥¶¥­¥Ç¥¤¥ê¡¼¥¹¥È¥¢',
+);
+
+//³Æ¼ï¥³¥ó¥Ó¥ËÍÑ¥á¥Ã¥»¡¼¥¸
+$arrCONVENIMESSAGE = array(
+	1 => "¾åµ­URL¤«¤é¿¶¹þÉ¼¤ò°õºþ¡¢¤â¤·¤¯¤Ï¿¶¹þÉ¼ÈÖ¹æ¤ò»æ¤Ë¹µ¤¨¤Æ¡¢Á´¹ñ¤Î¥»¥Ö¥ó¥¤¥ì¥Ö¥ó¤Ë¤Æ¤ª»ÙÊ§¤¤¤¯¤À¤µ¤¤¡£",
+	2 => "´ë¶È¥³¡¼¥É¡¢¼õÉÕÈÖ¹æ¤ò»æ¤Ê¤É¤Ë¹µ¤¨¤Æ¡¢Á´¹ñ¤Î¥Õ¥¡¥ß¥ê¡¼¥Þ¡¼¥È¤Ë¤ª»ÙÊ§¤¤¤¯¤À¤µ¤¤¡£",
+	3 => "¾åµ­URL¤«¤é¿¶¹þÉ¼¤ò°õºþ¡¢¤â¤·¤¯¤Ï¥±¡¼¥¿¥¤·èºÑÈÖ¹æ¤ò»æ¤Ê¤É¤Ë¹µ¤¨¤Æ¡¢Á´¹ñ¤Î¥µ¡¼¥¯¥ëK¥µ¥ó¥¯¥¹¤Ë¤Æ¤ª»ÙÊ§¤¯¤À¤µ¤¤¡£",
+	4 => "¿¶¹þÉ¼ÈÖ¹æ¤ò»æ¤Ë¹µ¤¨¤Æ¡¢Á´¹ñ¤Î¥í¡¼¥½¥ó¤Þ¤¿¤Ï¥»¥¤¥³¡¼¥Þ¡¼¥È¤Ë¤Æ¤ª»ÙÊ§¤¤¤¯¤À¤µ¤¤¡£",
+	5 => "¾åµ­URL¤«¤é¿¶¹þÉ¼¤ò°õºþ¤·¡¢Á´¹ñ¤Î¥ß¥Ë¥¹¥È¥Ã¥×¡¦¥Ç¥¤¥ê¡¼¥ä¥Þ¥¶¥­¡¦¥ä¥Þ¥¶¥­¥Ç¥¤¥ê¡¼¥¹¥È¥¢¤Ë¤Æ¤ª»ÙÊ§¤¤¤¯¤À¤µ¤¤¡£"
+);
+
+//»ÙÊ§´ü¸Â
+define("CV_PAYMENT_LIMIT", 14);
+
+/*--------- ¢¥¥³¥ó¥Ó¥Ë·èºÑÍÑ ---------*/
+
+//¥­¥ã¥ó¥Ú¡¼¥óÅÐÏ¿ºÇÂç¿ô
+define("CAMPAIGN_REGIST_MAX", 20);
+
+//DB¤Î¼ïÎà
+$arrDB = array(
+	1 => 'PostgreSQL',
+	2 => 'MySQL'
+);
+
+// ¥Ö¥í¥Ã¥¯ÇÛÃÖ
+$arrTarget = array(
+	1 => "LeftNavi",
+	2 => "MainHead",
+	3 => "RightNavi",
+	4 => "MainFoot",
+	5 => "Unused"
+);
+
+/*--------- ¢¥¥È¥é¥Ã¥¯¥Ð¥Ã¥¯ÍÑ ---------*/
+
+define ("TRACKBACK_STATUS_VIEW", 1);		// É½¼¨
+define ("TRACKBACK_STATUS_NOT_VIEW", 2);	// ÈóÉ½¼¨
+define ("TRACKBACK_STATUS_SPAM", 3);		// ¥¹¥Ñ¥à
+
+define ("TRACKBACK_VIEW_MAX", 10);			// ¥Õ¥í¥ó¥ÈºÇÂçÉ½¼¨¿ô
+define ("TRACKBACK_TO_URL", SITE_URL . "tb/index.php?pid=");	// ¥È¥é¥Ã¥¯¥Ð¥Ã¥¯ÀèURL
+
+// ¾õÂÖ
+$arrTrackBackStatus = array(
+	1 => "É½¼¨",
+	2 => "ÈóÉ½¼¨",
+	3 => "¥¹¥Ñ¥à"
+);
+
+/*--------- ¢¥¥µ¥¤¥È´ÉÍýÍÑ ---------*/
+
+define ("SITE_CONTROL_TRACKBACK", 1);		// ¥È¥é¥Ã¥¯¥Ð¥Ã¥¯
+define ("SITE_CONTROL_AFFILIATE", 2);		// ¥¢¥Õ¥£¥ê¥¨¥¤¥È
+
+// ¥È¥é¥Ã¥¯¥Ð¥Ã¥¯
+$arrSiteControlTrackBack = array(
+	1 => "Í­¸ú",
+	2 => "Ìµ¸ú"
+);
+
+// ¥¢¥Õ¥£¥ê¥¨¥¤¥È
+$arrSiteControlAffiliate = array(
+	1 => "Í­¸ú",
+	2 => "Ìµ¸ú"
+);
+
+/*--------- ¢¥View´ÉÍýÍÑ ---------*/
+
+// View¤ÎWhere¶çÃÖ´¹ÍÑ
+$arrViewWhere = array(
+	"&&crscls_where&&" => "",
+	"&&crsprdcls_where&&" =>"",
+	"&&noncls_where&&" => "",
+	"&&allcls_where&&" => "",
+	"&&allclsdtl_where&&" => "",
+	"&&prdcls_where&&" => "",
+	"&&catcnt_where&&" => ""
+);
+
+// ViewÊÑ´¹ÍÑ(MySQLÂÐ±þ)
+$arrView = array(
+	"vw_cross_class" => '
+		(SELECT T1.class_id AS class_id1, T2.class_id AS class_id2, T1.classcategory_id AS classcategory_id1, T2.classcategory_id AS classcategory_id2, T1.name AS name1, T2.name AS name2, T1.rank AS rank1, T2.rank AS rank2
+		FROM dtb_classcategory AS T1, dtb_classcategory AS T2 ) ',
+
+	"vw_cross_products_class" =>'
+		(SELECT T1.class_id1, T1.class_id2, T1.classcategory_id1, T1.classcategory_id2, T2.product_id,
+		T1.name1, T1.name2, T2.product_code, T2.stock, T2.price01, T2.price02, T1.rank1, T1.rank2
+		FROM (SELECT T1.class_id AS class_id1, T2.class_id AS class_id2, T1.classcategory_id AS classcategory_id1, T2.classcategory_id AS classcategory_id2, T1.name AS name1, T2.name AS name2, T1.rank AS rank1, T2.rank AS rank2
+		FROM dtb_classcategory AS T1, dtb_classcategory AS T2 ) AS T1 LEFT JOIN dtb_products_class AS T2 
+		ON T1.classcategory_id1 = T2.classcategory_id1 AND T1.classcategory_id2 = T2.classcategory_id2) ',
+
+	"vw_products_nonclass" => '
+		(SELECT 
+		    T1.product_id,
+		    T1.name,
+		    T1.deliv_fee,
+		    T1.sale_limit,
+		    T1.sale_unlimited,
+		    T1.category_id,
+		    T1.rank,
+		    T1.status,
+		    T1.product_flag,
+		    T1.point_rate,
+		    T1.comment1,
+		    T1.comment2,
+		    T1.comment3,
+		    T1.comment4,
+		    T1.comment5,
+		    T1.comment6,
+		    T1.file1,
+		    T1.file2,
+		    T1.file3,
+		    T1.file4,
+		    T1.file5,
+		    T1.file6,
+		    T1.main_list_comment,
+		    T1.main_list_image,
+		    T1.main_comment,
+		    T1.main_image,
+		    T1.main_large_image,
+		    T1.sub_title1,
+		    T1.sub_comment1,
+		    T1.sub_image1,
+		    T1.sub_large_image1,
+		    T1.sub_title2,
+		    T1.sub_comment2,
+		    T1.sub_image2,
+		    T1.sub_large_image2,
+		    T1.sub_title3,
+		    T1.sub_comment3,
+		    T1.sub_image3,
+		    T1.sub_large_image3,
+		    T1.sub_title4,
+		    T1.sub_comment4,
+		    T1.sub_image4,
+		    T1.sub_large_image4,
+		    T1.sub_title5,
+		    T1.sub_comment5,
+		    T1.sub_image5,
+		    T1.sub_large_image5,
+		    T1.sub_title6,
+		    T1.sub_comment6,
+		    T1.sub_image6,
+		    T1.sub_large_image6,
+		    T1.del_flg,
+		    T1.creator_id,
+		    T1.create_date,
+		    T1.update_date,
+		    T1.deliv_date_id,
+		    T2.product_id_sub,
+		    T2.product_code,
+		    T2.price01,
+		    T2.price02,
+		    T2.stock,
+		    T2.stock_unlimited,
+		    T2.classcategory_id1,
+		    T2.classcategory_id2
+		FROM (SELECT * FROM dtb_products &&noncls_where&&) AS T1 LEFT JOIN 
+		(SELECT
+		product_id AS product_id_sub,
+		product_code,
+		price01,
+		price02,
+		stock,
+		stock_unlimited,
+		classcategory_id1,
+		classcategory_id2
+		FROM dtb_products_class WHERE classcategory_id1 = 0 AND classcategory_id2 = 0) 
+		AS T2
+		ON T1.product_id = T2.product_id_sub) ',
+
+	"vw_products_allclass" => '
+		(SELECT
+        product_id,
+        product_code_min,
+        product_code_max,
+        price01_min,
+        price01_max,
+        price02_min,
+        price02_max,
+        stock_min,
+        stock_max,
+        stock_unlimited_min,
+        stock_unlimited_max,
+        del_flg,
+        status,
+        name,
+        comment1,
+        comment2,
+        comment3,
+        rank,
+        main_list_comment,
+        main_image,
+        main_list_image,
+        product_flag,
+        deliv_date_id,
+        sale_limit,
+        point_rate,
+        sale_unlimited,
+        create_date,
+        deliv_fee
+        ,(SELECT rank AS category_rank FROM dtb_category AS T4 WHERE T1.category_id = T4.category_id) as category_rank
+        ,(SELECT category_id AS sub_category_id FROM dtb_category T4 WHERE T1.category_id = T4.category_id) as category_id
+    FROM
+        dtb_products AS T1 RIGHT JOIN (SELECT product_id AS product_id_sub, MIN(product_code) AS product_code_min, MAX(product_code) AS product_code_max, MIN(price01) AS price01_min, MAX(price01) AS price01_max, MIN(price02) AS price02_min, MAX(price02) AS price02_max, MIN(stock) AS stock_min, MAX(stock) AS stock_max, MIN(stock_unlimited) AS stock_unlimited_min, MAX(stock_unlimited) AS stock_unlimited_max FROM dtb_products_class GROUP BY product_id) AS T2 ON T1.product_id = T2.product_id_sub
+    ) ',
+
+	"vw_products_allclass_detail" => '
+		(SELECT product_id,price01_min,price01_max,price02_min,price02_max,stock_min,stock_max,stock_unlimited_min,stock_unlimited_max,
+		del_flg,status,name,comment1,comment2,comment3,deliv_fee,main_comment,main_image,main_large_image,
+		sub_title1,sub_comment1,sub_image1,sub_large_image1,
+		sub_title2,sub_comment2,sub_image2,sub_large_image2,
+		sub_title3,sub_comment3,sub_image3,sub_large_image3,
+		sub_title4,sub_comment4,sub_image4,sub_large_image4,
+		sub_title5,sub_comment5,sub_image5,sub_large_image5,
+		product_flag,deliv_date_id,sale_limit,point_rate,sale_unlimited,file1,file2,category_id
+		FROM ( SELECT * FROM (dtb_products AS T1 RIGHT JOIN 
+		(SELECT 
+		product_id AS product_id_sub,
+		MIN(price01) AS price01_min,
+		MAX(price01) AS price01_max,
+		MIN(price02) AS price02_min,
+		MAX(price02) AS price02_max,
+		MIN(stock) AS stock_min,
+		MAX(stock) AS stock_max,
+		MIN(stock_unlimited) AS stock_unlimited_min,
+		MAX(stock_unlimited) AS stock_unlimited_max
+		FROM dtb_products_class GROUP BY product_id) AS T2
+		ON T1.product_id = T2.product_id_sub ) ) AS T3 LEFT JOIN (SELECT rank AS category_rank, category_id AS sub_category_id FROM dtb_category) AS T4
+		ON T3.category_id = T4.sub_category_id) ',
+
+	"vw_product_class" => '
+		(SELECT * FROM 
+		(SELECT T3.product_class_id, T3.product_id AS product_id_sub, classcategory_id1, classcategory_id2, 
+		T3.rank AS rank1, T4.rank AS rank2, T3.class_id AS class_id1, T4.class_id AS class_id2,
+		stock, price01, price02, stock_unlimited, product_code
+		FROM ( SELECT 
+		        T1.product_class_id,
+		        T1.product_id,
+		        classcategory_id1,
+		        classcategory_id2,
+		        T2.rank,
+		        T2.class_id,
+		        stock,
+		        price01,
+		        price02,
+		        stock_unlimited,
+		        product_code		
+		 FROM (dtb_products_class AS T1 LEFT JOIN dtb_classcategory AS T2
+		ON T1.classcategory_id1 = T2.classcategory_id))
+		AS T3 LEFT JOIN dtb_classcategory AS T4
+		ON T3.classcategory_id2 = T4.classcategory_id) AS T5 LEFT JOIN dtb_products AS T6
+		ON product_id_sub = T6.product_id) ',
+
+	"vw_category_count" => '
+		(SELECT T1.category_id, T1.category_name, T1.parent_category_id, T1.level, T1.rank, T2.product_count
+		FROM dtb_category AS T1 LEFT JOIN dtb_category_total_count AS T2
+		ON T1.category_id = T2.category_id) '
+);
+
+?>
Index: /branches/beta/html/test/naka/md5.php
===================================================================
--- /branches/beta/html/test/naka/md5.php	(revision 14676)
+++ /branches/beta/html/test/naka/md5.php	(revision 14676)
@@ -0,0 +1,3 @@
+<?php
+    print(md5("yamayama"));
+?>
Index: /branches/beta/html/test/naka/header.php
===================================================================
--- /branches/beta/html/test/naka/header.php	(revision 14676)
+++ /branches/beta/html/test/naka/header.php	(revision 14676)
@@ -0,0 +1,4 @@
+<?php
+    print("test");
+    header("Location: http://www.ec-cube.net/");
+?>
Index: /branches/beta/html/test/takayuki/test_json.php
===================================================================
--- /branches/beta/html/test/takayuki/test_json.php	(revision 14676)
+++ /branches/beta/html/test/takayuki/test_json.php	(revision 14676)
@@ -0,0 +1,23 @@
+<?php
+/*
+ * Created on 2007/05/17
+ *
+ * To change the template for this generated file go to
+ * Window - Preferences - PHPeclipse - PHP - Code Templates
+ */
+ 
+ require_once('JSON.php');
+
+    $json = new JSON();
+
+    $obj = array(
+       id   => array("foo", "bar", array( aa => 'bb')),
+       hoge => 'boge',
+       no   => 123 ,
+       bo   => true
+    );
+    
+    $js = $json->encode($obj);
+    print "$js";
+ 
+?>
Index: /branches/beta/html/test/uehara/ftp.php
===================================================================
--- /branches/beta/html/test/uehara/ftp.php	(revision 14676)
+++ /branches/beta/html/test/uehara/ftp.php	(revision 14676)
@@ -0,0 +1,40 @@
+<?php
+
+
+$TEST_DIR = realpath(dirname( __FILE__));
+require_once($TEST_DIR . "/../../require.php");
+require_once($TEST_DIR . "/../../../data/include/ftp.php");
+
+// FTP²èÁüÊÝÂ¸ÁêÂÐ¥Ñ¥¹
+define("FTP_IMAGE_SAVE_DIR", "./html" . URL_DIR . "upload/save_image/");
+// FTP²èÁü°ì»þÊÝÂ¸ÁêÂÐ¥Ñ¥¹
+define("FTP_IMAGE_TEMP_DIR", "./html" . URL_DIR . "upload/temp_image/");
+define ("IMAGE_TEMP_DIR", HTML_PATH . "upload/temp_image/");                // ²èÁü°ì»þÊÝÂ¸
+define ("IMAGE_SAVE_DIR", HTML_PATH . "upload/save_image/");                // ²èÁüÊÝÂ¸Àè
+
+
+ftpMoveTempFile(FTP_IMAGE_TEMP_DIR);
+
+//----------------------------------------------------------------------------
+
+// ¥Õ¥¡¥¤¥ë¤Î¹¹¿·¤òÂ¾¥µ¡¼¥Ð¤Ë¤âÈ¿±Ç¤¹¤ë¡£
+function ftpMoveTempFile($ftp_image_save_dir) {
+    global $arrWEB_SERVERS;
+    
+    $arrFiles = array();
+    $arrFiles[] = '06081024_4668afcc10571.jpg';
+    
+    // Éé²ÙÊ¬»¶¤·¤Æ¤¤¤ëÁ´¤Æ¤Î¥µ¡¼¥Ð¤Ë¥Õ¥¡¥¤¥ë¤ò¥³¥Ô¡¼¤¹¤ë
+    foreach($arrFiles as $files) {
+        foreach($arrWEB_SERVERS as $array) {
+               $dst_path = $ftp_image_save_dir . $files;
+               $src_path = IMAGE_TEMP_DIR . $files;
+               
+echo $dst_path;
+               sfFtpDelete($array['host'], $array['user'], $array['pass'], $dst_path);
+//               sfFtpCopy($array['host'], $array['user'], $array['pass'], $dst_path, $src_path);            
+        }
+    }
+}
+
+?>
Index: /branches/beta/html/define.php
===================================================================
--- /branches/beta/html/define.php	(revision 12179)
+++ /branches/beta/html/define.php	(revision 14676)
@@ -1,4 +1,4 @@
 <?php
 	// HTML¥Ç¥£¥ì¥¯¥È¥ê¤«¤é¤ÎDATA¥Ç¥£¥ì¥¯¥È¥ê¤ÎÁêÂÐ¥Ñ¥¹
-	define("HTML2DATA_DIR", "/../data/")
+	define("HTML2DATA_DIR", "/../data/");
 ?>
Index: /branches/beta/html/shopping/complete.php
===================================================================
--- /branches/beta/html/shopping/complete.php	(revision 11615)
+++ /branches/beta/html/shopping/complete.php	(revision 14676)
@@ -58,5 +58,12 @@
 	// ´°Î»¥á¡¼¥ëÁ÷¿®
 	if($order_id != "") {
-		sfSendOrderMail($order_id, '1');
+		$order_email = $objQuery->select("order_email", "dtb_order", "order_id = ?", array($order_id));
+    
+    //ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¥á¡¼¥ë¥¢¥É¥ì¥¹¤¬·ÈÂÓ¤«PC¤«¤Ë±þ¤¸¤ÆÃíÊ¸´°Î»¥á¡¼¥ë¤Î¥Æ¥ó¥×¥ì¡¼¥È¤òÊÑ¤¨¤ë
+    if(ereg("(ezweb.ne.jp$|docomo.ne.jp$|softbank.ne.jp$|vodafone.ne.jp$)",$order_email[0]['order_email'])){
+              sfSendOrderMail($order_id, '1',"","");
+        }else{
+              sfSendOrderMail($order_id, '0',"","");
+        }
 	}
 
@@ -200,5 +207,5 @@
 	lfDeleteTempOrder($objQuery, $uniqid);
 	// ¥­¥ã¥ó¥Ú¡¼¥ó¤«¤é¤ÎÁ«°Ü¤Î¾ì¹çÅÐÏ¿¤¹¤ë¡£
-	if($objCampaignSess->getIsCampaign()) {
+	if($objCampaignSess->getIsCampaign() and $objCartSess->chkCampaign($objCampaignSess->getCampaignId())) {
 		lfRegistCampaignOrder($objQuery, $objCampaignSess, $order_id);
 	}
Index: /branches/beta/html/shopping/confirm.php
===================================================================
--- /branches/beta/html/shopping/confirm.php	(revision 232)
+++ /branches/beta/html/shopping/confirm.php	(revision 14676)
@@ -79,11 +79,14 @@
 // ·èºÑ¶èÊ¬¤ò¼èÆÀ¤¹¤ë
 $payment_type = "";
+$module_id = "";
 if(sfColumnExists("dtb_payment", "memo01")){
-	// MEMO03¤ËÃÍ¤¬Æþ¤Ã¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢¥â¥¸¥å¡¼¥ëÄÉ²Ã¤µ¤ì¤¿¤â¤Î¤È¤ß¤Ê¤¹
-	$sql = "SELECT memo03 FROM dtb_payment WHERE payment_id = ?";
+	// module_id¤ËÃÍ¤¬Æþ¤Ã¤Æ¤¤¤ë¾ì¹ç¤Ë¤Ï¡¢¥â¥¸¥å¡¼¥ëÄÉ²Ã¤µ¤ì¤¿¤â¤Î¤È¤ß¤Ê¤¹
+	$sql = "SELECT module_id,memo03 FROM dtb_payment WHERE payment_id = ?";
 	$arrPayment = $objQuery->getall($sql, array($arrData['payment_id']));
 	$payment_type = $arrPayment[0]["memo03"];
+    $module_id =  $arrPayment[0]["module_id"];
 }
 $objPage->payment_type = $payment_type;
+
 
 
@@ -112,5 +115,5 @@
 	
 	// ·èºÑÊýË¡¤Ë¤è¤ê²èÌÌÀÚÂØ
-	if($payment_type != "") {
+	if(!empty($module_id)) {
 		$_SESSION["payment_id"] = $arrData['payment_id'];
 		header("Location: " . URL_SHOP_MODULE);
Index: /branches/beta/html/admin/products/product.php
===================================================================
--- /branches/beta/html/admin/products/product.php	(revision 12021)
+++ /branches/beta/html/admin/products/product.php	(revision 14676)
@@ -50,5 +50,5 @@
 
 // ¥Õ¥¡¥¤¥ë´ÉÍý¥¯¥é¥¹
-$objUpFile = new SC_UploadFile(IMAGE_TEMP_DIR, IMAGE_SAVE_DIR);
+$objUpFile = new SC_UploadFile(IMAGE_TEMP_DIR, IMAGE_SAVE_DIR, FTP_IMAGE_TEMP_DIR, FTP_IMAGE_SAVE_DIR, MULTI_WEB_SERVER_MODE);
 
 // ¥Õ¥¡¥¤¥ë¾ðÊó¤Î½é´ü²½
@@ -439,5 +439,5 @@
 	$arrConvList['product_code'] = "KVna";
 	$arrConvList['comment1'] = "a";
-	//¥Û¥Í¥±¡¼¥­:Á÷ÎÁ¤Î»ØÄê¤Ê¤·
+	// Á÷ÎÁ¤Î»ØÄê¤Ê¤·
 	$arrConvList['deliv_fee'] = "n";
 	
@@ -556,5 +556,5 @@
 			// °ìÍ÷¥á¥¤¥ó²èÁü
 			lfMakeScaleImage($_POST['image_key'], "main_list_image");
-			break;
+            break;
 		case "sub_large_image" . $subno:
 			// ¥µ¥Ö¥á¥¤¥ó²èÁü
Index: /branches/beta/html/admin/products/upload_csv.php
===================================================================
--- /branches/beta/html/admin/products/upload_csv.php	(revision 373)
+++ /branches/beta/html/admin/products/upload_csv.php	(revision 14676)
@@ -188,5 +188,5 @@
 	$objFormParam->addParam("¹ØÆþÀ©¸Â", "sale_limit", INT_LEN, "n", array("MAX_LENGTH_CHECK","NUM_CHECK"));
 	$objFormParam->addParam("¥á¡¼¥«¡¼URL", "comment1", URL_LEN, "KVa", array("SPTAB_CHECK","URL_CHECK","MAX_LENGTH_CHECK"));
-	$objFormParam->addParam("¸¡º÷¥ï¡¼¥É", "comment3", STEXT_LEN, "KVa", array("SPTAB_CHECK","MAX_LENGTH_CHECK"));
+	$objFormParam->addParam("¸¡º÷¥ï¡¼¥É", "comment3", LLTEXT_LEN, "KVa", array("SPTAB_CHECK","MAX_LENGTH_CHECK"));
 	$objFormParam->addParam("°ìÍ÷-¥á¥¤¥ó¥³¥á¥ó¥È", "main_list_comment", LTEXT_LEN, "KVa", array("EXIST_CHECK","SPTAB_CHECK","MAX_LENGTH_CHECK"));
 	$objFormParam->addParam("°ìÍ÷-¥á¥¤¥ó²èÁü", "main_list_image", LTEXT_LEN, "KVa", array("EXIST_CHECK","FILE_EXISTS","SPTAB_CHECK","MAX_LENGTH_CHECK"));
Index: /branches/beta/html/admin/order/mail.php
===================================================================
--- /branches/beta/html/admin/order/mail.php	(revision 339)
+++ /branches/beta/html/admin/order/mail.php	(revision 14676)
@@ -8,4 +8,7 @@
 
 class LC_Page {
+    
+    var $mailTemp;
+    var $arrMAILTEMPLATE;
 	function LC_Page() {
 		$this->tpl_mainpage = 'order/mail.tpl';
@@ -14,6 +17,6 @@
 		$this->tpl_subno = 'index';
 		$this->tpl_subtitle = '¼õÃí´ÉÍý';
-		global $arrMAILTEMPLATE;
-		$this->arrMAILTEMPLATE = $arrMAILTEMPLATE;
+		
+		
 	}
 }
@@ -22,4 +25,11 @@
 $objView = new SC_AdminView();
 $objSess = new SC_Session();
+
+// ¥Ñ¥é¥á¡¼¥¿´ÉÍý¥¯¥é¥¹
+$objFormParam = new SC_FormParam();
+// ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
+lfInitParam();
+
+// Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
 sfIsSuccess($objSess);
 
@@ -32,9 +42,21 @@
 
 $objPage->tpl_order_id = $_POST['order_id'];
+// DB¤«¤é¼õÃí¾ðÊó¤òÆÉ¤ß¹þ¤à
+lfGetOrderData($_POST['order_id']);
 
-// ¥Ñ¥é¥á¡¼¥¿´ÉÍý¥¯¥é¥¹
-$objFormParam = new SC_FormParam();
-// ¥Ñ¥é¥á¡¼¥¿¾ðÊó¤Î½é´ü²½
-lfInitParam();
+// --¥Æ¥ó¥×¥ì¡¼¥È¡¿¥×¥ë¥À¥¦¥ó¥á¥Ë¥å¡¼¤ÎºîÀ®
+$conn = new SC_DbConn();
+$sql = "SELECT * FROM dtb_mailtemplate WHERE del_flg=0 ORDER BY template_id ASC";
+
+$Temp = $conn->getAll($sql);//$Temp¤Ë¼èÆÀ¤·¤¿¥Ç¡¼¥¿¤ò°ì»þÅª¤Ë³ÊÇ¼
+//¥Æ¥ó¥×¥ì¡¼¥È¥Õ¥¡¥¤¥ë¤Ë½ÐÎÏ¤¹¤ë¤¿¤á¤ËÆó¼¡¸µÇÛÎó¤ËÂåÆþ¤¹¤ë
+for($i = 0;$i < count($Temp);$i++){
+    $arrTemplate[0][$i] = $Temp[$i]['template_id'];
+    $arrTemplate[1][$i] = $Temp[$i]['template_name'];
+}
+
+//¥Æ¥ó¥×¥ì¡¼¥È¥Õ¥¡¥¤¥ë¤Ø¥Ç¡¼¥¿¤òÂåÆþ
+$objPage->mailTemp = $arrTemplate;
+$objPage->arrMAILTEMPLATE = $arrTemplate[1];
 
 switch($_POST['mode']) {
@@ -54,5 +76,5 @@
 	if (count($objPage->arrErr) == 0) {
 		// ÃíÊ¸¼õÉÕ¥á¡¼¥ë
-		sfSendOrderMail($_POST['order_id'], $_POST['template_id'], $_POST['subject'], $_POST['header'], $_POST['footer']);
+		sfSendOrderMail($_POST['order_id'], $_POST['template_id'], $_POST['subject'], $_POST['body']);
 	}
 	header("Location: " . URL_SEARCH_ORDER);
@@ -70,5 +92,5 @@
 	if (count($objPage->arrErr) == 0) {
 		// ÃíÊ¸¼õÉÕ¥á¡¼¥ë(Á÷¿®¤Ê¤·)
-		$objSendMail = sfSendOrderMail($_POST['order_id'], $_POST['template_id'], $_POST['subject'], $_POST['header'], $_POST['footer'], false);
+		$objSendMail = sfSendOrderMail($_POST['order_id'], $_POST['template_id'], $_POST['subject'], $_POST['body'], false);
 		// ³ÎÇ§¥Ú¡¼¥¸¤ÎÉ½¼¨
 		$objPage->tpl_subject = $objSendMail->subject;
@@ -85,10 +107,14 @@
 case 'change':
 	// POSTÃÍ¤Î¼èÆÀ
+    
 	$objFormParam->setValue('template_id', $_POST['template_id']);
-	if(sfIsInt($_POST['template_id'])) {
-		$objQuery = new SC_Query();
+    
+    //¥Æ¥ó¥×¥ì¡¼¥È¥Õ¥¡¥¤¥ë¤ÇÁªÂò¤µ¤ì¤¿¥Æ¥ó¥×¥ì¡¼¥ÈÌ¾¤ò¥Æ¥ó¥×¥ì¡¼¥ÈID¤È´ØÏ¢ÉÕ¤±¤ë
+    $_POST['template_id'] = $arrTemplate[0][$_POST['template_id']];
+    if(sfIsInt($_POST['template_id'])) {
+        $objQuery = new SC_Query();
 		$where = "template_id = ?";
-		$arrRet = $objQuery->select("subject, header, footer", "dtb_mailtemplate", $where, array($_POST['template_id']));
-		$objFormParam->setParam($arrRet[0]);
+		$arrRet = $objQuery->select("subject, body", "dtb_mailtemplate", $where, array($_POST['template_id']));
+        $objFormParam->setParam($arrRet[0]);
 	}
 	break;
@@ -113,5 +139,21 @@
 	$objFormParam->addParam("¥Æ¥ó¥×¥ì¡¼¥È", "template_id", INT_LEN, "n", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
 	$objFormParam->addParam("¥á¡¼¥ë¥¿¥¤¥È¥ë", "subject", STEXT_LEN, "KVa",  array("EXIST_CHECK", "MAX_LENGTH_CHECK", "SPTAB_CHECK"));
-	$objFormParam->addParam("¥Ø¥Ã¥À¡¼", "header", LTEXT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "SPTAB_CHECK"));
-	$objFormParam->addParam("¥Õ¥Ã¥¿¡¼", "footer", LTEXT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "SPTAB_CHECK"));
+	$objFormParam->addParam("¥Ø¥Ã¥À¡¼", "body", LTEXT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "SPTAB_CHECK"));
+	//$objFormParam->addParam("¥Õ¥Ã¥¿¡¼", "footer", LTEXT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "SPTAB_CHECK"));
 }
+
+function lfGetOrderData($order_id) {
+	global $objFormParam;
+	global $objPage;
+	if(sfIsInt($order_id)) {
+		// DB¤«¤é¼õÃí¾ðÊó¤òÆÉ¤ß¹þ¤à
+		$objQuery = new SC_Query();
+		$where = "order_id = ?";
+		$arrRet = $objQuery->select("*", "dtb_order", $where, array($order_id));
+		$objFormParam->setParam($arrRet[0]);
+		list($point, $total_point) = sfGetCustomerPoint($order_id, $arrRet[0]['use_point'], $arrRet[0]['add_point']);
+		$objFormParam->setValue('total_point', $total_point);
+		$objFormParam->setValue('point', $point);
+		$objPage->arrDisp = $arrRet[0];
+	}
+}
Index: /branches/beta/html/admin/order/index.php
===================================================================
--- /branches/beta/html/admin/order/index.php	(revision 225)
+++ /branches/beta/html/admin/order/index.php	(revision 14676)
@@ -248,6 +248,6 @@
 			$objNavi = new SC_PageNavi($_POST['search_pageno'], $linemax, $page_max, "fnNaviSearchPage", NAVI_PMAX);
 			$startno = $objNavi->start_row;
-			$objPage->arrPagenavi = $objNavi->arrPagenavi;		
-			
+			$objPage->arrPagenavi = $objNavi->arrPagenavi;
+		
 			// ¼èÆÀÈÏ°Ï¤Î»ØÄê(³«»Ï¹ÔÈÖ¹æ¡¢¹Ô¿ô¤Î¥»¥Ã¥È)
 			$objQuery->setlimitoffset($page_max, $startno);
@@ -263,5 +263,4 @@
 	break;
 }
-
 $objDate = new SC_Date();
 // ÅÐÏ¿¡¦¹¹¿·Æü¸¡º÷ÍÑ
Index: /branches/beta/html/admin/batch/daily.php
===================================================================
--- /branches/beta/html/admin/batch/daily.php	(revision 387)
+++ /branches/beta/html/admin/batch/daily.php	(revision 14676)
@@ -49,5 +49,5 @@
 		
 	// ºÇ¸å¤Î¥Ð¥Ã¥Á¼Â¹Ô¤«¤éLOAD_BATCH_PASSÉÃ·Ð²á¤·¤Æ¤¤¤Ê¤¤¤È¼Â¹Ô¤·¤Ê¤¤¡£
-	if($pass < LOAD_BATCH_PASS) {
+	if(!$command && $pass < LOAD_BATCH_PASS) {
 		gfPrintLog("LAST BATCH " . $arrRet[0]['create_date'] . " > " . $batch_pass . " -> EXIT BATCH $batch_date");
 		return;
@@ -66,6 +66,11 @@
 		lfBatOrderAge($tmp_time);
 		
-		// ¥¿¥¤¥à¥¢¥¦¥È¤òËÉ¤°
-		sfFlush();
+        // ¥Ö¥é¥¦¥¶¤«¤é¤Î¼Â¹Ô¤Î¾ì¹ç
+        if(!$command) {
+            // ¥¿¥¤¥à¥¢¥¦¥È¤òËÉ¤°
+            sfFlush();
+        } else {
+            print("LOADING BATCH $batch_date\n");
+        }
 	}
 }
@@ -91,5 +96,5 @@
 			$create_time = strtotime($create_date);
 			$order_time = strtotime($order_date);
-			// ¥ª¡¼¥À¡¼³«»ÏÆü¤è¤ê°ìÆü°Ê¾å¸å¤Ë½¸·×¤µ¤ì¤Æ¤¤¤ë¾ì¹ç¤Ï½¸·×¤·¤Ê¤ª¤µ¤Ê¤¤
+			// ½¸·×³«»ÏÆü¤è¤ê1Æü°Ê¾å¸å¤Ë½¸·×¤µ¤ì¤Æ¤¤¤ë¾ì¹ç¤Ï½¸·×¤·¤Ê¤ª¤µ¤Ê¤¤
 			if($order_time + 86400 < $create_time || $tmp_time > time()) {
 				gfPrintLog("EXIT BATCH $batch_date $tmp_time" . " " . time());
Index: /branches/beta/html/admin/mail/sendmail.php
===================================================================
--- /branches/beta/html/admin/mail/sendmail.php	(revision 11808)
+++ /branches/beta/html/admin/mail/sendmail.php	(revision 14676)
@@ -11,42 +11,46 @@
 
 if(MELMAGA_SEND != true) {
-	exit;
-}
-
+    exit;
+}
+
+//¥ê¥¢¥ë¥¿¥¤¥àÇÛ¿®¥â¡¼¥É¤¬¥ª¥ó¤Î¤È¤­
 if($_GET['mode'] == 'now') {
-	//----¡¡Ì¤Á÷¿®¥Ç¡¼¥¿¤ò¼èÆÀ¤¹¤ë
-	$time_data = $conn->getAll( "SELECT send_id FROM dtb_send_history  WHERE complete_count = 0 AND del_flg = 0 ORDER BY send_id ASC, start_date ASC" );
+    //----¡¡Ì¤Á÷¿®¥Ç¡¼¥¿¤ò¼èÆÀ¤¹¤ë
+    $time_data = $conn->getAll( "SELECT send_id FROM dtb_send_history  WHERE complete_count = 0 AND del_flg = 0 ORDER BY send_id ASC, start_date ASC" );
 } else {
-	
-	// postgresql ¤È mysql ¤È¤ÇSQL¤ò¤ï¤±¤ë
-	if (DB_TYPE == "pgsql") {
-		$sql = "SELECT send_id FROM dtb_send_history  ";
-		$sql.= "WHERE start_date  BETWEEN current_timestamp + '- 5 minutes' AND current_timestamp + '5 minutes' AND del_flg = 0 ORDER BY send_id ASC, start_date ASC";
-	}else if (DB_TYPE == "mysql") {
-		$sql = "SELECT send_id FROM dtb_send_history  ";
-		$sql.= "WHERE start_date  BETWEEN date_add(now(),INTERVAL -5 minute) AND date_add(now(),INTERVAL 5 minute) AND del_flg = 0 ORDER BY send_id ASC, start_date ASC";
-	}	
-	//----¡¡30Ê¬Ëè¤ËCron¤¬Á÷¿®»þ´Ö¥Ç¡¼¥¿³ÎÇ§
-	$time_data = $conn->getAll($sql);
-}
-
+    
+    // postgresql ¤È mysql ¤È¤ÇSQL¤ò¤ï¤±¤ë
+    if (DB_TYPE == "pgsql") {
+        $sql = "SELECT send_id FROM dtb_send_history  ";
+        $sql.= "WHERE start_date  BETWEEN current_timestamp + '- 5 minutes' AND current_timestamp + '5 minutes' AND del_flg = 0 ORDER BY send_id ASC, start_date ASC";
+    }else if (DB_TYPE == "mysql") {
+        $sql = "SELECT send_id FROM dtb_send_history  ";
+        $sql.= "WHERE start_date  BETWEEN date_add(now(),INTERVAL -5 minute) AND date_add(now(),INTERVAL 5 minute) AND del_flg = 0 ORDER BY send_id ASC, start_date ASC";
+    }   
+    //----¡¡30Ê¬Ëè¤ËCron¤¬Á÷¿®»þ´Ö¥Ç¡¼¥¿³ÎÇ§
+    $time_data = $conn->getAll($sql);
+}
+
+//Ì¤Á÷¿®¥á¡¼¥ë¤Î¿ô
 $count = count($time_data);
 
+//Ì¤Á÷¿®¥á¡¼¥ë¤¬¤¢¤ì¤ÐÁ÷¿®½èÍý¤òÂ³¤±¤ë¡£¤Ê¤±¤ì¤ÐÃæÃÇ¤¹¤ë¡£
 if( $count > 0 ){
-	print("start sending <br />\n");
+    print("start sending <br />\n");
+
 } else {
-	print("not found <br />\n");
-	exit;
-}
-
-//---- ¥á¡¼¥ëÁ÷¿®
-for( $i = 0; $i < count( $time_data ); $i++ ) {
-
-	$sql = "SELECT * FROM dtb_send_customer WHERE send_id = ? AND (send_flag = 2 OR send_flag IS NULL)";
-	$list_data[] = $conn->getAll( $sql, array( $time_data[$i]["send_id"] ) );
-	
-	$sql = "SELECT * FROM dtb_send_history WHERE send_id = ?";
-	$mail_data[] = $conn->getAll( $sql, array(  $time_data[$i]["send_id"] ) );
-
+    print("not found <br />\n");
+    exit;
+}
+
+//---- ¥á¡¼¥ëÁ÷¿®½àÈ÷
+for( $i = 0; $i < $count; $i++ ) {
+
+    $sql = "SELECT * FROM dtb_send_customer WHERE send_id = ? AND (send_flag = 2 OR send_flag IS NULL)";
+    $list_data[] = $conn->getAll( $sql, array( $time_data[$i]["send_id"] ) );
+    
+    $sql = "SELECT * FROM dtb_send_history WHERE send_id = ?";
+    $mail_data[] = $conn->getAll( $sql, array( $time_data[$i]["send_id"] ) );
+    
 }
 
@@ -55,12 +59,14 @@
 $objMail = new GC_SendMail();
 
+
+
 //----¡¡¥á¡¼¥ëÀ¸À®¤ÈÁ÷¿®
-for( $i = 0; $i < count( $time_data ); $i++ ) {
-
-	for( $j = 0; $j < count( $list_data[$i] ); $j ++ ) {
-
-		$customerName = "";
-		$mailBody = "";
-		$sendFlag = "";
+for( $i = 0; $i < $count; $i++ ) {
+
+    for( $j = 0; $j < count( $list_data[$i] ); $j ++ ) {
+
+        $customerName = "";
+        $mailBody = "";
+        $sendFlag = "";
 
 		//-- ¸ÜµÒÌ¾¤ÎÊÑ´¹
@@ -75,72 +81,118 @@
 		$mailBody = ereg_replace( "{name}", $customerName ,  $mail_data[$i][0]["body"] );
 
-		//-- ¥Æ¥­¥¹¥È¥á¡¼¥ëÇÛ¿®¤Î¾ì¹ç	
-		if( $mail_data[$i][0]["mail_method"] == 2 ) {
-
-			$sendResut = MAIL_SENDING(
-										 $list_data[$i][$j]["email"]				//¡¡¸ÜµÒ°¸Àè
-										,$subjectBody								//¡¡Subject
-										,$mailBody									//¡¡¥á¡¼¥ëËÜÊ¸
-										,$objSite->data["email03"]					//¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹
-										,$objSite->data["company_name"]				//¡¡Á÷¿®¸µÌ¾
-										,$objSite->data["email03"]					//¡¡reply_to
-										,$objSite->data["email04"]					//¡¡return_path
-										,$objSite->data["email04"]					//¡¡errors_to
-																			 );
-
-		//--  HTML¥á¡¼¥ëÇÛ¿®¤Î¾ì¹ç	
-		} elseif( $mail_data[$i][0]["mail_method"] == 1 || $mail_data[$i][0]["mail_method"] == 3) {
-			
-			$sendResut = HTML_MAIL_SENDING(
-											 $list_data[$i][$j]["email"]
-											,$subjectBody
-											,$mailBody
-											,$objSite->data["email03"]					//¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹
-											,$objSite->data["company_name"]				//¡¡Á÷¿®¸µÌ¾
-											,$objSite->data["email03"]					//¡¡reply_to
-											,$objSite->data["email04"]					//¡¡return_path
-											,$objSite->data["email04"]					//¡¡errors_to
-																	 );
-		}
-	
-		//-- Á÷¿®´°Î»¤Ê¤é1¡¢¼ºÇÔ¤Ê¤é0¤ò¥á¡¼¥ëÁ÷¿®·ë²Ì¥Õ¥é¥°¤È¤·¤ÆDB¤ËÁÞÆþ
-		if( ! $sendResut ){
-			 $sendFlag = "-1";
+
+        //-- ¥á¥ë¥Þ¥¬ÇÛ¿®¤ò¥Ö¥ì¥¤¥óÏ¢·È¤Ç¹Ô¤¦¾ì¹ç
+        if(lfGetBlayn()){
+	        
+	        //-- Ê¸»ú¤òÆüËÜ¸ì¤ËÀßÄê
+	        Mb_language( "Japanese" );
+	              
+            //-- Á÷¿®¤¹¤ë¥á¡¼¥ë¤ÎÆâÍÆ¤ÈÁ÷¿®Àè
+            $sendResut = array( 
+                          "to" => $list_data[$i][$j]["email"]        //¡¡¸ÜµÒ°¸Àè 
+	 	            ,"subject" => mb_encode_mimeheader($subjectBody) //¡¡Subject  
+	 	               ,"from" => $objSite->data["email03"]          //¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹ 
+                  ,"replay_to" => $objSite->data["email03"]          //¡¡reply_to 
+                ,"return_path" => $objSite->data["email04"]          //¡¡return_path
+                                                                       );
+            //-- ¥á¥Ã¥»¡¼¥¸¤Î¹½ÃÛ
+            $html_param['head_charset'] = "ISO-2022-JP";
+            $html_param['html_encoding'] = "ISO-2022-JP";
+            $html_param['html_charset'] = "JIS";
+            
+            //-- ¥Ö¥ì¥¤¥óSMTP¥µ¡¼¥Ð¡¼IP¥¢¥É¥ì¥¹ 
+            $sql = "SELECT blayn_ip FROM dtb_blayn";
+            $host = $conn->getAll($sql);
+            $param = array(   
+                       'host' => $host[0][blayn_ip]
+                      ,'port' => SMTP_PORT_BLAYN                  
+                                                  );
+
+	 	    //-- Mail_mime¥ª¥Ö¥¸¥§¥¯¥ÈºîÀ®
+            $mail_mimeObj = new Mail_mime();
+            
+            //-- Mail_mime¥ª¥Ö¥¸¥§¥¯¥È¤ËHTML¤ÎËÜÊ¸¤òÄÉ²Ã
+            $mailBody = mb_convert_encoding($mailBody, "JIS", CHAR_CODE);
+            $mail_mimeObj->setHTMLBody($mailBody);
+            
+            $body = $mail_mimeObj->get($html_param);
+            $header = $mail_mimeObj->headers($sendResut);
+            
+            //-- PEAR::Mail¤ò»È¤Ã¤Æ¥á¡¼¥ëÁ÷¿®¥ª¥Ö¥¸¥§¥¯¥ÈºîÀ®
+            $mailObj =& Mail::factory("smtp", $param);
+            // ¥á¡¼¥ëÁ÷¿®
+            $result = $mailObj->send($sendResut["to"], $header, $body);
+
 		} else {
-			$sendFlag = "1";
-			
-			// ´°Î»¤ò1¤³Áý¤ä¤¹
-			$sql = "UPDATE dtb_send_history SET complete_count = complete_count + 1 WHERE send_id = ?";
-			$conn->query( $sql, array($mail_data[$i][0]["send_id"]) );
-		}
-
-		$conn->query( $sql_flag, array( $sendFlag, $mail_data[$i][0]["send_id"], $list_data[$i][$j]["customer_id"] ) );
-		
-		
-
-	}
-
-	//--- ¥á¡¼¥ëÁ´·ïÁ÷¿®´°Î»¸å¤Î½èÍý
-	$completeSql = "UPDATE dtb_send_history SET end_date = now() WHERE send_id = ?";
-	$conn->query( $completeSql, array( $time_data[$i]["send_id"] ) );
-
-	//---¡¡Á÷¿®´°Î»¡¡Êó¹ð¥á¡¼¥ë
-	$compData =  date("YÇ¯m·îdÆüH»þiÊ¬" . "  ²¼µ­¥á¡¼¥ë¤ÎÇÛ¿®¤¬´°Î»¤·¤Þ¤·¤¿¡£" );
-
-	HTML_MAIL_SENDING(
-					 $objSite->data["email03"]	
-					,$compData
-					,$mail_data[$i][0]["body"]
-					,$objSite->data["email03"]					//¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹
-					,$objSite->data["company_name"]				//¡¡Á÷¿®¸µÌ¾
-					,$objSite->data["email03"]					//¡¡reply_to
-					,$objSite->data["email04"]					//¡¡return_path
-					,$objSite->data["email04"]					//¡¡errors_to
-				 );
-				 
-	if ($_GET['mode'] = "now") {
-		header("Location: " . URL_DIR . "admin/mail/history.php");
-	}
-	echo "complete\n";
+	        //-- ¥Æ¥­¥¹¥È¥á¡¼¥ëÇÛ¿®¤Î¾ì¹ç
+	        if( $mail_data[$i][0]["mail_method"] == 2 ) {
+
+		        $sendResut = MAIL_SENDING(
+									     $list_data[$i][$j]["email"]				//¡¡¸ÜµÒ°¸Àè
+									    ,$subjectBody								//¡¡Subject
+									    ,$mailBody									//¡¡¥á¡¼¥ëËÜÊ¸
+									    ,$objSite->data["email03"]					//¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹
+									    ,$objSite->data["company_name"]				//¡¡Á÷¿®¸µÌ¾
+									    ,$objSite->data["email03"]					//¡¡reply_to
+									    ,$objSite->data["email04"]					//¡¡return_path
+									    ,$objSite->data["email04"]					//¡¡errors_to
+																		 );
+																		 
+
+            //--  HTML¥á¡¼¥ëÇÛ¿®¤Î¾ì¹ç  
+            } elseif( $mail_data[$i][0]["mail_method"] == 1 || $mail_data[$i][0]["mail_method"] == 3) {
+            
+                $sendResut = HTML_MAIL_SENDING(
+                                             $list_data[$i][$j]["email"]
+                                            ,$subjectBody
+                                            ,$mailBody
+                                            ,$objSite->data["email03"]                  //¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹
+                                            ,$objSite->data["company_name"]             //¡¡Á÷¿®¸µÌ¾
+                                            ,$objSite->data["email03"]                  //¡¡reply_to
+                                            ,$objSite->data["email04"]                  //¡¡return_path
+                                            ,$objSite->data["email04"]                  //¡¡errors_to
+                                                                     );
+            }
+        }
+  
+        //-- Á÷¿®´°Î»¤Ê¤é1¡¢¼ºÇÔ¤Ê¤é-1¤ò¥á¡¼¥ëÁ÷¿®·ë²Ì¥Õ¥é¥°¤È¤·¤ÆDB¤ËÁÞÆþ
+        if( ! $sendResut ){
+            $sendFlag = "-1";
+        } else {
+            $sendFlag = "1";
+            
+            // ´°Î»¤ò 1 Áý¤ä¤¹
+            $sql = "UPDATE dtb_send_history SET complete_count = complete_count + 1 WHERE send_id = ?";
+            $conn->query( $sql, array($mail_data[$i][0]["send_id"]));
+        }
+
+        $conn->query( $sql_flag, array( $sendFlag, $mail_data[$i][0]["send_id"], $list_data[$i][$j]["customer_id"] ) );
+        
+        
+
+    }
+
+    //--- ¥á¡¼¥ëÁ´·ïÁ÷¿®´°Î»¸å¤Î½èÍý
+    $completeSql = "UPDATE dtb_send_history SET end_date = now() WHERE send_id = ?";
+    $conn->query( $completeSql, array( $time_data[$i]["send_id"] ) );
+
+    //---¡¡Á÷¿®´°Î»¡¡Êó¹ð¥á¡¼¥ë
+    $compData =  date("YÇ¯m·îdÆüH»þiÊ¬" . "  ²¼µ­¥á¡¼¥ë¤ÎÇÛ¿®¤¬´°Î»¤·¤Þ¤·¤¿¡£" );
+
+    HTML_MAIL_SENDING(
+                     $objSite->data["email03"]  
+                    ,$compData
+                    ,$mail_data[$i][0]["body"]
+                    ,$objSite->data["email03"]                  //¡¡Á÷¿®¸µ¥á¡¼¥ë¥¢¥É¥ì¥¹
+                    ,$objSite->data["company_name"]             //¡¡Á÷¿®¸µÌ¾
+                    ,$objSite->data["email03"]                  //¡¡reply_to
+                    ,$objSite->data["email04"]                  //¡¡return_path
+                    ,$objSite->data["email04"]                  //¡¡errors_to
+                 );
+               
+    if ($_GET['mode'] = "now") {
+        header("Location: " . URL_DIR . "admin/mail/history.php");
+    }
+    echo "complete\n";
 
 }
@@ -150,12 +202,11 @@
 function MAIL_SENDING( $to, $subject, $body, $fromaddress, $from_name, $reply_to, $return_path, $errors_to="", $bcc="", $cc ="" ) {
 
-
-	$mail_obj = new GC_SendMail();	
-	$mail_obj->setItem( $to, $subject, $body, $fromaddress, $from_name, $reply_to, $return_path, $errors_to, $bcc, $cc );
-		
-	if( $mail_obj->sendMail() ) {
-		return true;
-	}
-	
+    $mail_obj = new GC_SendMail();  
+    $mail_obj->setItem( $to, $subject, $body, $fromaddress, $from_name, $reply_to, $return_path, $errors_to, $bcc, $cc );
+        
+    if( $mail_obj->sendMail() ) {
+        return true;
+    }
+    
 }
 
@@ -163,15 +214,26 @@
 function HTML_MAIL_SENDING( $to, $subject, $body, $fromaddress, $from_name, $reply_to, $return_path, $errors_to="", $bcc="", $cc ="" ) {
 
-
-	$html_mail_obj = new GC_SendMail();
-	$html_mail_obj->setItemHtml( $to, $subject, $body, $fromaddress, $from_name, $reply_to, $return_path, $errors_to, $bcc, $cc );
-
-			
-	if( $html_mail_obj->sendHtmlMail() ) {
-		return true;	
-	}
-	
-}
-
-
+    $html_mail_obj = new GC_SendMail();
+    $html_mail_obj->setItemHtml( $to, $subject, $body, $fromaddress, $from_name, $reply_to, $return_path, $errors_to, $bcc, $cc );
+            
+    if( $html_mail_obj->sendHtmlMail() ) {
+        return true;    
+    }
+    
+}
+
+// ¥Ö¥ì¥¤¥ó¥¨¥ó¥¸¥ó¤¬ÀßÄêºÑ¤ß¤«³ÎÇ§
+function lfGetBlayn() {
+    
+    $objQuery = new SC_Query();
+    
+    $arrRet[now_version] = $objQuery->count("dtb_module", "now_version = (SELECT now_version FROM dtb_module WHERE main_php='blayn/blayn.php')");
+    $arrRet[blayn_ip] = $objQuery->count("dtb_blayn");
+    
+    if (!empty($arrRet[now_version]) && !empty($arrRet[blayn_ip])) {
+        return true;
+    } else {
+        return false;
+    }
+}
 ?>
Index: /branches/beta/html/admin/mail/inc_mailmagazine.php
===================================================================
--- /branches/beta/html/admin/mail/inc_mailmagazine.php	(revision 11772)
+++ /branches/beta/html/admin/mail/inc_mailmagazine.php	(revision 14676)
@@ -70,12 +70,12 @@
 							array(  "column" => "buy_end_month",	"convert" => "n" ),
 							array(  "column" => "buy_end_day",		"convert" => "n" ),
-							array(  "column" => "buy_product_code",	"convert" => "aKV" )
-							,array(  "column" => "buy_product_name",	"convert" => "aKV" )
-							,array(  "column" => "category_id",	"convert" => "" )			
-							,array(  "column" => "buy_total_from",	"convert" => "n" )		
-							,array(  "column" => "buy_total_to",	"convert" => "n" )
-							,array(  "column" => "campaign_id",	"convert" => "" )
-							,array(  "column" => "mail_type",			"convert" => "" )
-
+							array(  "column" => "buy_product_code",	"convert" => "aKV" ),
+							array(  "column" => "buy_product_name", "convert" => "aKV" ),
+							array(  "column" => "category_id",	    "convert" => ""  ),		
+							array(  "column" => "buy_total_from",	"convert" => "n" ),	
+							array(  "column" => "buy_total_to",	    "convert" => "n" ),
+							array(  "column" => "campaign_id",	    "convert" => ""  ),
+							array(  "column" => "mail_type",		"convert" => ""  ),
+							array(  "column" => "domain",           "convert" => "" )
 					);
 
@@ -216,5 +216,5 @@
 	if ( $flag ){
 		$objErr->doFunc(array("¥Æ¥ó¥×¥ì¡¼¥È", "template_id"), array("EXIST_CHECK", "NUM_CHECK"));
-		$objErr->doFunc(array("¥á¡¼¥ëÁ÷¿®Ë¡Ë¡", "mail_method"), array("EXIST_CHECK", "NUM_CHECK"));
+		$objErr->doFunc(array("¥á¡¼¥ëÁ÷¿®ÊýË¡", "mail_method"), array("EXIST_CHECK", "NUM_CHECK"));
 		
 		if(MELMAGA_BATCH_MODE) {
@@ -230,5 +230,5 @@
 		$objErr->doFunc(array("ËÜÊ¸", 'body', LLTEXT_LEN), array("EXIST_CHECK","MAX_LENGTH_CHECK"));	// HTML¥Æ¥ó¥×¥ì¡¼¥È¤ò»ÈÍÑ¤·¤Ê¤¤¾ì¹ç
 	}
-	
+
 	return $objErr->arrErr;
 }
Index: /branches/beta/html/admin/mail/index.php
===================================================================
--- /branches/beta/html/admin/mail/index.php	(revision 13628)
+++ /branches/beta/html/admin/mail/index.php	(revision 14676)
@@ -29,4 +29,6 @@
 		global $arrMailType;
 		$this->arrMailType = $arrMailType;
+		global $arrDomain;
+		$this->arrDomain = $arrDomain;
 		global $arrPageRows;
 		$this->arrPageRows = $arrPageRows;
@@ -40,4 +42,9 @@
 		global $arrCustomerType;
 		$this->arrCustomerType = $arrCustomerType;
+		global $arrDOMAIN;
+		$this->arrDomain = $arrDOMAIN;
+		$this->arrDomain[''] = "»ØÄê¤·¤Ê¤¤";
+		$this->arrDomain[1] = $arrDOMAIN[1];
+		$this->arrDomain[2] = $arrDOMAIN[2]; 
 	}
 }
@@ -75,4 +82,7 @@
 	$list_data['pref_disp'] = $objPage->arrPref[$list_data['pref']];
 	
+	//¥É¥á¥¤¥ó»ØÄê¤òÊÑ´¹
+	$list_data['domain_disp'] = $objPage->arrDomain[$list_data['domain']];
+	
 	// ÇÛ¿®·Á¼°
 	$list_data['htmlmail_disp'] = $objPage->arrHtmlmail[$list_data['htmlmail']];
@@ -134,5 +144,4 @@
 		// À¸À®¤µ¤ì¤¿WHEREÊ¸¤ò¼èÆÀ¤¹¤ë		
 		list($where, $arrval) = $objSelect->getWhere();
-	
 		// ¡ÖWHERE¡×ÉôÊ¬¤òºï½ü¤¹¤ë¡£
 		$where = ereg_replace("^WHERE", "", $where);
@@ -145,5 +154,5 @@
 		$linemax = $objQuery->count($from, $where, $arrval);
 		$objPage->tpl_linemax = $linemax;				// ²¿·ï¤¬³ºÅö¤·¤Þ¤·¤¿¡£É½¼¨ÍÑ
-		
+
 		// ¥Ú¡¼¥¸Á÷¤ê¤Î¼èÆÀ
 		$objNavi = new SC_PageNavi($_POST['search_pageno'], $linemax, SEARCH_PMAX, "fnResultPageNavi", NAVI_PMAX);
@@ -253,5 +262,7 @@
 		} else if( $_POST['mode'] == 'regist_complete' ){
 			lfRegistData($objPage->list_data);
+            //¥á¥ë¥Þ¥¬µ¡Ç½¤¬¥ª¥ó¤Ë¤Ê¤Ã¤Æ¤¤¤ë¤«¤É¤¦¤«¤ÎÈ½Äê
 			if(MELMAGA_SEND == true) {
+                //Í½ÌóÇÛ¿®¥â¡¼¥É¤ÎÊ¬´ô
 				if(MELMAGA_BATCH_MODE) {
 					header("Location: " . URL_DIR . "admin/mail/history.php");
@@ -275,4 +286,7 @@
 	$arrYear[$year] = $year;
 }
+
+$objPage->arrBlaynEngine = lfGetBlayn();
+
 $objPage->arrYear = $arrYear;
 
@@ -380,17 +394,19 @@
 	$search_data = $conn->getAll($objSelect->getListMailMagazine(lfGetIsMobile($_POST['mail_type'])), $objSelect->arrVal);
 	$dataCnt = count($search_data);
-	
 	$dtb_send_history = array();
 	
-	if(DB_TYPE == "pgsql"){
-        $dtb_send_history["send_id"] = $objQuery->nextval('dtb_send_history', 'send_id');
+    if(DB_TYPE == "pgsql"){
+	   $dtb_send_history["send_id"] = $objQuery->nextval('dtb_send_history', 'send_id');
     }
+    
     $dtb_send_history["mail_method"] = $arrData['mail_method'];
 	$dtb_send_history["subject"] = $arrData['subject'];
 	$dtb_send_history["body"] = $arrData['body'];
 	if(MELMAGA_BATCH_MODE) {
-		$dtb_send_history["start_date"] = $arrData['send_year'] ."/".$arrData['send_month']."/".$arrData['send_day']." ".$arrData['send_hour'].":".$arrData['send_minutes'];
+		//¥¤¥ó¥¹¥È¡¼¥ëÀè¤Î¥µ¡¼¥Ð¡¼¤ÇCRON¤¬Í­¸ú¤Ç¤¢¤ë¤Ê¤é»ØÄê¤µ¤ì¤¿»þ´Ö¤Ë¥á¡¼¥ë¤òÁ÷¤ë
+        $dtb_send_history["start_date"] = $arrData['send_year'] ."/".$arrData['send_month']."/".$arrData['send_day']." ".$arrData['send_hour'].":".$arrData['send_minutes'];
 	} else {
-		$dtb_send_history["start_date"] = "now()";
+		//CRON¤¬Ìµ¸ú¤Ç¤¢¤ì¤Ð¥ê¥¢¥ë¥¿¥¤¥à¤ËÁ÷¿®¤¹¤ë
+        $dtb_send_history["start_date"] = "now()";
 	}
 	$dtb_send_history["creator_id"] = $_SESSION['member_id'];
@@ -400,21 +416,23 @@
 	$dtb_send_history["update_date"] = "now()";
 	$dtb_send_history["create_date"] = "now()";
-	$objQuery->insert("dtb_send_history", $dtb_send_history );	
-	if(DB_TYPE == "mysql"){
+   
+    //¥Ï¥Ã¥·¥ådtb_send_history¤ò¥Ç¡¼¥¿¥Ù¡¼¥¹dtb_send_history¤ËÁÞÆþ
+    $objQuery->insert("dtb_send_history", $dtb_send_history );
+    if(DB_TYPE == "mysql"){
         $dtb_send_history["send_id"] = $objQuery->nextval('dtb_send_history','send_id');
     }
     
 	if ( is_array( $search_data ) ){
-		foreach( $search_data as $line ){
-			$dtb_send_customer = array();
+        foreach( $search_data as $line ){
+            
+            $dtb_send_customer = array();
 			$dtb_send_customer["customer_id"] = $line["customer_id"];
 			$dtb_send_customer["send_id"] = $dtb_send_history["send_id"];
 			$dtb_send_customer["email"] = $line["email"];
-			
-			$dtb_send_customer["name"] = $line["name01"] . " " . $line["name02"];
-				
-			$conn->autoExecute("dtb_send_customer", $dtb_send_customer );					
-		}	
-	}	
+			$dtb_send_customer["name"] = $line["name01"] . " " . $line["name02"];            
+            $conn->autoExecute("dtb_send_customer", $dtb_send_customer );					
+            
+        }	
+	}
 }
 
@@ -430,5 +448,4 @@
 		$arrCampaign[$arrVal['campaign_id']] = $arrVal['campaign_name'];
 	}
-
 	return $arrCampaign;
 }
@@ -451,3 +468,13 @@
 	return $is_mobile;
 }
+
+// ¥Ö¥ì¥¤¥ó¥¨¥ó¥¸¥ó¤¬ÀßÄêºÑ¤ß¤«³ÎÇ§
+function lfGetBlayn() {
+    
+    global $objQuery;
+    
+    $arrRet[now_version] = $objQuery->count("dtb_module", "now_version = (SELECT now_version FROM dtb_module WHERE main_php='blayn/blayn.php')");
+    $arrRet[blayn_ip] = $objQuery->count("dtb_blayn");
+    return $arrRet;
+}
 ?>
Index: /branches/beta/html/admin/total/index.php
===================================================================
--- /branches/beta/html/admin/total/index.php	(revision 13353)
+++ /branches/beta/html/admin/total/index.php	(revision 14676)
@@ -107,4 +107,5 @@
 				
 		$page = $objFormParam->getValue('page');
+        
 		switch($page) {
 		// ¾¦ÉÊÊÌ½¸·×
@@ -201,5 +202,5 @@
 default:
 	if(count($_GET) == 0) {
-		// ¥Ð¥Ã¥Á¥â¡¼¥É¤Î¾ì¹ç¤Î¤ß¼Â¹Ô¤¹¤ë
+		// ¥Ð¥Ã¥Á¥â¡¼¥É¤Î¾ì¹ç¤Î¤ß¼Â¹Ô¤¹¤ë¡ÊÅöÆü¤Î½¸·×¤ò¹Ô¤¦¤¿¤á¡Ë
 		if(DAILY_BATCH_MODE) {
 			// 3ÆüÁ°¤Þ¤Ç¤Î½¸·×
@@ -209,5 +210,4 @@
 	break;
 }
-
 
 $objPage->install_GD = $install_GD;
@@ -622,4 +622,6 @@
 function lfGetOrderProducts($type, $sdate, $edate, $objPage, $graph = true, $mode = "") {
 	list($where, $arrval) = lfGetWhereMember('create_date', $sdate, $edate, $type);
+    
+    $where .= " and del_flg=0 and status <> " . ORDER_CANCEL;
 	
     $where .= " and del_flg=0 and status <> " . ORDER_CANCEL;
@@ -659,10 +661,10 @@
 	
 	$sql = "SELECT job, count(*) AS order_count, SUM(total) AS total, (AVG(total)) AS total_average ";
-	$sql.= "FROM dtb_customer AS T1 LEFT JOIN dtb_order AS T2 USING ( customer_id ) WHERE $where AND T2.del_flg = 0 ";
-	$sql.= "GROUP BY job ORDER BY total DESC";
+	$sql.= "FROM dtb_customer AS T1 LEFT JOIN dtb_order AS T2 USING ( customer_id ) WHERE $where AND T2.del_flg = 0 and T2.status <> " . ORDER_CANCEL;
+	$sql.= " GROUP BY job ORDER BY total DESC";
 	
 	$objQuery = new SC_Query();
 	$objPage->arrResults = $objQuery->getall($sql, $arrval);
-			
+    
 	$max = count($objPage->arrResults);
 	for($i = 0; $i < $max; $i++) {
@@ -808,5 +810,5 @@
 		// ¸¡º÷·ë²Ì¤Î¼èÆÀ
 		$objPage->arrResults = $objQuery->select($col, $from, $where, $arrval);
-		
+        
 		// ÀÞ¤ìÀþ¥°¥é¥Õ¤ÎÀ¸À®	
 		if($graph) {
Index: /branches/beta/html/admin/system/module.php
===================================================================
--- /branches/beta/html/admin/system/module.php	(revision 297)
+++ /branches/beta/html/admin/system/module.php	(revision 14676)
@@ -130,5 +130,5 @@
 function lfLoadUpdateList() {
 	$objQuery = new SC_Query();
-	$path = UPDATE_HTTP . "module.txt";
+	$path = UPDATE_HTTP . MODULE_CSV;
 	$fp = @fopen($path, "rb");
 	
Index: /branches/beta/html/admin/contents/campaign_design.php
===================================================================
--- /branches/beta/html/admin/contents/campaign_design.php	(revision 17)
+++ /branches/beta/html/admin/contents/campaign_design.php	(revision 14676)
@@ -79,5 +79,12 @@
 case 'preview':
 	// ¥×¥ì¥Ó¥å¡¼¤ò½ñ¤­½Ð¤·ÊÌÁë¤Ç³«¤¯
-	sfWriteFile($arrForm['header'] . $arrForm['contents'] . $arrForm['footer'], $campaign_dir."preview.tpl", "w");
+	// ¥×¥ì¥Ó¥å¡¼¤ò½ñ¤­½Ð¤·ÊÌÁë¤Ç³«¤¯
+	$preview  = $arrForm['header']."\n";
+	$preview .= '<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/site.js"></script>'."\n";
+	$preview .= '<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/navi.js"></script>'."\n";
+	$preview .= $arrForm['contents'] . "\n";
+	$preview .= $arrForm['footer']."\n";
+	sfWriteFile($preview, $campaign_dir."preview.tpl", "w");
+	
 	$objPage->tpl_onload = "win02('./campaign_preview.php?status=". $arrForm['status'] ."&campaign_id=". $arrForm['campaign_id'] ."', 'preview', '600', '400');";
 	$objPage->header_data = $arrForm['header'];	
Index: /branches/beta/html/admin/contents/campaign_preview.php
===================================================================
--- /branches/beta/html/admin/contents/campaign_preview.php	(revision 17)
+++ /branches/beta/html/admin/contents/campaign_preview.php	(revision 14676)
@@ -38,4 +38,5 @@
 // ¥Ç¥£¥ì¥¯¥È¥êÌ¾¤ò¼èÆÀÌ¾		
 $directory_name = $objQuery->get("dtb_campaign", "directory_name", "campaign_id = ?", array($_GET['campaign_id']));
+$objPage->dir_name = $directory_name;
 
 $template_dir = CAMPAIGN_TEMPLATE_PATH . $directory_name  . "/" . $status . "preview.tpl";
Index: /branches/beta/html/admin/basis/template_input.php
===================================================================
--- /branches/beta/html/admin/basis/template_input.php	(revision 14676)
+++ /branches/beta/html/admin/basis/template_input.php	(revision 14676)
@@ -0,0 +1,112 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+require_once("../require.php");
+
+class LC_Page {
+	
+	var $arrSession;
+	var $site_info;
+	var $objDate;
+	var $arrForm;
+	var $mode;
+	var $arrMagazineType;
+	var $title;
+	
+	function LC_Page() {
+		$this->tpl_mainpage = 'basis/mail.tpl';
+		$this->tpl_mainno = 'basis';
+		$this->tpl_subnavi = 'basis/subnavi.tpl';
+		$this->tpl_subno = 'mail';
+	}
+}
+
+$conn = new SC_DBConn();
+$objPage = new LC_Page();
+$objView = new SC_AdminView();
+$objSess = new SC_Session();
+
+// Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
+sfIsSuccess($objSess);
+
+$objPage->arrSendType = array("¥Ñ¥½¥³¥ó","·ÈÂÓ");
+$objPage->mode = "regist";
+
+// id¤¬»ØÄê¤µ¤ì¤Æ¤¤¤ë¤È¤­¤Ï¡ÖÊÔ½¸¡×É½¼¨
+if ( $_REQUEST['template_id'] ){
+	$objPage->title = "ÊÔ½¸";
+} else {
+	$objPage->title = "¿·µ¬ÅÐÏ¿";
+}
+
+// ¥â¡¼¥É¤Ë¤è¤ë½èÍýÊ¬´ô
+if ( $_POST['mode'] == 'regist' ) {
+	
+	// ¿·µ¬ÅÐÏ¿
+	$objPage->arrForm = lfConvData( $_POST );
+	//print_r($objPage->arrForm);print("<br>");
+    $objPage->arrErr = lfErrorCheck($objPage->arrForm);
+	
+	if ( ! $objPage->arrErr ){
+		// ¥¨¥é¡¼¤¬Ìµ¤¤¤È¤­¤ÏÅÐÏ¿¡¦ÊÔ½¸
+		lfRegistData( $objPage->arrForm, $_POST['template_id']);	
+		//sfReload("mode=complete");	// ¼«Ê¬¤òºÆÆÉ¹þ¤·¤Æ¡¢´°Î»²èÌÌ¤ØÁ«°Ü
+	}
+} 
+
+$objView->assignobj($objPage);
+$objView->display(MAIN_FRAME);
+
+
+function lfRegistData( $arrVal, $id = null ){
+	
+	$query = new SC_Query();
+	
+    $sqlval['template_name'] = $arrVal['template_name'];
+	$sqlval['subject'] = $arrVal['subject'];
+	$sqlval['creator_id'] = $_SESSION['member_id'];
+	$sqlval['body'] = $arrVal['body'];
+	$sqlval['update_date'] = "now()";
+
+	if ( $id ){
+		$query->update("dtb_mailtemplate", $sqlval, "template_id=".$id );
+	} else {
+		$sqlval['create_date'] = "now()";
+		$query->insert("dtb_mailtemplate", $sqlval);
+	}
+}
+
+function lfConvData( $data ){
+	
+	 // Ê¸»úÎó¤ÎÊÑ´¹¡Êmb_convert_kana¤ÎÊÑ´¹¥ª¥×¥·¥ç¥ó¡Ë							
+	$arrFlag = array(
+					  "template_name" => "KV"
+                     ,"subject" => "KV"
+					 ,"body" => "KV"
+					);
+		
+	if ( is_array($data) ){
+		foreach ($arrFlag as $key=>$line) {
+			$data[$key] = mb_convert_kana($data[$key], $line);
+		}
+	}
+	return $data;
+}
+
+// ÆþÎÏ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+function lfErrorCheck($array) {
+	$objErr = new SC_CheckError($array);
+	$objErr->doFunc(array("¥á¡¼¥ë·Á¼°", "send_type"), array("EXIST_CHECK"));
+    $objErr->doFunc(array("¥Æ¥ó¥×¥ì¡¼¥È", "template_name"), array("EXIST_CHECK"));
+	$objErr->doFunc(array("Subject", "subject"), array("EXIST_CHECK"));
+	$objErr->doFunc(array("ËÜÊ¸", 'body'), array("EXIST_CHECK"));
+
+	return $objErr->arrErr;
+}
+
+
+
+?>
Index: /branches/beta/html/admin/basis/mail_template.php
===================================================================
--- /branches/beta/html/admin/basis/mail_template.php	(revision 14676)
+++ /branches/beta/html/admin/basis/mail_template.php	(revision 14676)
@@ -0,0 +1,56 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+require_once("../require.php");
+
+class LC_Page {
+    var $arrSession;
+    var $list_data;
+    var $default_template;
+    var $default_template_mobile;
+    var $arrMagazineType;
+    
+    function LC_Page() {
+        $this->tpl_mainpage = 'basis/template.tpl';
+        $this->tpl_mainno = 'basis';
+        $this->tpl_subnavi = 'basis/subnavi.tpl';
+        $this->tpl_subno = 'mail';
+        $this->tpl_subtitle = '¥Æ¥ó¥×¥ì¡¼¥ÈÀßÄê';
+    }
+}
+
+$conn = new SC_DBConn();
+$objPage = new LC_Page();
+$objView = new SC_AdminView();
+$objSess = new SC_Session();
+
+// Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
+sfIsSuccess($objSess);
+
+if ( $_GET['mode'] == "delete" && sfCheckNumLength($_GET['id'])===true ){
+    
+    // ÅÐÏ¿ºï½ü
+    $sql = "UPDATE dtb_mailtemplate SET del_flg = 1 WHERE template_id = ?";
+    $conn->query($sql, array($_GET['id']));
+    sfReload();
+}
+
+$sql = "SELECT * FROM dtb_mailtemplate WHERE del_flg = 0 ORDER BY template_id ASC";
+$list_data = $conn->getAll($sql);
+$linemax = count($list_data);
+
+for($i = 0;$i < count($list_data);$i++){
+   $split_data = explode(".",$list_data[$i]["create_date"]);
+   $list_data[$i]["create_date"] = $split_data[0];    
+}
+
+//print_r($list_data);
+$objPage->list_data = $list_data;
+$objPage->arrMagazineType = $arrMagazineTypeAll;
+
+$objView->assignobj($objPage);
+$objView->display(MAIN_FRAME);
+?>
Index: /branches/beta/html/admin/basis/preview.php
===================================================================
--- /branches/beta/html/admin/basis/preview.php	(revision 14676)
+++ /branches/beta/html/admin/basis/preview.php	(revision 14676)
@@ -0,0 +1,46 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+require_once("../require.php");
+
+class LC_Page {
+	var $arrSession;
+	var $list_data;
+
+	function LC_Page() {
+		$this->tpl_mainpage = 'basis/preview.tpl';
+	}
+}
+
+//---- ¥Ú¡¼¥¸½é´üÀßÄê
+$conn = new SC_DBConn();
+$objPage = new LC_Page();
+$objView = new SC_AdminView();
+$objSess = new SC_Session();
+$objDate = new SC_Date();
+
+// Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
+sfIsSuccess($objSess);
+
+if ( $_GET['mode']=="preview" || $_GET['id']){
+		$sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = ? AND del_flg = 0";
+		$id = $_GET['id'];
+        $result = $conn->getAll($sql, array($id));
+        print($result[0]["header"]);
+        if ( $result ){
+            if ( $result[0]["mail_method"] == 2 ){
+            // ¥Æ¥­¥¹¥È·Á¼°¤Î»þ¤Ï¥¿¥°Ê¸»ú¤ò¥¨¥¹¥±¡¼¥×
+                $objPage->escape_flag = 1;
+            }
+            $objPage->list_data = $result[0];    
+        }
+    
+    }
+
+$objView->assignobj($objPage);
+$objView->display($objPage->tpl_mainpage);
+
+?>
Index: /branches/beta/html/admin/basis/mail.php
===================================================================
--- /branches/beta/html/admin/basis/mail.php	(revision 17)
+++ /branches/beta/html/admin/basis/mail.php	(revision 14676)
@@ -20,45 +20,39 @@
 
 $conn = new SC_DBConn();
+$objQuery = new SC_Query();
 $objPage = new LC_Page();
 $objView = new SC_AdminView();
 $objSess = new SC_Session();
 
-// Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
+//Ç§¾Ú²ÄÈÝ¤ÎÈ½Äê
 sfIsSuccess($objSess);
 
 $objPage->arrMailTEMPLATE = $arrMAILTEMPLATE;
 
-if ( $_POST['mode'] == 'id_set'){
-	// ¥Æ¥ó¥×¥ì¡¼¥È¥×¥ë¥À¥¦¥óÊÑ¹¹»þ
-	
-	if ( sfCheckNumLength( $_POST['template_id']) ){
+$objPage->arrSendType = array("¥Ñ¥½¥³¥ó","·ÈÂÓ");
+
+if ( $_GET['mode'] == 'edit' && sfCheckNumLength($_GET['template_id']) === true ){
+	if ( sfCheckNumLength( $_GET['template_id']) ){
 		$sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = ?";
-		$result = $conn->getAll($sql, array($_POST['template_id']) );
+		$result = $conn->getAll($sql, array($_GET['template_id']) );
 		if ( $result ){
 			$objPage->arrForm = $result[0];
 		} else {
-			$objPage->arrForm['template_id'] = $_POST['template_id'];
+			$objPage->arrForm['template_id'] = $_GET['template_id'];
 		}
 	}
-	
 } elseif ( $_POST['mode'] == 'regist' && sfCheckNumLength( $_POST['template_id']) ){
-
 	// POST¥Ç¡¼¥¿¤Î°ú¤­·Ñ¤®
 	$objPage->arrForm = lfConvertParam($_POST);
 	$objPage->arrErr = fnErrorCheck($objPage->arrForm);
-	
 	if ( $objPage->arrErr ){
 		// ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸
 		$objPage->tpl_msg = "¥¨¥é¡¼¤¬È¯À¸¤·¤Þ¤·¤¿";
-		
 	} else {
 		// Àµ¾ï
 		lfRegist($conn, $objPage->arrForm);
-		
 		// ´°Î»¥á¥Ã¥»¡¼¥¸
-		$objPage->tpl_onload = "window.alert('¥á¡¼¥ëÀßÄê¤¬´°Î»¤·¤Þ¤·¤¿¡£¥Æ¥ó¥×¥ì¡¼¥È¤òÁªÂò¤·¤ÆÆâÍÆ¤ò¤´³ÎÇ§¤¯¤À¤µ¤¤¡£');";
-		unset($objPage->arrForm);
+		$objPage->tpl_onload = "window.alert('¥á¡¼¥ëÀßÄê¤¬´°Î»¤·¤Þ¤·¤¿¡£');";
 	}
-
 }
 
@@ -72,22 +66,22 @@
 	$data['creator_id'] = $_SESSION['member_id'];
 	
-	$sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = ?";
+	$sql = "SELECT * FROM dtb_mailtemplate WHERE template_id = ? AND del_flg = 0";
 	$result = $conn->getAll($sql, array($_POST['template_id']) );
 	if ( $result ){
 		$sql_where = "template_id = ". addslashes($_POST['template_id']);
-		$conn->query("UPDATE dtb_mailtemplate SET template_id = ?, subject = ?,header = ?, footer = ?,creator_id = ?, update_date = now() WHERE ".$sql_where, $data);
+		$conn->query("UPDATE dtb_mailtemplate SET send_type = ?,template_id = ?, template_name = ?,subject = ?,body = ?,creator_id = ?, update_date = now() WHERE ".$sql_where, $data);
 	}else{
-		$conn->query("INSERT INTO dtb_mailtemplate (template_id,subject,header,footer,creator_id,update_date,create_date) values ( ?,?,?,?,?,now(),now() )", $data);
+		$conn->query("INSERT INTO dtb_mailtemplate (send_type,template_id,template_name,subject,body,creator_id,update_date,create_date) values ( ?,?,?,?,?,?,now(),now() )", $data);
 	}
 
 }
 
-
 function lfConvertParam($array) {
 	
+    $new_array["send_type"] = $array["send_type"];
 	$new_array["template_id"] = $array["template_id"];
+    $new_array["template_name"] = mb_convert_kana($array["template_name"],"KV");
 	$new_array["subject"] = mb_convert_kana($array["subject"] ,"KV");
-	$new_array["header"] = mb_convert_kana($array["header"] ,"KV");
-	$new_array["footer"] = mb_convert_kana($array["footer"] ,"KV");
+	$new_array["body"] = mb_convert_kana($array["body"] ,"KV");
 	
 	return $new_array;
@@ -98,9 +92,9 @@
 	
 	$objErr = new SC_CheckError($array);
-	
+	$objErr->doFunc(array("¥á¡¼¥ë¤Î¼ïÎà",'send_type'), array("EXIST_CHECK"));
 	$objErr->doFunc(array("¥Æ¥ó¥×¥ì¡¼¥È",'template_id'), array("EXIST_CHECK"));
+    $objErr->doFunc(array("¥Æ¥ó¥×¥ì¡¼¥È",'template_name'), array("EXIST_CHECK"));
 	$objErr->doFunc(array("¥á¡¼¥ë¥¿¥¤¥È¥ë",'subject',MTEXT_LEN,"BIG"), array("EXIST_CHECK", "MAX_LENGTH_CHECK"));
-	$objErr->doFunc(array("¥Ø¥Ã¥À¡¼",'header',LTEXT_LEN,"BIG"), array("MAX_LENGTH_CHECK"));
-	$objErr->doFunc(array("¥Õ¥Ã¥¿¡¼",'footer',LTEXT_LEN,"BIG"), array("MAX_LENGTH_CHECK"));
+	$objErr->doFunc(array("¥á¡¼¥ë¤ÎÆâÍÆ",'body',LTEXT_LEN,"BIG"), array("MAX_LENGTH_CHECK","EXIST_CHECK"));
 
 	return $objErr->arrErr;
Index: /branches/beta/html/admin/require.php
===================================================================
--- /branches/beta/html/admin/require.php	(revision 12184)
+++ /branches/beta/html/admin/require.php	(revision 14676)
@@ -28,4 +28,10 @@
 require_once($include_dir . "/.." . HTML2DATA_DIR . "class/SC_Customer.php");
 require_once($include_dir . "/.." . HTML2DATA_DIR . "class/SC_Pdf.php");
+require_once($include_dir . "/.." . HTML2DATA_DIR . "module/PEAR.php");
+require_once($include_dir . "/.." . HTML2DATA_DIR . "module/Mail/mimeDecode.php");
+require_once($include_dir . "/.." . HTML2DATA_DIR . "module/Mail/Mail.php");
+require_once($include_dir . "/.." . HTML2DATA_DIR . "module/Mail/mime.php");
+require_once($include_dir . "/.." . HTML2DATA_DIR . "module/Mail/mimePart.php");
+
 // ¥¢¥Ã¥×¥Ç¡¼¥È¤Ç¼èÆÀ¤·¤¿PHP¤òÆÉ¤ß½Ð¤¹
 sfLoadUpdateModule();
Index: /branches/beta/data/Smarty/templates/shopping/confirm.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/shopping/confirm.tpl	(revision 11551)
+++ /branches/beta/data/Smarty/templates/shopping/confirm.tpl	(revision 14676)
@@ -46,5 +46,5 @@
 						<td align="center">
 							<a href="<!--{$smarty.server.PHP_SELF|escape}-->" onclick="win01('../products/detail_image.php?product_id=<!--{$arrProductsClass[cnt].product_id}-->&image=main_image','detail_image','<!--{$arrProductsClass[cnt].tpl_image_width}-->','<!--{$arrProductsClass[cnt].tpl_image_height}-->'); return false;" target="_blank">
-								<img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$smarty.const.IMAGE_SAVE_DIR}-->/<!--{$arrProductsClass[cnt].main_list_image}-->&width=65&height=65" alt="<!--{$arrProductsClass[cnt].name|escape}-->">
+								<img src="<!--{$smarty.const.URL_DIR}-->resize_image.php?image=<!--{$smarty.const.IMAGE_SAVE_DIR}-->/<!--{$arrProductsClass[cnt].main_list_image}-->&width=65&height=65" alt="<!--{$arrProductsClass[cnt].name|escape}-->">
 							</a>
 						</td>
Index: /branches/beta/data/Smarty/templates/shopping/nonmember_input.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/shopping/nonmember_input.tpl	(revision 11577)
+++ /branches/beta/data/Smarty/templates/shopping/nonmember_input.tpl	(revision 14676)
@@ -63,7 +63,7 @@
 									<span class="fs12n"><span class="red"><!--{$arrErr[$key1]}--><!--{$arrErr[$key2]}--></span></span>
 									¢©
-									<input type="text" name="<!--{$key1}-->" value="<!--{$arrForm[$key1].value|escape}-->" maxlength="<!--{$arrForm[$key1].length}-->" style="<!--{$arrErr[$key1]|sfGetErrorColor}-->"  size="6" />
+									<input type="text" name="<!--{$key1}-->" value="<!--{$arrForm[$key1].value|escape}-->" maxlength="<!--{$arrForm[$key1].length}-->" style="<!--{$arrErr[$key1]|sfGetErrorColor}-->"  size="6" onblur="fnSendZipcode()"/>
 									 - 
-									<input type="text"  name="<!--{$key2}-->" value="<!--{$arrForm[$key2].value|escape}-->" maxlength="<!--{$arrForm[$key2].length}-->" style="<!--{$arrErr[$key2]|sfGetErrorColor}-->"  size="6" />¡¡
+									<input type="text"  name="<!--{$key2}-->" value="<!--{$arrForm[$key2].value|escape}-->" maxlength="<!--{$arrForm[$key2].length}-->" style="<!--{$arrErr[$key2]|sfGetErrorColor}-->"  size="6" onblur="fnSendZipcode()"/>¡¡
 									<a href="http://search.post.japanpost.jp/7zip/" target="_blank"><span class="fs10">Í¹ÊØÈÖ¹æ¸¡º÷</span></a>
 								</td>
Index: /branches/beta/data/Smarty/templates/admin/mail/input.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/mail/input.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/mail/input.tpl	(revision 14676)
@@ -34,16 +34,17 @@
 								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+										<!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--><!--{assign var=key value="4"}--><!--{else}--><!--{assign var=key value="3"}--><!--{/if}-->
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
 									</tr>
 									<tr>
 										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
-										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÀßÄê¡§ÇÛ¿®ÆâÍÆÀßÄê</span></td>
+										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÀßÄê¡§ÇÛ¿®ÆâÍÆÀßÄê</span><!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--></td><td align="right"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/blayn_icon.jpg"><!--{/if}--></td>
 										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
 									</tr>
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
 									</tr>
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
 									</tr>
 								</table>
Index: /branches/beta/data/Smarty/templates/admin/mail/query.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/mail/query.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/mail/query.tpl	(revision 14676)
@@ -112,9 +112,20 @@
 											<td bgcolor="#ffffff" width="507" colspan="3"><!--{$list_data.email|escape|default:"¡ÊÌ¤»ØÄê¡Ë"}--></td>
 										</tr>
-										<tr class="fs12n">
+										
+										<tr class="fs12n">
+											<td bgcolor="#f0f0f0" width="110">·ÈÂÓ¥á¡¼¥ë¥¢¥É¥ì¥¹</td>
+											<td bgcolor="#ffffff" width="507" colspan="3"><!--{$list_data.email_mobile|escape|default:"¡ÊÌ¤»ØÄê¡Ë"}--></td>
+										</tr>
+										
+										<tr class="fs12n">
+											<td bgcolor="#f0f0f0" width="110">¥É¥á¥¤¥ó»ØÄê</td>
+											<td bgcolor="#ffffff" width="507" colspan="3"><!--{$list_data.domain_disp|escape|default:"¡ÊÌ¤»ØÄê¡Ë"}--></td>
+										</tr>
+							            
+							            <tr class="fs12n">
 											<td bgcolor="#f0f0f0" width="110">¿¦¶È</td>
 											<td bgcolor="#ffffff" width="507" colspan="3"><!--{$list_data.job_disp|escape|default:"¡ÊÌ¤»ØÄê¡Ë"}--></td>
 										</tr>
-							
+										
 										<tr class="fs12n">
 											<td bgcolor="#f0f0f0" width="110">À¸Ç¯·îÆü</td>
Index: /branches/beta/data/Smarty/templates/admin/mail/index.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/mail/index.tpl	(revision 11771)
+++ /branches/beta/data/Smarty/templates/admin/mail/index.tpl	(revision 14676)
@@ -26,20 +26,21 @@
 					</tr>
 					<tr>
+						<!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--><!--{assign var=key value="4"}--><!--{else}--><!--{assign var=key value="3"}--><!--{/if}-->
 						<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
 						<td bgcolor="#cccccc">
 						<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
 							<tr>
-								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+								<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
 							</tr>
 							<tr>
 								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
-								<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®Àè¸¡º÷¾ò·ïÀßÄê</span></td>
+								<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®Àè¸¡º÷¾ò·ïÀßÄê</span><!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--></td><td align="right"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/blayn_icon.jpg"><!--{/if}--></td>
 								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
 							</tr>
 							<tr>
-								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
-							</tr>
-							<tr>
-								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+								<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+							</tr>
+							<tr>
+								<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
 							</tr>
 						</table>
@@ -93,5 +94,5 @@
 								<td bgcolor="#ffffff" width="194">
 									<!--{if $arrErr.htmlmail}--><span class="red12"><!--{$arrErr.htmlmail}--></span><br /><!--{/if}-->
-									<!--{html_radios name="htmlmail" options=$arrHtmlmail separator="&nbsp;" selected=$list_data.htmlmail}-->
+									<!--{html_radios name="htmlmail" options=$arrHtmlmail separator="&nbsp;" selected=$htmlmail}-->
 								</td>
 								<td bgcolor="#f2f1ec" width="110">¹ØÆþ²ó¿ô</td>
@@ -146,9 +147,16 @@
 								</td>
 							</tr>
-
+                            <!--{* ¤¤¤Ã¤¿¤ó¡¢Ää»ß¤È¤·¤Þ¤¹¡¡2007/05/28 
 							<tr class="fs12n">
 								<td bgcolor="#f2f1ec" width="110">ÇÛ¿®¥á¡¼¥ë¥¢¥É¥ì¥¹¼ïÊÌ</td>
 								<td bgcolor="#ffffff" colspan="3">
 									<!--{html_radios name="mail_type" options=$arrMailType separator="&nbsp;" selected=$list_data.mail_type}-->
+								</td>
+							</tr>
+							*}-->
+							<tr class="fs12n">
+								<td bgcolor="#f2f1ec" width="110">¥É¥á¥¤¥ó»ØÄê</td>
+								<td bgcolor="#ffffff" colspan="3">
+									<!--{html_radios name="domain" options=$arrDomain separator="&nbsp;" selected=$list_data.domain}-->
 								</td>
 							</tr>
Index: /branches/beta/data/Smarty/templates/admin/mail/input_complete.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/mail/input_complete.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/mail/input_complete.tpl	(revision 14676)
@@ -34,16 +34,17 @@
 								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+										<!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--><!--{assign var=key value="4"}--><!--{else}--><!--{assign var=key value="3"}--><!--{/if}-->
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
 									</tr>
 									<tr>
 										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
-										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÀßÄê¡§ÇÛ¿®ÆâÍÆÀßÄê</span></td>
+										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÀßÄê¡§ÇÛ¿®ÆâÍÆÀßÄê</span><!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--></td><td align="right"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/blayn_icon.jpg"><!--{/if}--></td>
 										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
 									</tr>
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
 									</tr>
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
 									</tr>
 								</table>
Index: /branches/beta/data/Smarty/templates/admin/mail/input_confirm.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/mail/input_confirm.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/mail/input_confirm.tpl	(revision 14676)
@@ -34,16 +34,17 @@
 								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+										<!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--><!--{assign var=key value="4"}--><!--{else}--><!--{assign var=key value="3"}--><!--{/if}-->
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
 									</tr>
 									<tr>
 										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
-										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÀßÄê¡§ÇÛ¿®ÆâÍÆÀßÄê</span></td>
+										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÀßÄê¡§ÇÛ¿®ÆâÍÆÀßÄê</span><!--{if $arrBlaynEngine.now_version > 0 && $arrBlaynEngine.blayn_ip > 0}--></td><td align="right"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/blayn_icon.jpg"><!--{/if}--></td>
 										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
 									</tr>
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
 									</tr>
 									<tr>
-										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+										<td colspan="<!--{$key}-->"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
 									</tr>
 								</table>
Index: /branches/beta/data/Smarty/templates/admin/basis/template_complete.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/template_complete.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/admin/basis/template_complete.tpl	(revision 14676)
@@ -0,0 +1,58 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+<table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
+<form name="form1" id="form1" method="post" action="./product_class.php">
+<input type="hidden" name="mode" value="">
+<input type="hidden" name="product_id" value="">
+	<tr valign="top">
+		<td background="<!--{$smarty.const.URL_DIR}-->img/contents/navi_bg.gif" height="402">
+			<!-- ¥µ¥Ö¥Ê¥Ó -->
+			<!--{include file=$tpl_subnavi}-->
+		</td>
+		<td class="mainbg" >
+		<table width="737" border="0" cellspacing="0" cellpadding="0" summary=" ">
+			<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+			<tr>
+				<td align="center">
+				<table width="706" border="0" cellspacing="0" cellpadding="0" summary=" ">
+
+					<tr><td height="14"></td></tr>
+					<tr>
+						<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_top.jpg" width="706" height="14" alt=""></td>
+					</tr>
+					<tr>
+						<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+						<td bgcolor="#f2f1ec">
+						<!--´°Î»¥á¥Ã¥»¡¼¥¸¥Æ¡¼¥Ö¥ë¤³¤³¤«¤é-->
+						<table width="678" border="0" cellspacing="1" cellpadding="8" summary=" " height="402">
+							<tr class="fs12n" height="400">
+								<td bgcolor="#ffffff" align="center">¥Æ¥ó¥×¥ì¡¼¥È¤ÎÅÐÏ¿¡¦ÊÔ½¸¤¬´°Î»¤·¤Þ¤·¤¿
+								<br/><br/><a href="./template.php">¥Æ¥ó¥×¥ì¡¼¥È°ìÍ÷¤ËÌá¤ë</a></td>								
+							</tr>
+						</table>
+						<!--´°Î»¥á¥Ã¥»¡¼¥¸¥Æ¡¼¥Ö¥ë¤³¤³¤Þ¤Ç-->
+						</td>
+						<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_right.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+					</tr>
+					<tr>
+						<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bottom.jpg" width="706" height="14" alt=""></td>
+					</tr>
+					<tr><td height="30"></td></tr>
+
+				</table>
+				</td>
+			</tr>
+			<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+		</table>
+		</td>
+	</tr>
+</form>
+</table>
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->		
+
Index: /branches/beta/data/Smarty/templates/admin/basis/subnavi.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/subnavi.tpl	(revision 11923)
+++ /branches/beta/data/Smarty/templates/admin/basis/subnavi.tpl	(revision 14676)
@@ -18,5 +18,5 @@
 	<tr><td class=<!--{if $tpl_subno != 'point'}-->"navi"<!--{else}-->"navi-on"<!--{/if}-->><a href="./point.php" onMouseOver="naviStyleChange('point', '#a5a5a5')" <!--{if $tpl_subno != 'point'}-->onMouseOut="naviStyleChange('point', '#636469')"<!--{/if}--> id="point"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/icon.jpg" width="15" height="9" alt="" border="0"><span class="navi_text">¥Ý¥¤¥ó¥ÈÀßÄê</span></a></td></tr>
 	<tr><td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/navi_line.gif" width="140" height="2" alt=""></td></tr>
-	<tr><td class=<!--{if $tpl_subno != 'mail'}-->"navi"<!--{else}-->"navi-on"<!--{/if}-->><a href="./mail.php" onMouseOver="naviStyleChange('mail_id', '#a5a5a5')" <!--{if $tpl_subno != 'mail'}-->onMouseOut="naviStyleChange('mail_id', '#636469')"<!--{/if}--> id="mail_id"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/icon.jpg" width="15" height="9" alt="" border="0"><span class="navi_text">¥á¡¼¥ëÀßÄê</span></a></td></tr>
+	<tr><td class=<!--{if $tpl_subno != 'mail'}-->"navi"<!--{else}-->"navi-on"<!--{/if}-->><a href="./mail_template.php" onMouseOver="naviStyleChange('mail_id', '#a5a5a5')" <!--{if $tpl_subno != 'mail'}-->onMouseOut="naviStyleChange('mail_id', '#636469')"<!--{/if}--> id="mail_id"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/icon.jpg" width="15" height="9" alt="" border="0"><span class="navi_text">¥á¡¼¥ëÀßÄê</span></a></td></tr>
 	<tr><td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/navi_line.gif" width="140" height="2" alt=""></td></tr>
 	<tr><td class=<!--{if $tpl_subno != 'seo'}-->"navi"<!--{else}-->"navi-on"<!--{/if}-->><a href="./seo.php" onMouseOver="naviStyleChange('seo', '#a5a5a5')" <!--{if $tpl_subno != 'seo'}-->onMouseOut="naviStyleChange('seo', '#636469')"<!--{/if}--> id="seo"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/icon.jpg" width="15" height="9" alt="" border="0"><span class="navi_text">SEO´ÉÍý</span></a></td></tr>
Index: /branches/beta/data/Smarty/templates/admin/basis/template.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/template.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/admin/basis/template.tpl	(revision 14676)
@@ -0,0 +1,117 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+<table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
+<form name="form1" id="form1" method="post" action="">
+	<tr valign="top">
+		<td background="<!--{$smarty.const.URL_DIR}-->img/contents/navi_bg.gif" height="402">
+			<!--¢§SUB NAVI-->
+			<!--{include file=$tpl_subnavi}-->
+			<!--¢¥SUB NAVI-->
+		</td>
+		<td class="mainbg">
+			<!--¢§ÅÐÏ¿¥Æ¡¼¥Ö¥ë¤³¤³¤«¤é-->
+			<table width="737" border="0" cellspacing="0" cellpadding="0" summary=" ">
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+				<tr>
+					<td align="center">
+						<table width="706" border="0" cellspacing="0" cellpadding="0" summary=" ">
+							<tr><td height="14"></td></tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_top.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+								<td bgcolor="#cccccc">
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
+										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È°ìÍ÷</span></td>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+									</tr>
+								</table>
+
+								<table width="678" border="0" cellspacing="1" cellpadding="8" summary=" ">
+									<tr bgcolor="#f2f1ec" align="center" class="fs12n">
+										<td width="120">ºîÀ®Æü</td>
+										<td width="333">¥Æ¥ó¥×¥ì¡¼¥ÈÌ¾</td>
+										<td width="70">¥á¡¼¥ë·Á¼°</td>
+										<td width="40">ÊÔ½¸</td>
+										<td width="40">ºï½ü</td>
+										<td width="70">¥×¥ì¥Ó¥å¡¼</td>
+									</tr>
+									<!--{section name=data loop=$list_data}-->
+									<tr bgcolor="#ffffff" class="fs12n">
+										<td width="120" align="center"><!--{$list_data[data].create_date|escape}--></td>
+										<td width="333"><!--{$list_data[data].template_name|escape}--></td>
+										<!--{assign var=type value=$list_data[data].mail_method|escape}-->
+										<td width="70" align="center"><!--{if $list_data[data].send_type eq 0}-->¥Ñ¥½¥³¥ó<!--{else}-->·ÈÂÓ<!--{/if}--></td>
+										<td width="40" align="center"><a href="./mail.php?mode=edit&template_id=<!--{$list_data[data].template_id}-->">ÊÔ½¸</a></td>
+										<td width="40" align="center">
+										<!--{if $list_data[data].template_id > 1}-->
+										<a href="" onclick="fnDelete('<!--{$smarty.server.PHP_SELF|escape}-->?mode=delete&id=<!--{$list_data[data].template_id}-->'); return false;">ºï½ü</a>
+										<!--{else}-->(¸ÇÄê)<!--{/if}-->
+										</td>
+										<td width="70" align="center"><!--{if $list_data[data].send_type eq 0}--><a href="" onclick="win03('./preview.php?mode=preview&id=<!--{$list_data[data].template_id}-->','preview','750','550'); return false;" target="_blank"><!--{else}--><a href="" onclick="win03('./preview.php?id=<!--{$list_data[data].template_id}-->','preview','650','700'); return false;" target="_blank"><!--{/if}-->¥×¥ì¥Ó¥å¡¼</a></td>
+									</tr>
+									<!--{/section}-->
+								</table>
+
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+										<td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_top.gif" width="676" height="7" alt=""></td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+									</tr>
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+										<td bgcolor="#e9e7de" align="center">
+										<table border="0" cellspacing="0" cellpadding="0" summary=" ">
+											<tr>
+												<td>
+													<input type="button" name="subm" onclick="location.href='./template_input.php'" value="¿·µ¬ºîÀ®" />¡¡
+													<!-- £È£Ô£Í£ÌºîÀ®¥¦¥£¥¶¡¼¥É¤ÏÊÝÎ± ¡Ê¼¡´ü³«È¯¡Ë
+													<input type="button" name="subm" onclick="location.href='./htmlmail.php'" value="HTML¥Æ¥ó¥×¥ì¡¼¥ÈºîÀ®¥¦¥£¥¶¡¼¥É" />
+													-->
+												</td>
+											</tr>
+										</table>
+										</td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_bottom.gif" width="678" height="8" alt=""></td>
+									</tr>
+								</table>
+								</td>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_right.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+							</tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bottom.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr><td height="30"></td></tr>
+						</table>
+					</td>
+				</tr>
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+			</table>
+			<!--¢¥ÅÐÏ¿¥Æ¡¼¥Ö¥ë¤³¤³¤Þ¤Ç-->
+		</td>
+	</tr>
+</table>
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+
Index: /branches/beta/data/Smarty/templates/admin/basis/mail_list.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/mail_list.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/admin/basis/mail_list.tpl	(revision 14676)
@@ -0,0 +1,136 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+<table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
+<form name="form1" id="form1" method="post" action="./index.php">
+<input type="text" name="mode" value="<!--{$tpl_mode}-->">
+	<tr valign="top">
+		<td background="<!--{$smarty.const.URL_DIR}-->img/contents/navi_bg.gif" height="402">
+			<!--¢§SUB NAVI-->
+			<!--{include file=$tpl_subnavi}-->
+			<!--¢¥SUB NAVI-->
+		</td>
+		<td class="mainbg">
+			<!--¢§ÅÐÏ¿¥Æ¡¼¥Ö¥ë¤³¤³¤«¤é-->
+			<table width="737" border="0" cellspacing="0" cellpadding="0" summary=" ">
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+				<tr>
+					<td align="center">
+						<table width="706" border="0" cellspacing="0" cellpadding="0" summary=" ">
+							<tr><td height="14"></td></tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_top.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+								<td bgcolor="#cccccc">
+								<table width="680" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
+										<td bgcolor="#636469" width="680" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È°ìÍ÷</span></td>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+									</tr>
+								</table>
+
+<!--¢§¥ê¥¹¥ÈÉ½¼¨ÉôÊ¬-->
+<table width="680" border="0" cellspacing="0" cellpadding="0" summary=" ">
+	<tr>
+		<td bgcolor="#f0f0f0" align="center">
+
+		<!--{if count($search_data) > 0}-->		
+
+			<table width="680" border="0" cellspacing="0" cellpadding="0" summary=" ">
+				<tr><td height="12"></td></tr>
+				<tr>
+					<td bgcolor="#cccccc">
+					<!--¸¡º÷·ë²ÌÉ½¼¨¥Æ¡¼¥Ö¥ë-->
+					<table width="680" border="0" cellspacing="1" cellpadding="5" summary=" ">
+						<tr bgcolor="#636469" align="center" class="fs12n">
+							<td width="220"><span class="white">ÆüÉÕ</span></td>
+							<td width="220"><span class="white">¥¿¥¤¥È¥ë</span></td>
+							<td width="60"><span class="white">¥Æ¥ó¥×¥ì¡¼¥È¤Î¼ïÎà</span></td>
+							<td width="60" "><span class="white">ÊÔ½¸</span></td>
+							<td width="60"><span class="white">ºï½ü</span></td>
+							<td width="60" ><span class="white">¥×¥ì¥Ó¥å¡¼</span></td>
+						</tr>
+						<!--{section name=data loop=$mail_list}-->
+							<!--¸ÜµÒ<!--{$smarty.section.data.iteration}-->-->
+							<tr bgcolor="#ffffff" class="fs12n">
+								<td align="center" ><!--{$mail_list[data].create_date|escape}--></td>
+								<td align="center" ><!--{$mail_list[data].template_name|escape}--></td>					
+								<td><!--{if $mail_list[data].send_type eq 0}-->¥Ñ¥½¥³¥ó<!--{else}-->·ÈÂÓ<!--{/if}--></td>
+								<td align="center" ><span class="icon_edit"><a href="#" onclick="return fnEdit('<!--{$mail_list[data].template_code|escape}-->');">ÊÔ½¸</a></span></td>
+								<td align="center" ><span class="icon_delete"><a href="#" onclick="return fnDelete('<!--{$mail_list[data].template_code|escape}-->');">ºï½ü</a></span></td>
+								<td align="center" ><span class="icon_delete"><a href="#" onclick="return fnDelete('<!--{$mail_list[data].template_code|escape}-->');">ºï½ü</a></span></td>
+							</tr>
+							<!--¸ÜµÒ<!--{$smarty.section.data.iteration}-->-->
+						<!--{/section}-->
+					</table>
+					<!--¸¡º÷·ë²ÌÉ½¼¨¥Æ¡¼¥Ö¥ë-->
+					</td>
+				</tr>
+			</table>
+
+		<!--{/if}-->
+
+		</td>
+	</tr>
+</form>
+</table>	
+
+<!--¢¥¥ê¥¹¥ÈÉ½¼¨ÉôÊ¬-->
+
+
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+										<td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_top.gif" width="676" height="7" alt=""></td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+									</tr>
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+										<td bgcolor="#e9e7de" align="center">
+										<table border="0" cellspacing="0" cellpadding="0" summary=" ">
+											<tr>
+												<td><input type="image" onMouseover="chgImgImageSubmit('<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist_on.jpg',this)" onMouseout="chgImgImageSubmit('<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist.jpg',this)" src="<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist.jpg" width="123" height="24" alt="¤³¤ÎÆâÍÆ¤ÇÅÐÏ¿¤¹¤ë" border="0" name="subm" ></td>
+											</tr>
+										</table>
+										</td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_bottom.gif" width="678" height="8" alt=""></td>
+									</tr>
+								</table>
+								</td>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_right.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+							</tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bottom.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr><td height="30"></td></tr>
+						</table>
+					</td>
+				</tr>
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+			</table>
+			<!--¢¥ÅÐÏ¿¥Æ¡¼¥Ö¥ë¤³¤³¤Þ¤Ç-->
+		</td>
+	</tr>
+</form>
+</table>
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
Index: /branches/beta/data/Smarty/templates/admin/basis/preview.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/preview.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/admin/basis/preview.tpl	(revision 14676)
@@ -0,0 +1,127 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<!--¡¡-->
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja">
+
+<head>
+<meta http-equiv="content-type" content="application/xhtml+xml; charset=<!--{$smarty.const.CHAR_CODE}-->" />
+<meta http-equiv="content-script-type" content="text/javascript" />
+<meta http-equiv="content-style-type" content="text/css" />
+<link rel="stylesheet" href="<!--{$smarty.const.URL_DIR}-->admin/css/contents.css" type="text/css" media="all" />
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/css.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/navi.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/win_op.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/site.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/admin.js"></script>
+<!--{include file='css/contents.tpl'}-->
+<title><!--{$tpl_subtitle}--></title>
+<script type="text/javascript">
+<!--
+self.moveTo(20,20);self.focus();
+//-->
+</script>
+</head>
+
+<body bgcolor="#ffffff" text="#666666" link="#007bb7" vlink="#007bb7" alink="#cc0000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" onload="<!--{$tpl_onload}-->">
+<noscript>
+<link rel="stylesheet" href="<!--{$smarty.const.URL_DIR}-->admin/css/common.css" type="text/css" />
+</noscript>
+
+<div align="center">
+
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+			<table width="737" border="0" cellspacing="0" cellpadding="0" summary=" ">
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+				<tr>
+					<td align="center">
+						<table width="706" border="0" cellspacing="0" cellpadding="0" summary=" ">
+							<tr><td height="14"></td></tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_top.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+								<td bgcolor="#cccccc">
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
+										<td bgcolor="#636469" width="638" class="fs14n"><span style="color:#ffffff;"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È¥×¥ì¥Ó¥å¡¼</span></td>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+									</tr>
+								</table>
+
+								<table width="678" border="0" cellspacing="1" cellpadding="8" summary=" ">
+									<tr class="fs12n">
+										<td bgcolor="#f2f1ec">¥á¡¼¥ë·Á¼°<span class="red"> *</span></td>
+										<td bgcolor="#ffffff">
+										<!--{if $list_data.send_type eq 0}-->¥Ñ¥½¥³¥ó<!--{else}-->·ÈÂÓ<!--{/if}-->
+										</td>
+									</tr>
+									<tr>
+										<td bgcolor="#f2f1ec" width="160" class="fs12n">¥Æ¥ó¥×¥ì¡¼¥È<span class="red"> *</span></td>
+										<td bgcolor="#ffffff" width="557" class="fs10n">
+										<!--{$list_data.template_name|escape}-->
+										</td>
+									</tr>
+									<tr>
+										<td bgcolor="#f2f1ec" width="160" class="fs12n">¥á¡¼¥ë¥¿¥¤¥È¥ë<span class="red"> *</span></td>
+										<td bgcolor="#ffffff" width="557" class="fs10n">
+										<!--{$list_data.subject|escape}-->
+										</td>
+									</tr>
+									<tr>
+										<td bgcolor="#f2f1ec" width="160" class="fs12">¥á¡¼¥ë¤ÎÆâÍÆ</td>
+										<td bgcolor="#ffffff" width="557" class="fs10">
+										<textarea  name="body" maxlength="<!--{$arrForm[$key].length}-->" style="color:#000000;background-color:#ffffff;border-width:0px;" cols="55" rows="12" class="area75" disabled="true"><!--{$list_data.body|escape}--></textarea></td>
+									</tr>						
+								</table>
+
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+										<td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_top.gif" width="676" height="7" alt=""></td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+									</tr>
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+										<td bgcolor="#e9e7de" align="center">
+										</td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_bottom.gif" width="678" height="8" alt=""></td>
+									</tr>
+								</table>
+								</td>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_right.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+							</tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bottom.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr><td height="30"></td></tr>
+						</table>
+					</td>
+				</tr>
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+			</table>
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+</div>
+
+</body>
+</html>
+
Index: /branches/beta/data/Smarty/templates/admin/basis/mail.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/mail.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/basis/mail.tpl	(revision 14676)
@@ -13,16 +13,47 @@
 	flag = 1;
 }
+
 function checkFlagAndSubmit(){
 	if ( flag == 1 ){
 		if( confirm('ÆâÍÆ¤¬ÊÑ¹¹¤µ¤ì¤Æ¤¤¤Þ¤¹¡£Â³¹Ô¤¹¤ì¤ÐÊÑ¹¹ÆâÍÆ¤ÏÇË´þ¤µ¤ì¤Þ¤¹¡£\nµ¹¤·¤¤¤Ç¤·¤ç¤¦¤«¡©' )){
-			fnSetvalAndSubmit( 'form1', 'mode', 'id_set' );
+			fnSetvalAndSubmit( 'form1', 'mode', 'edit' );
 		} else {
 			return false;
 		}
 	} else {
-		fnSetvalAndSubmit( 'form1', 'mode', 'id_set' );
+		fnSetvalAndSubmit( 'form1', 'mode', 'edit' );
 	}
 }
 
+function lfnCheckSubmit(){
+	
+	fm = document.form1;
+	var err = '';
+	
+	if ( ! fm["send_type"][0].checked && ! fm["send_type"][1].checked ){
+		err += '¥á¡¼¥ë¤Î·Á¼°¤òÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£';
+	}
+	if ( ! fm["subject"].value ){
+		err += 'Subject¤òÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£';
+	}
+	if ( ! fm["body"].value ){
+		if ( err ) err += '\n';
+		err += '¥á¡¼¥ë¤ÎËÜÊ¸¤òÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£';
+	}
+	if( ! fm["template_name"]){
+		if ( err ) err += '\n';
+		err += '¥Æ¥ó¥×¥ì¡¼¥È¤ÎÌ¾Á°¤òÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£';
+	}
+	if ( err ){
+		alert(err);
+		return false;
+	} else {
+		if(window.confirm('ÆâÍÆ¤òÅÐÏ¿¤·¤Æ¤âµ¹¤·¤¤¤Ç¤¹¤«')){
+			return true;
+		}else{
+			return false;
+		}
+	}
+}
 //-->
 </script>
@@ -30,6 +61,8 @@
 <!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
 <table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
-<form name="form1" id="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+<form name="form1" id="form1" method="POST" action="<!--{$smarty.server.PHP_SELF|escape}-->" onsubmit="return lfnCheckSubmit();" >
 <input type="hidden" name="mode" value="regist">
+<!--{assign var=key value="template_id"}-->
+<input type="hidden" name="template_id" value="<!--{$arrForm[$key]|escape}-->">
 	<tr valign="top">
 		<td background="<!--{$smarty.const.URL_DIR}-->img/contents/navi_bg.gif" height="402">
@@ -70,13 +103,26 @@
 
 								<table width="678" border="0" cellspacing="1" cellpadding="8" summary=" ">
+									<tr class="fs12n">
+										<td bgcolor="#f2f1ec">¥á¡¼¥ë·Á¼°<span class="red"> *</span></td>
+										<td bgcolor="#ffffff">
+										<!--{assign var=key value="send_type"}-->
+										<!--{if $arrForm.template_id > 1}-->
+										<!--{html_radios_ex name="send_type" options=$arrSendType separator="&nbsp;" selected=$arrForm[$key]}-->
+										<!--{else}-->
+											<!--{if $arrForm.template_id=='0'}-->
+											<input type="radio" name="send_type" value="0" id="send_type_0" checked="checked" /><label for="send_type_0">¥Ñ¥½¥³¥ó</label>&nbsp;
+											<!--{else}-->
+											<input type="radio" name="send_type" value="1" id="send_type_1" checked="checked" /><label for="send_type_1">·ÈÂÓ</label>&nbsp;
+											<!--{/if}-->
+											<!--{* <!--{html_radios_ex name="send_type" options=$arrSendType separator="&nbsp;" selected=$arrForm[$key]}--> *}-->
+										<!--{/if}-->
+										</td>
+									</tr>
 									<tr>
 										<td bgcolor="#f2f1ec" width="160" class="fs12n">¥Æ¥ó¥×¥ì¡¼¥È<span class="red"> *</span></td>
 										<td bgcolor="#ffffff" width="557" class="fs10n">
-										<!--{assign var=key value="template_id"}-->
+										<!--{assign var=key value="template_name"}-->
 										<span class="red12"><!--{$arrErr[$key]}--></span>
-										<select name="template_id" onChange="return checkFlagAndSubmit();" style="<!--{$arrErr[$key]|sfGetErrorColor}-->">
-										<option value="" selected="selected">ÁªÂò¤·¤Æ¤¯¤À¤µ¤¤</option>
-										<!--{html_options options=$arrMailTEMPLATE selected=$arrForm[$key]}-->
-										</select>
+										<input type="text" name="template_name" value="<!--{$arrForm[$key]|escape}-->" onChange="setFlag();" size="30" class="box30" style="<!--{$arrErr[$key]|sfGetErrorColor}-->">
 										</td>
 									</tr>
@@ -90,38 +136,23 @@
 									</tr>
 									<tr>
-										<td bgcolor="#f2f1ec" width="160" class="fs12">¥Ø¥Ã¥À¡¼</td>
+										<td bgcolor="#f2f1ec" colspan="2" class="fs12n"><span class="red"> *</span>Ì¾Á°¤òº¹¤·¹þ¤à¾ì¹ç¤Ï¡¢{name}¤ÈÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£<br>
+										<span class="red"> *</span>ÃíÊ¸¾ðÊó¤òº¹¤·¹þ¤à¾ì¹ç¤Ï¡¢{order}¤ÈÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£</td>
+									</tr>
+									<tr>
+										<td bgcolor="#f2f1ec" width="160" class="fs12">ËÜÊ¸</td>
 										<td bgcolor="#ffffff" width="557" class="fs10">
-										<!--{assign var=key value="header"}-->
+										<!--{assign var=key value="body"}-->
 										<span class="red12"><!--{$arrErr[$key]}--></span>
-										<textarea name="header" cols="75" rows="12" class="area75" onChange="setFlag();" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"><!--{$arrForm[$key]|escape}--></textarea><br />
+										<textarea name="body" cols="75" rows="20" class="area75" onChange="setFlag();" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"><!--{$arrForm[$key]|escape}--></textarea><br />
 										<span class="red"> ¡Ê¾å¸Â<!--{$smarty.const.LTEXT_LEN}-->Ê¸»ú¡Ë
 										</span>
 						
 										<div align="right">
-											<input type="button" width="110" height="30" value="Ê¸»ú¿ô¥«¥¦¥ó¥È" onclick="fnCharCount('form1','header','cnt_header');" border="0" name="next" id="next" />
+											<input type="button" width="110" height="30" value="Ê¸»ú¿ô¥«¥¦¥ó¥È" onclick="fnCharCount('form1','body','cnt_body');" border="0" name="next" id="next" />
 											<br>º£¤Þ¤Ç¤ËÆþÎÏ¤·¤¿¤Î¤Ï
-											<input type="text" name="cnt_header" size="4" class="box4" readonly = true style="text-align:right">
+											<input type="text" name="cnt_body" size="4" class="box4" readonly = true style="text-align:right">
 											Ê¸»ú¤Ç¤¹¡£
 										</div>
 						
-										</td>
-									</tr>
-						
-									<tr class="fs12n">
-										<td bgcolor="#ffffff" colspan="2" align="center" height="40">Æ°Åª¥Ç¡¼¥¿ÁÞÆþÉôÊ¬</td>
-									</tr>
-									<tr>
-										<td bgcolor="#f2f1ec" width="160" class="fs12">¥Õ¥Ã¥¿¡¼</td>
-										<td bgcolor="#ffffff" width="557" class="fs10">
-										<!--{assign var=key value="footer"}-->
-										<span class="red12"><!--{$arrErr[$key]}--></span>
-										<textarea name="footer" cols="75" rows="12" class="area75" onChange="setFlag();" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"><!--{$arrForm[$key]|escape}--></textarea><br />
-										<span class="red"> ¡Ê¾å¸Â<!--{$smarty.const.LTEXT_LEN}-->Ê¸»ú¡Ë</span>
-										<div align="right">
-											<input type="button" width="110" height="30" value="Ê¸»ú¿ô¥«¥¦¥ó¥È" onclick="fnCharCount('form1','footer','cnt_footer');" border="0" name="next" id="next" />
-											<br>º£¤Þ¤Ç¤ËÆþÎÏ¤·¤¿¤Î¤Ï
-											<input type="text" name="cnt_footer" size="4" class="box4" readonly = true style="text-align:right">
-											Ê¸»ú¤Ç¤¹¡£
-										</div>
 										</td>
 									</tr>
Index: /branches/beta/data/Smarty/templates/admin/basis/template_input.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/template_input.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/admin/basis/template_input.tpl	(revision 14676)
@@ -0,0 +1,143 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<script language="JavaScript">
+<!--
+function lfnCheckSubmit(){
+	
+	fm = document.form1;
+	var err = '';
+	
+	if ( ! fm["subject"].value ){
+		err += 'Subject¤òÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£';
+	}
+	if ( ! fm["body"].value ){
+		if ( err ) err += '\n';
+		err += 'ËÜÊ¸¤òÆþÎÏ¤·¤Æ²¼¤µ¤¤¡£';
+	}
+	if ( err ){
+		alert(err);
+		return false;
+	} else {
+		if(window.confirm('ÆâÍÆ¤òÅÐÏ¿¤·¤Æ¤âµ¹¤·¤¤¤Ç¤¹¤«')){
+			return true;
+		}else{
+			return false;
+		}
+	}
+}
+//-->
+</script>
+
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+<table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
+<form name="form1" id="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->" onSubmit="return lfnCheckSubmit();">
+<input type="hidden" name="mode" value="<!--{$mode}-->">
+<input type="hidden" name="template_id" value="<!--{$arrForm.template_id}-->">
+	<tr valign="top">
+		<td background="<!--{$smarty.const.URL_DIR}-->img/contents/navi_bg.gif" height="402">
+			<!--¢§SUB NAVI-->
+			<!--{include file=$tpl_subnavi}-->
+			<!--¢¥SUB NAVI-->
+		</td>
+		<td class="mainbg">
+			<!--¢§ÅÐÏ¿¥Æ¡¼¥Ö¥ë¤³¤³¤«¤é-->
+			<table width="737" border="0" cellspacing="0" cellpadding="0" summary=" ">
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+				<tr>
+					<td align="center">
+						<table width="706" border="0" cellspacing="0" cellpadding="0" summary=" ">
+							<tr><td height="14"></td></tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_top.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+								<td bgcolor="#cccccc">
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
+										<td bgcolor="#636469" width="638" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë-->ÇÛ¿®ÆâÍÆÀßÄê¡§<!--{$title}--></span></td>
+										<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="678" height="7" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="678" height="10" alt=""></td>
+									</tr>
+								</table>
+
+								<table width="678" border="0" cellspacing="1" cellpadding="8" summary=" ">
+									<tr class="fs12n">
+										<td bgcolor="#f2f1ec">¥á¡¼¥ë·Á¼°<span class="red"> *</span></td>
+										<td bgcolor="#ffffff"><span <!--{if $arrErr.mail_method}--><!--{sfSetErrorStyle}--><!--{/if}-->><!--{html_radios name="mail_method" options=$arrMagazineType separator="&nbsp;" selected=$arrForm.mail_method}--></span>
+										<!--{if $arrErr.mail_method}--><br><span class="red12"><!--{$arrErr.mail_method}--></span><!--{/if}-->
+										</td>
+									</tr>
+									<tr>
+										<td bgcolor="#f2f1ec" class="fs12n">Subject<span class="red"> *</span></td>
+										<td bgcolor="#ffffff">
+										<input type="text" name="subject" size="65" class="box65" <!--{if $arrErr.subject}--><!--{sfSetErrorStyle}--><!--{/if}--> value="<!--{$arrForm.template_name|escape}-->" />
+										<!--{if $arrErr.subject}--><br><span class="red12"><!--{$arrErr.subject}--></span><!--{/if}-->
+										</td>
+									</tr>
+									<tr>
+										<td bgcolor="#f2f1ec" colspan="2" class="fs12n">ËÜÊ¸<span class="red"> *</span>¡ÊÌ¾Á°º¹¤·¹þ¤ß»þ¤Ï {name} ¤È¤¤¤ì¤Æ¤¯¤À¤µ¤¤¡Ë</td>
+									</tr>
+									<tr>
+										<td bgcolor="#ffffff" colspan="2">
+										<textarea name="body" cols="90" rows="40" class="area90" <!--{if $arrErr.body}--><!--{sfSetErrorStyle}--><!--{/if}-->><!--{$arrForm.body|escape}--></textarea>
+										<!--{if $arrErr.body}--><br><span class="red12"><!--{$arrErr.body}--></span><!--{/if}-->
+										</td>
+									</tr>
+								</table>
+
+								<table width="678" border="0" cellspacing="0" cellpadding="0" summary=" ">
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+										<td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_top.gif" width="676" height="7" alt=""></td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+									</tr>
+									<tr>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+										<td bgcolor="#e9e7de" align="center">
+										<table border="0" cellspacing="0" cellpadding="0" summary=" ">
+											<tr>
+												<td width="30%"></td>
+												<td width="40%" align = "center" valign="upper"><input type="image" onMouseover="chgImgImageSubmit('<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist_on.jpg',this)" onMouseout="chgImgImageSubmit('<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist.jpg',this)" src="<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist.jpg" width="123" height="24" alt="¤³¤ÎÆâÍÆ¤ÇÅÐÏ¿¤¹¤ë" border="0" name="subm"></td>
+												<td width="30%" align = "right" valign="upper"><input type="button" width="110" height="30" value="Ê¸»ú¿ô¥«¥¦¥ó¥È" onclick="fnCharCount('form1','body','cnt_footer');" border="0" name="next" id="next" />
+												<br><span class="fs10n">º£¤Þ¤Ç¤ËÆþÎÏ¤·¤¿¤Î¤Ï<input type="text" name="cnt_footer" size="4" class="box4" readonly = true style="text-align:right">Ê¸»ú¤Ç¤¹¡£</span></td>
+											</tr>
+										</table>
+										</td>
+										<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+									</tr>
+									<tr>
+										<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_bottom.gif" width="678" height="8" alt=""></td>
+									</tr>
+								</table>
+								</td>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_right.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+							</tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bottom.jpg" width="706" height="14" alt=""></td>
+							</tr>
+							<tr><td height="30"></td></tr>
+						</table>
+					</td>
+				</tr>
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+			</table>
+			<!--¢¥ÅÐÏ¿¥Æ¡¼¥Ö¥ë¤³¤³¤Þ¤Ç-->
+		</td>
+	</tr>
+</table>
+<!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
Index: /branches/beta/data/Smarty/templates/admin/basis/kiyaku.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/basis/kiyaku.tpl	(revision 11767)
+++ /branches/beta/data/Smarty/templates/admin/basis/kiyaku.tpl	(revision 14676)
@@ -121,10 +121,13 @@
 								</td>
 								<td align="center">
+								
 								<!--{if $smarty.section.cnt.iteration != 1}-->
 								<a href="<!--{$smarty.server.PHP_SELF|escape}-->" onclick="fnModeSubmit('up', 'kiyaku_id', <!--{$arrKiyaku[cnt].kiyaku_id}-->); return false;" />¾å¤Ø</a>
 								<!--{/if}-->
+								
 								<!--{if $smarty.section.cnt.iteration != $smarty.section.cnt.last}-->
 								<a href="<!--{$smarty.server.PHP_SELF|escape}-->" onclick="fnModeSubmit('down', 'kiyaku_id', <!--{$arrKiyaku[cnt].kiyaku_id}-->); return false;" />²¼¤Ø</a>
 								<!--{/if}-->
+								<!--{$smarty.section.cnt.last}--> <!--{$smarty.section.cnt.iteration}-->
 								</td>
 							</tr>
Index: /branches/beta/data/Smarty/templates/admin/products/upload_csv.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/products/upload_csv.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/products/upload_csv.tpl	(revision 14676)
@@ -7,7 +7,7 @@
 *}-->
 <!--¡ú¡ú¥á¥¤¥ó¥³¥ó¥Æ¥ó¥Ä¡ú¡ú-->
+<table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
 <form name="form1" id="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->" enctype="multipart/form-data" onSubmit="winSubmit('','form1', 'upload', 500, 400)">
 <input type="hidden" name="mode" value="csv_upload">
-<table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
 	<tr valign="top">
 		<td background="<!--{$smarty.const.URL_DIR}-->img/contents/navi_bg.gif" height="402">
Index: /branches/beta/data/Smarty/templates/admin/order/mail.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/order/mail.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/order/mail.tpl	(revision 14676)
@@ -75,4 +75,12 @@
 						<table width="678" border="0" cellspacing="1" cellpadding="8" summary=" ">
 							<tr>
+							    <td bgcolor="#f2f1ec" width="160" class="fs12n">¸ÜµÒÌ¾</td>
+							    <td bgcolor="#ffffff" width="557" class="fs12n"><!--{$arrDisp.order_name01|escape}--> <!--{$arrDisp.order_name02|escape}--></td>
+							</tr>
+							<tr>
+							    <td bgcolor="#f2f1ec" width="160" class="fs12n">¥á¡¼¥ë¥¢¥É¥ì¥¹</td>
+							    <td bgcolor="#ffffff" width="557" class="fs12n"><!--{$arrDisp.order_email|escape}--></td>
+							</tr>
+							<tr>
 								<td bgcolor="#f2f1ec" width="160" class="fs12n">¥Æ¥ó¥×¥ì¡¼¥È<span class="red"> *</span></td>
 								<td bgcolor="#ffffff" width="557" class="fs10n">
@@ -81,5 +89,7 @@
 								<select name="template_id" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" onchange="fnModeSubmit('change', '', '');">
 								<option value="" selected="selected">ÁªÂò¤·¤Æ¤¯¤À¤µ¤¤</option>
-								<!--{html_options options=$arrMAILTEMPLATE selected=$arrForm[$key].value|escape}-->
+
+
+								<!--{html_options options=$mailTemp[1] selected=$arrForm[$key].value|escape}-->
 								</select>
 								</td>
@@ -94,17 +104,7 @@
 							</tr>
 							<tr>
-								<td bgcolor="#f2f1ec" width="160" class="fs12">¥Ø¥Ã¥À¡¼</td>
+								<td bgcolor="#f2f1ec" width="160" class="fs12">¥á¡¼¥ë¤ÎÆâÍÆ</td>
 								<td bgcolor="#ffffff" width="557" class="fs10">
-								<!--{assign var=key value="header"}-->
-								<span class="red12"><!--{$arrErr[$key]}--></span>
-								<textarea  name="<!--{$arrForm[$key].keyname}-->" maxlength="<!--{$arrForm[$key].length}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" cols="75" rows="12" class="area75"><!--{$arrForm[$key].value|escape}--></textarea></td>
-							</tr>
-							<tr class="fs12n">
-								<td bgcolor="#ffffff" colspan="2" align="center" height="40">Æ°Åª¥Ç¡¼¥¿ÁÞÆþÉôÊ¬</td>
-							</tr>
-							<tr>
-								<td bgcolor="#f2f1ec" width="160" class="fs12">¥Õ¥Ã¥¿¡¼</td>
-								<td bgcolor="#ffffff" width="557" class="fs10">
-								<!--{assign var=key value="footer"}-->
+								<!--{assign var=key value="body"}-->
 								<span class="red12"><!--{$arrErr[$key]}--></span>
 								<textarea  name="<!--{$arrForm[$key].keyname}-->" maxlength="<!--{$arrForm[$key].length}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" cols="75" rows="12" class="area75"><!--{$arrForm[$key].value|escape}--></textarea></td>
Index: /branches/beta/data/Smarty/templates/admin/order/index.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/admin/order/index.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/admin/order/index.tpl	(revision 14676)
@@ -241,4 +241,7 @@
 <table width="878" border="0" cellspacing="0" cellpadding="0" summary=" ">
 <form name="form1" id="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+<!--{foreach from=$smarty.post key="key" item="item"}-->
+<!--{if $key ne "mode" && $key ne "del_mode" && $key ne "edit_customer_id" && $key ne "send_customer_id" && $key ne "del_customer_id" && $key ne "search_pageno" && $key ne "csv_mode" && $key ne "job" && $key ne "sex"}--><input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->"><!--{/if}-->
+<!--{/foreach}-->
 <input type="hidden" name="mode" value="search">
 <input type="hidden" name="order_id" value="">		
Index: /branches/beta/data/Smarty/templates/mail_templates/order_mail.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mail_templates/order_mail.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/mail_templates/order_mail.tpl	(revision 14676)
@@ -4,7 +4,5 @@
  * http://www.lockon.co.jp/
  *}-->
-<!--{$arrOrder.order_name01}--> <!--{$arrOrder.order_name02}--> ÍÍ
 
-<!--{$tpl_header}-->
 
 ******************************************************************
@@ -61,3 +59,2 @@
 ÊÝ»ý¥Ý¥¤¥ó¥È <!--{$arrCustomer.point|default:0}--> pt
 
-<!--{$tpl_footer}-->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/set1.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/set1.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/set1.tpl	(revision 14676)
@@ -0,0 +1,60 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">Â¾¤Î¤ªÆÏ¤±ÀèÅÐÏ¿</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+	<input type="hidden" name="mode" value="set2">
+
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡ÚÅÔÆ»ÉÜ¸©¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.pref}--></font>
+	<select name="pref">
+		<option value="">ÅÔÆ»ÉÜ¸©¤òÁªÂò</option>
+		<!--{html_options options=$arrPref selected=$arrForm.pref}-->
+	</select><br>
+
+	¡Ú»Ô¶èÄ®Â¼¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.addr01}--></font>
+	<input type="text" name="addr01" value="<!--{$arrForm.addr01|escape}-->" istyle="1"><br>
+
+	¡ÚÈÖÃÏ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.addr02}--></font>
+	<input type="text" name="addr02" value="<!--{$arrForm.addr02|escape}-->" istyle="1"><br>
+
+	¡ÚÅÅÏÃÈÖ¹æ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.tel01}--><!--{$arrErr.tel02}--><!--{$arrErr.tel03}--></font>
+	<!--{assign var="size" value="`$smarty.const.TEL_ITEM_LEN+2`"}-->
+	<input type="text" size="<!--{$size}-->" name="tel01" value="<!--{$arrForm.tel01|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input type="text" size="<!--{$size}-->" name="tel02" value="<!--{$arrForm.tel02|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input type="text" size="<!--{$size}-->" name="tel03" value="<!--{$arrForm.tel03|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4"><br>
+
+	<br>
+
+	<div align="center"><input type="submit" name="submit" value="¼¡¤Ø"></div>
+	<div align="center"><input type="submit" name="return" value="Ìá¤ë"></div>
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/confirm.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/confirm.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/confirm.tpl	(revision 14676)
@@ -0,0 +1,82 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<center>¤´ÃíÊ¸ÆâÍÆ³ÎÇ§</center>
+
+<hr>
+
+<form method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+<input type="hidden" name="mode" value="confirm">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+
+²¼µ­¤Î¤´ÃíÊ¸ÆâÍÆ¤Ë´Ö°ã¤¤¤Ï¤´¤¶¤¤¤Þ¤»¤ó¤«¡©<br>
+
+<br>
+
+¡ÚÇÛÁ÷Àè¡Û<br>
+<!--{if $arrData.deliv_check == 1}-->
+<!--{$arrData.deliv_name01|escape}--> <!--{$arrData.deliv_name02|escape}--><br>
+¢©<!--{$arrData.deliv_zip01|escape}-->-<!--{$arrData.deliv_zip02|escape}--><br>
+<!--{$arrPref[$arrData.deliv_pref]}--><!--{$arrData.deliv_addr01|escape}--><!--{$arrData.deliv_addr02|escape}--><br>
+<!--{else}-->
+<!--{$arrData.order_name01|escape}--> <!--{$arrData.order_name02|escape}--><br>
+¢©<!--{$arrData.order_zip01|escape}-->-<!--{$arrData.order_zip02|escape}--><br>
+<!--{$arrPref[$arrData.order_pref]}--><!--{$arrData.order_addr01|escape}--><!--{$arrData.order_addr02|escape}--><br>
+<!--{/if}-->
+
+<br>
+
+¡ÚÇÛÁ÷Æü»þ»ØÄê¡Û<br>
+Æü¡§<!--{$arrData.deliv_date|escape|default:"»ØÄê¤Ê¤·"}--><br>
+»þ´Ö¡§<!--{$arrData.deliv_time|escape|default:"»ØÄê¤Ê¤·"}--><br>
+
+<br>
+
+¡Ú¤ª»ÙÊ§¤¤ÊýË¡¡Û<br>
+<!--{$arrData.payment_method|escape}--><br>
+
+<br>
+
+¡Ú¤´ÃíÊ¸ÆâÍÆ¡Û<br>
+<!--{section name=cnt loop=$arrProductsClass}-->
+<!--{$arrProductsClass[cnt].name}--> <!--{$arrProductsClass[cnt].quantity|number_format}-->¸Ä<br>
+<!--{/section}-->
+
+<br>
+
+¡Ú¹ØÆþ¶â³Û¡Û<br>
+¾¦ÉÊ¹ç·×¡§<!--{$tpl_total_pretax|number_format}--><br>
+Á÷ÎÁ¡§<!--{$arrData.deliv_fee|number_format}--><br>
+<!--{if $arrData.charge > 0}-->¼ê¿ôÎÁ¡§<!--{$arrData.charge|number_format}--><br><!--{/if}-->
+¹ç·×¡§<!--{$arrData.payment_total|number_format}--><br>
+(Æâ¾ÃÈñÀÇ¡§<!--{$arrData.tax|number_format}-->)<br>
+
+<br>
+
+<center><input type="submit" value="ÃíÊ¸"></center>
+</form>
+<!--<form action="<!--{$smarty.const.MOBILE_URL_SHOP_PAYMENT}-->" method="post">-->
+<form action="./payment.php" method="post">
+<input type="hidden" name="mode" value="deliv_date">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+<input type="hidden" name="payment_id" value="<!--{$arrData.payment_id}-->">
+<input type="hidden" name="deliv_date" value="<!--{$arrData.deliv_date}-->">
+<input type="hidden" name="deliv_time_id" value="<!--{$arrData.deliv_time_id}-->">
+<center><input type="submit" value="Ìá¤ë"></center>
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<center>LOCKON CO.,LTD.</center>
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/deliv_addr.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/deliv_addr.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/deliv_addr.tpl	(revision 14676)
@@ -0,0 +1,64 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">Â¾¤Î¤ªÆÏ¤±ÀèÅÐÏ¿</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+	<input type="hidden" name="mode" value="set1">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡Ú¤ªÌ¾Á°¡Û<font color="#FF0000">¢¨</font><br>
+	<font color="#FF0000"><!--{$arrErr.name01}--><!--{$arrErr.name02}--></font>
+	À«¡ÊÎã¡§½ÂÃ«¡Ë<br>
+	<input type="text" name="name01" value="<!--{$arrForm.name01|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="1"><br>
+
+	Ì¾¡ÊÎã¡§²Ö»Ò¡Ë<br>
+	<input type="text" name="name02" value="<!--{$arrForm.name02|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="1"><br>
+	<font color="#FF0000"><!--{$arrErr.kana01}--><!--{$arrErr.kana02}--></font>
+
+	¥«¥Ê/À«¡ÊÎã¡§¥·¥Ö¥ä¡Ë<br>
+	<input type="text" name="kana01" value="<!--{$arrForm.kana01|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="2"><br>
+
+	¥«¥Ê/Ì¾¡ÊÎã¡§¥Ï¥Ê¥³¡Ë<br>
+	<input type="text" name="kana02" value="<!--{$arrForm.kana02|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="2"><br>
+
+	<br>
+
+	<!--{assign var=key1 value="zip01"}-->
+	<!--{assign var=key2 value="zip02"}-->
+	¡ÚÍ¹ÊØÈÖ¹æ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr[$key1]}--><!--{$arrErr[$key2]}--></font>
+	<!--{assign var="size1" value="`$smarty.const.ZIP01_LEN+2`"}-->
+	<!--{assign var="size2" value="`$smarty.const.ZIP02_LEN+2`"}-->
+	<input size="<!--{$size1}-->" type="text" name="zip01" value="<!--{if $arrForm.zip01 != ""}--><!--{$arrForm.zip01|escape}--><!--{else}--><!--{$zip01|escape}--><!--{/if}-->" maxlength="<!--{$smarty.const.ZIP01_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input size="<!--{$size2}-->" type="text" name="zip02" value="<!--{if $arrForm.zip02 != ""}--><!--{$arrForm.zip02|escape}--><!--{else}--><!--{$zip02|escape}--><!--{/if}-->" maxlength="<!--{$smarty.const.ZIP02_LEN}-->" istyle="4"><br>
+
+	<br>
+
+	<div align="center"><input type="submit" name="submit" value="¼¡¤Ø"></div>
+	<!--<div align="center"><input type="submit" name="return" value="Ìá¤ë"></div>-->
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/payment.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/payment.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/payment.tpl	(revision 14676)
@@ -0,0 +1,47 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<center>»ÙÊ§¤¤ÊýË¡»ØÄê</center>
+
+<hr>
+
+<!--<form method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">-->
+<form method="post" action="./payment.php">
+<input type="hidden" name="mode" value="deliv_date">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+<input type="hidden" name="deliv_date" value="<!--{$arrForm.deliv_date.value}-->">
+<input type="hidden" name="deliv_time_id" value="<!--{$arrForm.deliv_time_id.value}-->">
+<!--<input type="hidden" name="message" value="">-->
+<!--{if $tpl_login == 1}-->
+<!--<input type="hidden" name="point_check" value="2">-->
+<!--{/if}-->
+
+<!--{assign var=key value="payment_id"}-->
+<!--{if $arrErr[$key] != ""}-->
+<font color="red"><!--{$arrErr[$key]}--></font>
+<!--{/if}-->
+<!--{section name=cnt loop=$arrPayment}-->
+<input type="radio" name="<!--{$key}-->" value="<!--{$arrPayment[cnt].payment_id}-->" <!--{$arrPayment[cnt].payment_id|sfGetChecked:$arrForm[$key].value}-->>
+<!--{$arrPayment[cnt].payment_method|escape}-->
+<br>
+<!--{/section}-->
+
+<center><input type="submit" value="¼¡¤Ø"></center>
+<!--<center><input type="submit" name="return" value="Ìá¤ë"></center>-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<center>LOCKON CO.,LTD.</center>
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/set2.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/set2.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/set2.tpl	(revision 14676)
@@ -0,0 +1,38 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">Â¾¤Î¤ªÆÏ¤±ÀèÅÐÏ¿³ÎÇ§</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+	<input type="hidden" name="mode" value="complete">
+
+	¡Ú¸Ä¿Í¾ðÊó¡Û<br>
+	<!--{$list_data.name01|escape}-->¡¡<!--{$list_data.name02|escape}--><br>
+	<!--{$list_data.kana01|escape}-->¡¡<!--{$list_data.kana02|escape}--><br>
+	¢©<!--{$list_data.zip01|escape}--> - <!--{$list_data.zip02|escape}--><br>
+	<!--{$arrPref[$list_data.pref]|escape}--><!--{$list_data.addr01|escape}--><!--{$list_data.addr02|escape}--><br>
+	<!--{$list_data.tel01|escape}-->-<!--{$list_data.tel02|escape}-->-<!--{$list_data.tel03|escape}--><br>
+
+	<div align="center"><input type="submit" name="submit" value="¼¡¤Ø"></div>
+	<div align="center"><input type="submit" name="return" value="Ìá¤ë"></div>
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set1.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set1.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set1.tpl	(revision 14676)
@@ -0,0 +1,58 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">¤ªµÒÍÍ¾ðÊóÆþÎÏ 1/3</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+
+	<input type="hidden" name="mode" value="nonmember">
+	<input type="hidden" name="mode2" value="set2">
+	<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡Ú¥á¡¼¥ë¥¢¥É¥ì¥¹¡Û<font color="#FF0000">¢¨</font><br>
+	<font color="#FF0000"><!--{$arrErr.email}--></font>
+
+	<input type="text" name="email" value="<!--{$email|escape}-->" istyle="3">
+
+  <br>
+
+	¡Ú¤ªÌ¾Á°¡Û<font color="#FF0000">¢¨</font><br>
+	<font color="#FF0000"><!--{$arrErr.name01}--><!--{$arrErr.name02}--></font>
+	À«¡ÊÎã¡§½ÂÃ«¡Ë<br>
+	<input type="text" name="name01" value="<!--{$name01|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="1"><br>
+
+	Ì¾¡ÊÎã¡§²Ö»Ò¡Ë<br>
+	<input type="text" name="name02" value="<!--{$name02|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="1"><br>
+	<font color="#FF0000"><!--{$arrErr.kana01}--><!--{$arrErr.kana02}--></font>
+
+	¥«¥Ê/À«¡ÊÎã¡§¥·¥Ö¥ä¡Ë<br>
+	<input type="text" name="kana01" value="<!--{$kana01|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="2"><br>
+
+	¥«¥Ê/Ì¾¡ÊÎã¡§¥Ï¥Ê¥³¡Ë<br>
+	<input type="text" name="kana02" value="<!--{$kana02|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="2"><br>
+
+	<input type="submit" name="submit" value="¼¡¤Ø">
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set2.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set2.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set2.tpl	(revision 14676)
@@ -0,0 +1,62 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">¤ªµÒÍÍ¾ðÊóÆþÎÏ 2/3</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+	<input type="hidden" name="mode" value="nonmember">
+	<input type="hidden" name="mode2" value="set3">
+	<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡ÚÀ­ÊÌ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.sex}--></font>
+	<input type="radio" name="sex" value="1" <!--{if $sex eq 1}-->checked<!--{/if}--> />ÃËÀ­&nbsp;<input type="radio" name="sex" value="2" <!--{if $sex eq 2}-->checked<!--{/if}--> />½÷À­<br>
+
+	¡ÚÀ¸Ç¯·îÆü¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.year}--><!--{$arrErr.month}--><!--{$arrErr.day}--></font>
+	<input type="text" name="year" value="<!--{$year|escape}-->" size="4" maxlength="4" istyle="4">Ç¯(À¾Îñ)<br>
+	<select name="month">
+		<option value="">--</option>
+		<!--{html_options options=$arrMonth selected=$month}-->
+	</select>·î<br>
+	<select name="day">
+		<option value="">--</option>
+		<!--{html_options options=$arrDay selected=$day}-->
+	</select>Æü<br>
+
+	<!--{assign var=key1 value="zip01"}-->
+	<!--{assign var=key2 value="zip02"}-->
+	¡ÚÍ¹ÊØÈÖ¹æ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr[$key1]}--><!--{$arrErr[$key2]}--></font>
+	<!--{assign var="size1" value="`$smarty.const.ZIP01_LEN+2`"}-->
+	<!--{assign var="size2" value="`$smarty.const.ZIP02_LEN+2`"}-->
+	<input size="<!--{$size1}-->" type="text" name="zip01" value="<!--{if $zip01 == ""}--><!--{$arrOtherDeliv.zip01|escape}--><!--{else}--><!--{$zip01|escape}--><!--{/if}-->" maxlength="<!--{$smarty.const.ZIP01_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input size="<!--{$size2}-->" type="text" name="zip02" value="<!--{if $zip02 == ""}--><!--{$arrOtherDeliv.zip02|escape}--><!--{else}--><!--{$zip02|escape}--><!--{/if}-->" maxlength="<!--{$smarty.const.ZIP02_LEN}-->" istyle="4"><br>
+
+	<input type="submit" name="submit" value="¼¡¤Ø"><br>
+	<input type="submit" name="return" value="Ìá¤ë">
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/deliv_date.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/deliv_date.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/deliv_date.tpl	(revision 14676)
@@ -0,0 +1,66 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<center>ÇÛÃ£Æü»þ»ØÄê</center>
+
+<hr>
+
+<form method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+<input type="hidden" name="mode" value="confirm">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+<input type="hidden" name="payment_id" value="<!--{$arrForm.payment_id.value}-->">
+<input type="hidden" name="zip01" value="<!--{$arrAddr[0].zip01}-->">
+<input type="hidden" name="zip02" value="<!--{$arrAddr[0].zip02}-->">
+<input type="hidden" name="pref" value="<!--{$arrAddr[0].pref}-->">
+<input type="hidden" name="addr01" value="<!--{$arrAddr[0].addr01}-->">
+<input type="hidden" name="addr02" value="<!--{$arrAddr[0].addr02}-->">
+<!--<input type="hidden" name="message" value="">-->
+<!--{if $tpl_login == 1}-->
+<!--<input type="hidden" name="point_check" value="2">-->
+<!--{/if}-->
+
+¢£ÇÛÁ÷Æü»ØÄê<br>
+<!--{assign var=key value="deliv_date"}-->
+<!--{if $arrErr[$key] != ""}-->
+<font color="red"><!--{$arrErr[$key]}--></font>
+<!--{/if}-->
+<!--{if $arrDelivDate}-->
+<select name="<!--{$key}-->">
+<option value="">»ØÄê¤Ê¤·</option>
+<!--{html_options options=$arrDelivDate selected=$arrForm[$key].value}-->
+</select>
+<!--{else}-->
+¤´»ØÄêÄº¤±¤Þ¤»¤ó¡£
+<!--{/if}-->
+<br><br>
+
+¢£»þ´ÖÂÓ»ØÄê<br>
+<!--{assign var=key value="deliv_time_id"}-->
+<!--{if $arrErr[$key] != ""}-->
+<font color="red"><!--{$arrErr[$key]}--></font>
+<!--{/if}-->
+<select name="<!--{$key}-->">
+<option value="">»ØÄê¤Ê¤·</option>
+<!--{html_options options=$arrDelivTime selected=$arrForm[$key].value}-->
+</select>
+<br>
+
+<center><input type="submit" value="¼¡¤Ø"></center>
+<center><input type="submit" name="return" value="Ìá¤ë"></center>
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<center>LOCKON CO.,LTD.</center>
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set3.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set3.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_set3.tpl	(revision 14676)
@@ -0,0 +1,68 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+ 
+*}-->
+<div align="center">¤ªµÒÍÍ¾ðÊóÆþÎÏ 3/3</div>
+<hr>
+	<!--<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">-->
+	<form name="form1" method="post" action="./deliv.php">
+	<input type="hidden" name="mode" value="nonmember">
+	<input type="hidden" name="mode2" value="deliv">
+	<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡ÚÅÔÆ»ÉÜ¸©¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.pref}--></font>
+	<select name="pref">
+		<option value="">ÅÔÆ»ÉÜ¸©¤òÁªÂò</option>
+		<!--{html_options options=$arrPref selected=$pref}-->
+	</select><br>
+
+	¡Ú»Ô¶èÄ®Â¼¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.addr01}--></font>
+	<input type="text" name="addr01" value="<!--{$addr01|escape}-->" istyle="1"><br>
+
+	¡ÚÈÖÃÏ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.addr02}--></font>
+	<input type="text" name="addr02" value="<!--{$addr02|escape}-->" istyle="1"><br>
+
+	¡ÚÅÅÏÃÈÖ¹æ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.tel01}--><!--{$arrErr.tel02}--><!--{$arrErr.tel03}--></font>
+	<!--{assign var="size" value="`$smarty.const.TEL_ITEM_LEN+2`"}-->
+	<input type="text" size="<!--{$size}-->" name="tel01" value="<!--{$tel01|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input type="text" size="<!--{$size}-->" name="tel02" value="<!--{$tel02|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input type="text" size="<!--{$size}-->" name="tel03" value="<!--{$tel03|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4"><br>
+
+	<!--¡Ú¥á¡¼¥ë¥Þ¥¬¥¸¥ó¡Û<br>
+	¤ªÆÀ¤Ê¾ðÊó¤ò´õË¾¤µ¤ì¤Þ¤¹¤«¡©<br>
+	ÇÛ¿®´õË¾<input type="checkbox" name="mailmaga_flg" value="on" <!--{if $mailmaga_flg eq 'on'}-->checked<!--{/if}--> /><br>
+	¡Ê´õË¾¤µ¤ì¤Ê¤¤¾ì¹ç¤Ï¥Á¥§¥Ã¥¯¤ò¤Ï¤º¤·¤Æ¤¯¤À¤µ¤¤¡Ë<br>
+	<br>-->
+
+	<input type="submit" name="submit" value="¼¡¤Ø"><br>
+	<input type="submit" name="return" value="Ìá¤ë">
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="hidden" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/deliv.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/deliv.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/deliv.tpl	(revision 14676)
@@ -0,0 +1,56 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<center>ÇÛÁ÷Àè»ØÄê</center>
+
+<hr>
+
+<!--{if $arrErr.deli != ""}-->
+<font color="#ff0000"><!--{$arrErr.deli}--></font>
+<!--{/if}-->
+
+<!--¢§CONTENTS-->
+<!--{section name=cnt loop=$arrAddr}-->
+<form method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+<input type="hidden" name="deli" value="<!--{$smarty.section.cnt.iteration}-->">
+<!--{if $smarty.section.cnt.first}-->
+<input type="hidden" name="mode" value="customer_addr">
+<input type="hidden" name="other_deliv_id" value="">
+<!--{else}-->
+<input type="hidden" name="mode" value="other_addr">
+<input type="hidden" name="other_deliv_id" value="<!--{$arrAddr[cnt].other_deliv_id}-->">
+<!--{/if}-->
+¢£ÇÛÁ÷Àè<!--{$smarty.section.cnt.iteration}--><br>
+¢©<!--{$arrAddr[cnt].zip01}-->-<!--{$arrAddr[cnt].zip02}--><br>
+<!--{assign var=key value=$arrAddr[cnt].pref}--><!--{$arrPref[$key]}--><!--{$arrAddr[cnt].addr01|escape}--><br>
+<!--{if $arrAddr[cnt].addr02 != ""}-->
+<!--{$arrAddr[cnt].addr02|escape}--><br>
+<!--{/if}-->
+<center><input type="submit" value="¤³¤³¤ËÁ÷¤ë"></center>
+</form>
+<!--{/section}-->
+
+<br>
+
+¢£¤½¤ÎÂ¾¤Î¤ªÆÏ¤±Àè¤ò»ØÄê<br>
+<form method="get" action="deliv_addr.php">
+<center><input type="submit" value="¿·µ¬ÅÐÏ¿"></center>
+</form>
+<!--¢¥CONTENTS-->
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<center>LOCKON CO.,LTD.</center>
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_deliv.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_deliv.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/nonmember_deliv.tpl	(revision 14676)
@@ -0,0 +1,57 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<center>ÇÛÁ÷Àè»ØÄê</center>
+
+<hr>
+
+<!--{if $arrErr.deli != ""}-->
+<font color="#ff0000"><!--{$arrErr.deli}--></font>
+<!--{/if}-->
+
+<!--¢§CONTENTS-->
+<!--{section name=cnt loop=$arrAddr}-->
+<form method="post" action="<!--{$smarty.const.MOBILE_URL_DIR}-->nonmember/payment.php">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+<input type="hidden" name="deli" value="<!--{$smarty.section.cnt.iteration}-->">
+<!--{if $smarty.section.cnt.first}-->
+<input type="hidden" name="mode" value="nonmember">
+<input type="hidden" name="mode2" value="customer_addr">
+<input type="hidden" name="other_deliv_id" value="">
+<!--{else}-->
+<input type="hidden" name="mode" value="other_addr">
+<input type="hidden" name="other_deliv_id" value="<!--{$arrAddr[cnt].other_deliv_id}-->">
+<!--{/if}-->
+¢£ÇÛÁ÷Àè<!--{$smarty.section.cnt.iteration}--><br>
+¢©<!--{$arrAddr[cnt].zip01}-->-<!--{$arrAddr[cnt].zip02}--><br>
+<!--{assign var=key value=$arrAddr[cnt].pref}--><!--{$arrPref[$key]}--><!--{$arrAddr[cnt].addr01|escape}--><br>
+<!--{if $arrAddr[cnt].addr02 != ""}-->
+<!--{$arrAddr[cnt].addr02|escape}--><br>
+<!--{/if}-->
+<center><input type="submit" value="¤³¤³¤ËÁ÷¤ë"></center>
+</form>
+<!--{/section}-->
+
+<br>
+
+¢£¤½¤ÎÂ¾¤Î¤ªÆÏ¤±Àè¤ò»ØÄê<br>
+<form method="get" action="deliv_addr.php">
+<center><input type="submit" value="¿·µ¬ÅÐÏ¿"></center>
+</form>
+<!--¢¥CONTENTS-->
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<center>LOCKON CO.,LTD.</center>
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/index.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/index.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/index.tpl	(revision 14676)
@@ -0,0 +1,64 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<!--¢§CONTENTS-->
+<!--¢§MAIN ONTENTS-->
+<div align="center"><font color="#000080">¤´ÃíÊ¸¼êÂ³¤­</font></div><br>
+<hr>
+<!--{if !$tpl_valid_phone_id}-->
+<!--¢§²ñ°÷ÅÐÏ¿¤¬¤ªºÑ¤ß¤Ç¤Ê¤¤¤ªµÒÍÍ-->
+¢£½é¤á¤Æ¤´ÃíÊ¸¤ÎÊý<br>
+(¿·µ¬¤´ÅÐÏ¿)<br>
+<form name="member_form" id="member_form" method="post" action="<!--{$smarty.const.MOBILE_URL_DIR}-->entry/kiyaku.php">
+	<div align="center"><input type="submit" value="¿·µ¬ÅÐÏ¿"></div><br>
+</form>
+<!--¢¥¤Þ¤À²ñ°÷ÅÐÏ¿¤µ¤ì¤Æ¤¤¤Ê¤¤¤ªµÒÍÍ-->
+<!--{/if}-->
+
+<!--¢§²ñ°÷ÅÐÏ¿¤¬¤ªºÑ¤ß¤Î¤ªµÒÍÍ-->
+<form name="member_form" id="member_form" method="post" action="./deliv.php">
+	<input type="hidden" name="mode" value="login">
+<!--{if !$tpl_valid_phone_id}-->
+	¢£°ÊÁ°¤Ë¤´ÃíÊ¸¤µ¤ì¤¿Êý<br>
+	(¥â¥Ð¥¤¥ëËô¤ÏPC¤Ç¤´ÅÐÏ¿ºÑ¤ß)<br>
+	¢§¥á¡¼¥ë¥¢¥É¥ì¥¹<br>
+	<!--{assign var=key value="login_email"}-->
+	<font color="#FF0000"><!--{$arrErr[$key]}--></font>
+	<input type="text" name="<!--{$key}-->" value="<!--{$tpl_login_email|escape}-->" 
+		maxlength="<!--{$arrForm[$key].length}-->" size="40" istyle="3"><br>
+<!--{else}-->
+<input type="hidden" name="login_email" value="dummy">
+<!--{/if}-->
+	¢§¥Ñ¥¹¥ï¡¼¥É<br>
+	<!--{assign var=key value="login_pass"}--><font color="#FF0000"><!--{$arrErr[$key]}--></font>
+	<input type="password" name="<!--{$key}-->" maxlength="<!--{$arrForm[$key].length}-->" size="40" istyle="3"><br>
+	<center><input type="submit" value="Á÷¿®" name="log"></center><br>
+	<a href="<!--{$smarty.const.MOBILE_URL_DIR}-->forgot/index.php">¥Ñ¥¹¥ï¡¼¥É¤ò¤ªËº¤ì¤ÎÊý¤Ï¤³¤Á¤é</a><br>
+	
+</form>
+<!--¢¥²ñ°÷ÅÐÏ¿¤¬¤ªºÑ¤Î¤ªµÒÍÍ-->
+<!--¢§²ñ°÷ÅÐÏ¿¤µ¤ì¤Ê¤¤¤ªµÒÍÍ-->
+<form name="nonmember_form" id="nonmember_form" method="post" action="<!--{$smarty.const.MOBILE_URL_DIR}-->shopping/index.php">
+	<input type="hidden" name="mode" value="nonmember">
+	<input type="hidden" name="mode2" value="set1">
+	<center><input type="submit" value="ÅÐÏ¿¤»¤º¤Ë¹ØÆþ" name="nonmember"></center>
+</form>
+<!--¢¥²ñ°÷ÅÐÏ¿¤µ¤ì¤Ê¤¤¤ªµÒÍÍ-->
+<!--¢¥MAIN ONTENTS-->
+<!--¢¥CONTENTS-->
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/nonmember/complete.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/nonmember/complete.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/nonmember/complete.tpl	(revision 14676)
@@ -0,0 +1,27 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">²ñ°÷ÅÐÏ¿´°Î»</div>
+<hr>
+
+²ñ°÷ÅÐÏ¿¤Î¼õÉÕ¤¬´°Î»¤¤¤¿¤·¤Þ¤·¤¿¡£<br>
+¸½ºß<font color="#FF0000">²¾²ñ°÷</font>¤Î¾õÂÖ¤Ç¤¹¡£<br>
+¤´ÆþÎÏ¤¤¤¿¤À¤¤¤¿¥á¡¼¥ë¥¢¥É¥ì¥¹°¸¤Æ¤Ë¡¢¤´Ï¢Íí¤¬ÆÏ¤¤¤Æ¤ª¤ê¤Þ¤¹¤Î¤Ç¡¢ËÜ²ñ°÷ÅÐÏ¿¤Ë¤Ê¤Ã¤¿¾å¤Ç¤ªÇã¤¤Êª¤ò¤ª³Ú¤·¤ß¤¯¤À¤µ¤¤¡£<br>
+º£¸å¤È¤â¤´°¦¸Ü»ò¤ê¤Þ¤¹¤è¤¦¤è¤í¤·¤¯¤ª´ê¤¤¿½¤·¾å¤²¤Þ¤¹¡£<br>
+
+<br>
+
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set1.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set1.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set1.tpl	(revision 14676)
@@ -0,0 +1,58 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">¤ªµÒÍÍ¾ðÊóÆþÎÏ 1/3</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+
+	<input type="text" name="mode" value="nonmember">
+	<input type="text" name="mode2" value="set2">
+	<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡Ú¥á¡¼¥ë¥¢¥É¥ì¥¹¡Û<font color="#FF0000">¢¨</font><br>
+	<font color="#FF0000"><!--{$arrErr.email}--></font>
+
+	<input type="text" name="email" value="<!--{$email|escape}-->" istyle="3">
+
+  <br>
+
+	¡Ú¤ªÌ¾Á°¡Û<font color="#FF0000">¢¨</font><br>
+	<font color="#FF0000"><!--{$arrErr.name01}--><!--{$arrErr.name02}--></font>
+	À«¡ÊÎã¡§½ÂÃ«¡Ë<br>
+	<input type="text" name="name01" value="<!--{$name01|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="1"><br>
+
+	Ì¾¡ÊÎã¡§²Ö»Ò¡Ë<br>
+	<input type="text" name="name02" value="<!--{$name02|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="1"><br>
+	<font color="#FF0000"><!--{$arrErr.kana01}--><!--{$arrErr.kana02}--></font>
+
+	¥«¥Ê/À«¡ÊÎã¡§¥·¥Ö¥ä¡Ë<br>
+	<input type="text" name="kana01" value="<!--{$kana01|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="2"><br>
+
+	¥«¥Ê/Ì¾¡ÊÎã¡§¥Ï¥Ê¥³¡Ë<br>
+	<input type="text" name="kana02" value="<!--{$kana02|escape}-->" maxlength="<!--{$smarty.const.STEXT_LEN}-->" istyle="2"><br>
+
+	<input type="submit" name="submit" value="¼¡¤Ø">
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="text" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set2.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set2.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set2.tpl	(revision 14676)
@@ -0,0 +1,62 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<div align="center">¤ªµÒÍÍ¾ðÊóÆþÎÏ 2/3</div>
+<hr>
+<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+	<input type="text" name="mode" value="nonmember">
+	<input type="text" name="mode2" value="set3">
+	<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡ÚÀ­ÊÌ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.sex}--></font>
+	<input type="radio" name="sex" value="1" <!--{if $sex eq 1}-->checked<!--{/if}--> />ÃËÀ­&nbsp;<input type="radio" name="sex" value="2" <!--{if $sex eq 2}-->checked<!--{/if}--> />½÷À­<br>
+
+	¡ÚÀ¸Ç¯·îÆü¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.year}--><!--{$arrErr.month}--><!--{$arrErr.day}--></font>
+	<input type="text" name="year" value="<!--{$year|escape}-->" size="4" maxlength="4" istyle="4">Ç¯(À¾Îñ)<br>
+	<select name="month">
+		<option value="">--</option>
+		<!--{html_options options=$arrMonth selected=$month}-->
+	</select>·î<br>
+	<select name="day">
+		<option value="">--</option>
+		<!--{html_options options=$arrDay selected=$day}-->
+	</select>Æü<br>
+
+	<!--{assign var=key1 value="zip01"}-->
+	<!--{assign var=key2 value="zip02"}-->
+	¡ÚÍ¹ÊØÈÖ¹æ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr[$key1]}--><!--{$arrErr[$key2]}--></font>
+	<!--{assign var="size1" value="`$smarty.const.ZIP01_LEN+2`"}-->
+	<!--{assign var="size2" value="`$smarty.const.ZIP02_LEN+2`"}-->
+	<input size="<!--{$size1}-->" type="text" name="zip01" value="<!--{if $zip01 == ""}--><!--{$arrOtherDeliv.zip01|escape}--><!--{else}--><!--{$zip01|escape}--><!--{/if}-->" maxlength="<!--{$smarty.const.ZIP01_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input size="<!--{$size2}-->" type="text" name="zip02" value="<!--{if $zip02 == ""}--><!--{$arrOtherDeliv.zip02|escape}--><!--{else}--><!--{$zip02|escape}--><!--{/if}-->" maxlength="<!--{$smarty.const.ZIP02_LEN}-->" istyle="4"><br>
+
+	<input type="submit" name="submit" value="¼¡¤Ø"><br>
+	<input type="submit" name="return" value="Ìá¤ë">
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="text" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set3.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set3.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_set3.tpl	(revision 14676)
@@ -0,0 +1,67 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+ 
+*}-->
+<div align="center">¤ªµÒÍÍ¾ðÊóÆþÎÏ 3/3</div>
+<hr>
+	<form name="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
+	<input type="text" name="mode" value="nonmember">
+	<input type="text" name="mode2" value="deliv">
+	<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+	
+	<font color="#FF0000">*¤ÏÉ¬¿Ü¹àÌÜ¤Ç¤¹¡£</font><br>
+	<br>
+
+	¡ÚÅÔÆ»ÉÜ¸©¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.pref}--></font>
+	<select name="pref">
+		<option value="">ÅÔÆ»ÉÜ¸©¤òÁªÂò</option>
+		<!--{html_options options=$arrPref selected=$pref}-->
+	</select><br>
+
+	¡Ú»Ô¶èÄ®Â¼¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.addr01}--></font>
+	<input type="text" name="addr01" value="<!--{$addr01|escape}-->" istyle="1"><br>
+
+	¡ÚÈÖÃÏ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.addr02}--></font>
+	<input type="text" name="addr02" value="<!--{$addr02|escape}-->" istyle="1"><br>
+
+	¡ÚÅÅÏÃÈÖ¹æ¡Û<font color="#FF0000">*</font><br>
+	<font color="#FF0000"><!--{$arrErr.tel01}--><!--{$arrErr.tel02}--><!--{$arrErr.tel03}--></font>
+	<!--{assign var="size" value="`$smarty.const.TEL_ITEM_LEN+2`"}-->
+	<input type="text" size="<!--{$size}-->" name="tel01" value="<!--{$tel01|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input type="text" size="<!--{$size}-->" name="tel02" value="<!--{$tel02|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4">
+	&nbsp;-&nbsp;
+	<input type="text" size="<!--{$size}-->" name="tel03" value="<!--{$tel03|escape}-->" maxlength="<!--{$smarty.const.TEL_ITEM_LEN}-->" istyle="4"><br>
+
+	<!--¡Ú¥á¡¼¥ë¥Þ¥¬¥¸¥ó¡Û<br>
+	¤ªÆÀ¤Ê¾ðÊó¤ò´õË¾¤µ¤ì¤Þ¤¹¤«¡©<br>
+	ÇÛ¿®´õË¾<input type="checkbox" name="mailmaga_flg" value="on" <!--{if $mailmaga_flg eq 'on'}-->checked<!--{/if}--> /><br>
+	¡Ê´õË¾¤µ¤ì¤Ê¤¤¾ì¹ç¤Ï¥Á¥§¥Ã¥¯¤ò¤Ï¤º¤·¤Æ¤¯¤À¤µ¤¤¡Ë<br>
+	<br>-->
+
+	<input type="submit" name="submit" value="¼¡¤Ø"><br>
+	<input type="submit" name="return" value="Ìá¤ë">
+
+	<!--{foreach from=$list_data key=key item=item}-->
+		<input type="text" name="<!--{$key|escape}-->" value="<!--{$item|escape}-->">
+	<!--{/foreach}-->
+</form>
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<!--{include file='footer.tpl'}-->
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_deliv.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_deliv.tpl	(revision 14676)
+++ /branches/beta/data/Smarty/templates/mobile/shopping/nonmember_deliv.tpl	(revision 14676)
@@ -0,0 +1,62 @@
+<!--{*
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+*}-->
+<center>ÇÛÁ÷Àè»ØÄê</center>
+
+<hr>
+
+<!--{if $arrErr.deli != ""}-->
+<font color="#ff0000"><!--{$arrErr.deli}--></font>
+<!--{/if}-->
+
+<!--¢§CONTENTS-->
+<!--{section name=cnt loop=$arrAddr}-->
+<form method="post" action="<!--{$smarty.const.MOBILE_URL_DIR}-->shopping/payment.php">
+<input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->">
+<input type="hidden" name="deli" value="<!--{$smarty.section.cnt.iteration}-->">
+<!--{if $smarty.section.cnt.first}-->
+<input type="text" name="mode" value="nonmember">
+<input type="text" name="mode2" value="customer_addr">
+<input type="hidden" name="other_deliv_id" value="">
+<input type="hidden" name="zip01" value="<!--{$arrAddr[0].zip01}-->">
+<input type="hidden" name="zip02" value="<!--{$arrAddr[0].zip02}-->">
+<input type="hidden" name="pref" value="<!--{$arrAddr[0].pref}-->">
+<input type="hidden" name="addr01" value="<!--{$arrAddr[0].addr01}-->">
+<input type="hidden" name="addr02" value="<!--{$arrAddr[cnt].addr02}-->">
+<!--{else}-->
+<input type="hidden" name="mode" value="other_addr">
+<input type="text" name="other_deliv_id" value="<!--{$arrAddr[cnt].other_deliv_id}-->">
+<!--{/if}-->
+¢£ÇÛÁ÷Àè<!--{$smarty.section.cnt.iteration}--><br>
+¢©<!--{$arrAddr[cnt].zip01}-->-<!--{$arrAddr[cnt].zip02}--><br>
+<!--{assign var=key value=$arrAddr[cnt].pref}--><!--{$arrPref[$key]}--><!--{$arrAddr[cnt].addr01|escape}--><br>
+<!--{if $arrAddr[cnt].addr02 != ""}-->
+<!--{$arrAddr[cnt].addr02|escape}--><br>
+<!--{/if}-->
+<center><input type="submit" value="¤³¤³¤ËÁ÷¤ë"></center>
+</form>
+<!--{/section}-->
+
+<br>
+
+¢£¤½¤ÎÂ¾¤Î¤ªÆÏ¤±Àè¤ò»ØÄê<br>
+<form method="get" action="deliv_addr.php">
+<center><input type="submit" value="¿·µ¬ÅÐÏ¿"></center>
+</form>
+<!--¢¥CONTENTS-->
+
+<br>
+<hr>
+
+<a href="<!--{$smarty.const.MOBILE_URL_CART_TOP}-->" accesskey="9"><!--{9|numeric_emoji}-->¤«¤´¤ò¸«¤ë</a><br>
+<a href="<!--{$smarty.const.MOBILE_URL_SITE_TOP}-->" accesskey="0"><!--{0|numeric_emoji}-->TOP¥Ú¡¼¥¸¤Ø</a><br>
+
+<br>
+
+<!-- ¢§¥Õ¥Ã¥¿¡¼ ¤³¤³¤«¤é -->
+<center>LOCKON CO.,LTD.</center>
+<!-- ¢¥¥Õ¥Ã¥¿¡¼ ¤³¤³¤Þ¤Ç -->
Index: /branches/beta/data/Smarty/templates/mobile/shopping/index.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/shopping/index.tpl	(revision 11853)
+++ /branches/beta/data/Smarty/templates/mobile/shopping/index.tpl	(revision 14676)
@@ -39,6 +39,14 @@
 	<center><input type="submit" value="Á÷¿®" name="log"></center><br>
 	<a href="<!--{$smarty.const.MOBILE_URL_DIR}-->forgot/index.php">¥Ñ¥¹¥ï¡¼¥É¤ò¤ªËº¤ì¤ÎÊý¤Ï¤³¤Á¤é</a><br>
+	
 </form>
 <!--¢¥²ñ°÷ÅÐÏ¿¤¬¤ªºÑ¤Î¤ªµÒÍÍ-->
+<!--¢§²ñ°÷ÅÐÏ¿¤µ¤ì¤Ê¤¤¤ªµÒÍÍ-->
+<form name="nonmember_form" id="nonmember_form" method="post" action="<!--{$smarty.const.MOBILE_URL_DIR}-->nonmember/index.php">
+	<input type="hidden" name="mode" value="nonmember">
+	<input type="hidden" name="mode2" value="set1">
+	<center><input type="submit" value="ÅÐÏ¿¤»¤º¤Ë¹ØÆþ" name="nonmember"></center>
+</form>
+<!--¢¥²ñ°÷ÅÐÏ¿¤µ¤ì¤Ê¤¤¤ªµÒÍÍ-->
 <!--¢¥MAIN ONTENTS-->
 <!--¢¥CONTENTS-->
Index: /branches/beta/data/Smarty/templates/mobile/mail_templates/order_mail.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/mobile/mail_templates/order_mail.tpl	(revision 11686)
+++ /branches/beta/data/Smarty/templates/mobile/mail_templates/order_mail.tpl	(revision 14676)
@@ -6,5 +6,5 @@
  */
 *}-->
-<!--{$arrOrder.order_name01}--> <!--{$arrOrder.order_name02}--> ÍÍ
+
 
 ¢£ÇÛÁ÷¾ðÊó¤È¤´ÀÁµá¶â³Û
Index: /branches/beta/data/Smarty/templates/site_frame.tpl
===================================================================
--- /branches/beta/data/Smarty/templates/site_frame.tpl	(revision 17)
+++ /branches/beta/data/Smarty/templates/site_frame.tpl	(revision 14676)
@@ -17,4 +17,5 @@
 <script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/win_op.js"></script>
 <script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/site.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/json.js"></script>
 <title><!--{$arrSiteInfo.shop_name}-->/<!--{$tpl_title|escape}--></title>
 <meta name="author" content="<!--{$arrPageLayout.author|escape}-->">
Index: /branches/beta/data/include/ftp.php
===================================================================
--- /branches/beta/data/include/ftp.php	(revision 14676)
+++ /branches/beta/data/include/ftp.php	(revision 14676)
@@ -0,0 +1,104 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+/*
+    $host:FTP¥Û¥¹¥È
+    $user:FTP¥æ¡¼¥¶
+    $pass:FTP¥Ñ¥¹¥ï¡¼¥É
+    $dst_file:Á÷¿®Àè¥Õ¥¡¥¤¥ë¡ÊÁêÂÐ¥Ñ¥¹¡Ë
+    $src_file:Á÷¿®¸µ¥Õ¥¡¥¤¥ë¡ÊÀäÂÐ¥Ñ¥¹¡Ë
+ */
+function sfFtpCopy($host, $user, $pass, $dst_file, $src_file) {
+    // FTPÀÜÂ³
+    $conn_id = ftp_connect($host); 
+
+    // ÀÜÂ³³ÎÇ§
+    if((!$conn_id)) {
+        gfPrintLog("FTPÀÜÂ³¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£SERVER:" . $host);
+        return;
+    }
+    
+    // FTP¥í¥°¥¤¥ó
+    $login_result = ftp_login($conn_id, $user, $pass); 
+        
+    if ((!$login_result)) { 
+        gfPrintLog("FTP¥í¥°¥¤¥ó¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£USER:" . $user . " SERVER:" . $host);
+        return;
+    }
+    
+    // Á÷¿®¸µ¥Õ¥¡¥¤¥ë¤ÎÂ¸ºß¥Á¥§¥Ã¥¯
+    if (is_file($src_file)) {
+        
+        // ¥Õ¥¡¥¤¥ëÁ÷¿®
+        $upload = ftp_put($conn_id, $dst_file, $src_file, FTP_BINARY); 
+    } else {
+        gfPrintLog("FTPÁ÷¿®¸µ¥Õ¥¡¥¤¥ë¤¬¸«¤Ä¤«¤ê¤Þ¤»¤ó¡£" . $src_file);
+        return;
+    }
+    
+    // ¥Õ¥¡¥¤¥ë¥¢¥Ã¥×¥í¡¼¥É
+    if (!$upload) { 
+        gfPrintLog("¥¢¥Ã¥×¥í¡¼¥É¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£SERVER:" . $host . " " . $src_file . " -> " . $dst_file);
+    } else {
+        gfPrintLog("¥¢¥Ã¥×¥í¡¼¥É¤ËÀ®¸ù¤·¤Þ¤·¤¿¡£SERVER:" . $host . " " . $src_file . " -> " . $dst_file);
+    }
+
+    // ÀÜÂ³¤òÊÄ¤¸¤ë 
+    ftp_close($conn_id);
+}
+
+function sfFtpDelete($host, $user, $pass, $dst_file) {
+    // FTPÀÜÂ³
+    $conn_id = @ftp_connect($host); 
+    
+    // ÀÜÂ³³ÎÇ§
+    if((!$conn_id)) {
+        gfPrintLog("FTPÀÜÂ³¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£SERVER:" . $host);
+        return;
+    }
+    
+    // FTP¥í¥°¥¤¥ó
+    $login_result = @ftp_login($conn_id, $user, $pass); 
+    
+    if ((!$login_result)) { 
+        gfPrintLog("FTP¥í¥°¥¤¥ó¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£USER:" . $user . " SERVER:" . $host);
+        return;
+    }
+        
+    // ¥Õ¥¡¥¤¥ëºï½ü
+    if (@ftp_delete($conn_id, $dst_file)) { 
+        gfPrintLog("¥Õ¥¡¥¤¥ëºï½ü¤ËÀ®¸ù¤·¤Þ¤·¤¿¡£SERVER:" . $host . " " . $dst_file);
+    } else {
+        gfPrintLog("¥Õ¥¡¥¤¥ëºï½ü¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£SERVER:" . $host . " " . $dst_file);
+    }
+    
+    // ÀÜÂ³¤òÊÄ¤¸¤ë 
+    ftp_close($conn_id);
+}
+
+ /* 
+ * ´Ø¿ôÌ¾ ¡§sfFtpExist
+ * °ú¿ô1¡¡:FTP¥Û¥¹¥È
+ * $user:FTP¥æ¡¼¥¶
+ * $pass:FTP¥Ñ¥¹¥ï¡¼¥É
+ * $file_path:¥Õ¥¡¥¤¥ë¥Ñ¥¹
+ * Ìá¤êÃÍ¡§Â¸ºß¤·¤¿¤étrueÌµ¤«¤Ã¤¿¤éfalse¤òÊÖ¤¹
+ * ÀâÌÀ¡¡¡§FTP¤¹¤ë¥µ¡¼¥Ð¤Ë¥Õ¥¡¥¤¥ë¤¬Ìµ¤¤¤«Ä´ºº¤¹¤ë
+ */
+ function sfFtpExist($host, $user, $pass, $file_path) {
+
+    $conn_id = ftp_connect($host);
+    $login_result = ftp_login($conn_id, $user, $pass);
+    $res = ftp_size($conn_id, $file_path);
+
+    // Ìá¤êÃÍ¤¬-1¤Ê¤é¥Õ¥¡¥¤¥ë¤¬Â¸ºß¤·¤Ê¤¤
+    if($res == -1) {
+        return false;
+    }
+        
+    return true;
+}
+?>
Index: /branches/beta/data/class/SC_CartSession.php
===================================================================
--- /branches/beta/data/class/SC_CartSession.php	(revision 11907)
+++ /branches/beta/data/class/SC_CartSession.php	(revision 14676)
@@ -173,5 +173,5 @@
 	
 	// ¥«¡¼¥È¤Ø¤Î¾¦ÉÊÄÉ²Ã
-	function addProduct($id, $quantity) {
+	function addProduct($id, $quantity, $campaign_id = "") {
 		$find = false;
 		$max = $this->getMax();
@@ -182,4 +182,8 @@
 				if(strlen($val) <= INT_LEN) {
 					$_SESSION[$this->key][$i]['quantity']+= $quantity;
+                    if(!empty($campaign_id)){
+                        $_SESSION[$this->key][$i]['campaign_id'] = $campaign_id;
+                        $_SESSION[$this->key][$i]['is_campaign'] = true;
+                    }
 				}
 				$find = true;
@@ -190,4 +194,8 @@
 			$_SESSION[$this->key][$max+1]['quantity'] = $quantity;
 			$_SESSION[$this->key][$max+1]['cart_no'] = $this->getNextCartID();
+            if(!empty($campaign_id)){
+                $_SESSION[$this->key][$max+1]['campaign_id'] = $campaign_id;
+                $_SESSION[$this->key][$max+1]['is_campaign'] = true;
+            }
 		}
 	}
@@ -322,5 +330,20 @@
 		}
 	}
-	
+    
+    /**
+     * ¥«¡¼¥È¤ÎÃæ¤Î¥­¥ã¥ó¥Ú¡¼¥ó¾¦ÉÊ¤Î¥Á¥§¥Ã¥¯
+     * @param integer $campaign_id ¥­¥ã¥ó¥Ú¡¼¥óID
+     * @return boolean True:¥­¥ã¥ó¥Ú¡¼¥ó¾¦ÉÊÍ­¤ê False:¥­¥ã¥ó¥Ú¡¼¥ó¾¦ÉÊÌµ¤·
+     */
+	function chkCampaign($campaign_id){
+		$max = $this->getMax();
+		for($i = 0; $i <= $max; $i++) {
+			if($_SESSION[$this->key][$i]['is_campaign'] and $_SESSION[$this->key][$i]['campaign_id'] == $campaign_id) return true;
+		}
+        
+		return false;
+	}
+    
+
 }
 ?>
Index: /branches/beta/data/class/SC_CustomerList.php
===================================================================
--- /branches/beta/data/class/SC_CustomerList.php	(revision 11771)
+++ /branches/beta/data/class/SC_CustomerList.php	(revision 14676)
@@ -5,5 +5,6 @@
  * http://www.lockon.co.jp/
  */
-
+$INC_PATH = realpath( dirname( __FILE__) );
+require( $INC_PATH ."/../conf/conf.php" );
 /*  [Ì¾¾Î] SC_CustomerList
  *  [³µÍ×] ²ñ°÷¸¡º÷ÍÑ¥¯¥é¥¹
@@ -191,14 +192,43 @@
 			$this->setWhere($sql_where);
 		}
-				
-		//¡¡ÇÛ¿®¥á¡¼¥ë¥¢¥É¥ì¥¹¼ïÊÌ
-		if ( $mode == 'magazine' ){
-			if ( strlen($this->arrSql['mail_type']) > 0 && $this->arrSql['mail_type'] == 2) {
-				$this->setWhere( " dtb_customer.email_mobile <> ''  ");
-			}
-		}
-							
-		//¡¡HTML-mail
-		if ( $mode == 'magazine' ){
+
+/*      2007/05/28  °ìÃ¶¡¢Ää»ß¤·¤Þ¤¹¡£				
+ *		//¡¡ÇÛ¿®¥á¡¼¥ë¥¢¥É¥ì¥¹¼ïÊÌ
+ *		if ( $mode == 'magazine' ){
+ *			if ( strlen($this->arrSql['mail_type']) > 0 && $this->arrSql['mail_type'] == 2) {
+ *				$this->setWhere( " dtb_customer.email_mobile <> ''  ");
+ *			}
+ *		}
+ */
+
+        if($mode == 'magazine'){
+        	global $arrDomainType;
+        	$sql_where = "";
+        	//¥É¥á¥¤¥ó»ØÄê¡££±¤Ï£Ð£Ã¡¢£²¤Ï·ÈÂÓ
+        	if ( $this->arrSql['domain'] > 0 ) {
+        		foreach($arrDomainType as $val) {
+        			if($this->arrSql['domain'] == 1) {
+        				if($sql_where == "") {
+        					$sql_where .= "dtb_customer.email NOT ILIKE ? ";
+        				} else {
+        					$sql_where .= "AND dtb_customer.email NOT ILIKE ? " ;
+        				}
+        			} elseif($this->arrSql['domain'] == 2) {
+        				if($sql_where == "") {
+        					$sql_where .= "dtb_customer.email ILIKE ? ";
+        				} else {
+        					$sql_where .= "OR dtb_customer.email LIKE ? " ;
+        				}
+                        $sql_where = "(".$sql_where.")";
+        			}
+        			$searchDomain = $this->addSearchStr($val);
+        			$this->arrVal[] = $searchDomain;
+        		}
+        	    $this->setWhere($sql_where);
+        	}
+        }
+
+		//¡¡HTML-mail¡ÊÇÛ¿®Êý¼°)
+		if( $mode == 'magazine' ){
 			if ( strlen($this->arrSql['htmlmail']) > 0 ) {
 				$this->setWhere( " mailmaga_flg = ? ");
Index: /branches/beta/data/class/SC_SelectSql.php
===================================================================
--- /branches/beta/data/class/SC_SelectSql.php	(revision 11917)
+++ /branches/beta/data/class/SC_SelectSql.php	(revision 14676)
@@ -27,5 +27,5 @@
 	}
 
-	//-- SQLÊ¬À¸À®
+	//-- SQLÊ¸À¸À®
 	function getSql( $mode = "" ){
 		$this->sql = $this->select ." ". $this->where ." ". $this->group ." ";
@@ -196,5 +196,5 @@
 		}
 	}
-
+	
 	function setOrder($order){
 		
Index: /branches/beta/data/class/SC_DbConn.php
===================================================================
--- /branches/beta/data/class/SC_DbConn.php	(revision 13370)
+++ /branches/beta/data/class/SC_DbConn.php	(revision 14676)
@@ -112,5 +112,5 @@
 				sfErrorHeader("DB¤Ø¤ÎÀÜÂ³¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£:" . $this->dsn);
 			}else{
-				sfErrorHeader("DB¤Ø¤ÎÀÜÂ³¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£:");
+				sfErrorHeader("DB¤Ø¤ÎÀÜÂ³¤Ë¼ºÇÔ¤·¤Þ¤·¤¿¡£");
 			}
 			return 0;
@@ -167,22 +167,33 @@
 	}
 
-    function send_err_mail( $result, $sql ){
-        
-        if ($this->err_disp && DEBUG_MODE) {
-            if ($_SERVER['HTTPS'] == "on") {
-                $url = "https://";
-            } else {
-                $url = "http://";
-            }
-            $url.= $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
-            
-            $errmsg = $url."\n\n";
-            $errmsg.= $sql . "\n";
-            $errmsg.= $result->message . "\n\n";
-            $errmsg.= $result->userinfo . "\n\n";
+    function debug_print($result, $sql){
+        $this->send_err_mail($result, $sql);
+    }
+    
+    function send_err_mail($result, $sql){
+        $url = '';
+        $errmsg = '';
+        
+        if ($_SERVER['HTTPS'] == "on") {
+            $url = "https://";
+        } else {
+            $url = "http://";
+        }
+        $url .= $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];
+        
+        $errmsg  = $url."\n\n";
+        $errmsg .= $sql . "\n";
+        $errmsg .= $result->message . "\n\n";
+        $errmsg .= $result->userinfo . "\n\n";
+        
+        if ($this->err_disp && DEBUG_MODE === true) {
+            print('<pre>');
             print_r(htmlspecialchars($errmsg, ENT_QUOTES, CHAR_CODE));
-
-            exit();
+            print('</pre>');
         }
+        
+        gfDebugLog($errmsg, DB_ERR_LOG_PATH);
+        
+        exit();
     }
 }
Index: /branches/beta/data/class/SC_Query.php
===================================================================
--- /branches/beta/data/class/SC_Query.php	(revision 337)
+++ /branches/beta/data/class/SC_Query.php	(revision 14676)
@@ -1,4 +1,4 @@
 <?php
-/*
+/**
  * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
  *
@@ -6,55 +6,141 @@
  */
 
+/**
+ *  SC_Query¥¯¥é¥¹
+ *
+ *  @author     LOCKON CO.,LTD.
+ *  @access     public
+ */
 class SC_Query {
-	var $option;
-	var $where;
-	var $conn;
-	var $groupby;
-	var $order;
-	
-	// ¥³¥ó¥¹¥È¥é¥¯¥¿
-	/*
-		$err_disp:¥¨¥é¡¼É½¼¨¤ò¹Ô¤¦¤«
-		$new¡§¿·µ¬¤ËÀÜÂ³¤ò¹Ô¤¦¤«
-	 */
-	function SC_Query($dsn = "", $err_disp = true, $new = false) {
-		$this->conn = new SC_DBconn($dsn, $err_disp, $new);
-		$this->where = "";
-		return $this->conn;
-	}
-	
-	// ¥¨¥é¡¼È½Äê
-	function isError() {
-		if(PEAR::isError($this->conn->conn)) {
-			return true;
-		}
-		return false;
-	}
-	
-	// COUNTÊ¸¤Î¼Â¹Ô
-	function count($table, $where = "", $arrval = array()) {
-		if(strlen($where) <= 0) {
-			$sqlse = "SELECT COUNT(*) FROM $table";
-		} else {
-			$sqlse = "SELECT COUNT(*) FROM $table WHERE $where";
-		}
-		// ¥«¥¦¥ó¥ÈÊ¸¤Î¼Â¹Ô
-		$ret = $this->conn->getOne($sqlse, $arrval);
-		return $ret;
-	}
-	
-	function select($col, $table, $where = "", $arrval = array()){
-		$sqlse = $this->getsql($col, $table, $where);
-		$ret = $this->conn->getAll($sqlse, $arrval);
-		return $ret;
-	}
-
-	function getLastQuery($disp = true) {
-		$sql = $this->conn->conn->last_query;
-		if($disp) { 
-			print($sql.";<br />\n");
-		}
-		return $sql;
-	}
+   /**#@+
+    * @access private
+    */
+    
+   /**
+    * SC_DBConn¥ª¥Ö¥¸¥§¥¯¥È
+    * @var SC_DBConn
+    */
+    var $conn;
+    
+   /**
+    * LIMIT,OFFSET ¶ç
+    * @var string
+    */
+    var $option;
+    
+   /**
+    * WHERE ¶ç
+    * @var string
+    */
+    var $where;
+    
+   /**
+    * GROUP BY ¶ç
+    * @var string
+    */
+    var $groupby;
+    
+   /**
+    * ORDER BY ¶ç
+    * @var string
+    */
+    var $order;
+    
+    /**#@-*/
+    
+    /**
+     *  SC_Query¥¯¥é¥¹¤Î¥³¥ó¥¹¥È¥é¥¯¥¿
+     *
+     *  @access public
+     *  @param  string  $dsn      DSN¾ðÊó
+     *  @param  boolean $err_disp ¥¨¥é¡¼É½¼¨¤ò¹Ô¤¦¤«¤É¤¦¤«
+     *  @param  boolean $new      ¿·µ¬¤ËDBÀÜÂ³¤ò¹Ô¤¦¤«¤É¤¦¤«
+     */
+    function SC_Query($dsn = "", $err_disp = true, $new = false) {
+        $this->conn = new SC_DBconn($dsn, $err_disp, $new);
+        $this->where   = "";
+        $this->option  = "";
+        $this->groupby = "";
+        return $this->conn; //?
+    }
+    
+    /**
+     *  DB¥¨¥é¡¼¤ÎÈ½Äê
+     *
+     *  @access public
+     *  @return boolean À®¸ù»þ¡§true ¼ºÇÔ»þ¡§false
+     */
+    function isError() {
+        if(PEAR::isError($this->conn->conn)) {
+            return true;
+        }
+        return false;
+    }
+    
+    /**
+     *  ¥ª¥×¥·¥ç¥ó¤Î½é´ü²½
+     *
+     *  @access public
+     *  @return void
+     */
+    function clear(){
+        $arrProperty = array_keys((get_object_vars($this)));
+        foreach ( $arrProperty as $property ) {
+            if ($property != 'conn') {
+                $this->$property = '';
+            }
+        }
+    }
+    
+    /**
+     *  COUNTÊ¸¤Î¼Â¹Ô
+     *
+     *  @access public
+     *  @param  string  $table  ¥Æ¡¼¥Ö¥ëÌ¾
+     *  @param  string  $where  WHERE¶ç
+     *  @param  array   $arrval ¥×¥ì¡¼¥¹¥Û¥ë¥À¤ÎÇÛÎó
+     *  @return string  ¥ì¥³¡¼¥É·ï¿ô
+     */
+    function count($table, $where = "", $arrval = array()) {
+        if(strlen($where) <= 0) {
+            $sqlse = "SELECT COUNT(*) FROM $table";
+        } else {
+            $sqlse = "SELECT COUNT(*) FROM $table WHERE $where";
+        }
+        // ¥«¥¦¥ó¥ÈÊ¸¤Î¼Â¹Ô
+        $ret = $this->conn->getOne($sqlse, $arrval);
+        return $ret;
+    }
+    
+    /**
+     *  SELECTÊ¸¤Î¼Â¹Ô
+     *
+     *  @access public
+     *  @param  string  $col    ¥«¥é¥àÌ¾
+     *  @param  string  $table  ¥Æ¡¼¥Ö¥ëÌ¾
+     *  @param  string  $where  WHERE¶ç
+     *  @param  array   $arrval ¥×¥ì¡¼¥¹¥Û¥ë¥À¤ÎÇÛÎó
+     *  @return array   SELECTÊ¸¤Î¼Â¹Ô·ë²Ì
+     */
+    function select($col, $table, $where = "", $arrval = array()){
+        $sqlse = $this->getsql($col, $table, $where);
+        $ret = $this->conn->getAll($sqlse, $arrval);
+        return $ret;
+    }
+    
+    /**
+     *  ºÇ¸å¤Ë¼Â¹Ô¤·¤¿SQLÊ¸¤ò¼èÆÀ¤¹¤ë
+     *
+     *  @access public
+     *  @param  boolean $disp SQLÊ¸¤òprint¤¹¤ë¤«¤É¤¦¤«
+     *  @return string  $disp==false¤Î¾ì¹ç¡§ºÇ¸å¤Ë¼Â¹Ô¤·¤¿SQLÊ¸¡¡$disp==true¤Î¾ì¹ç¡§¤Ê¤·
+     */
+    function getLastQuery($disp = true) {
+        $sql = $this->conn->conn->last_query;
+        if($disp) { 
+            print($sql.";<br />\n");
+        }
+        return $sql;
+    }
 
 	function commit() {
@@ -105,81 +191,157 @@
 	}
 
-	function getsql($col, $table, $where) {
-		if($where != "") {
-			// °ú¿ô¤Î$where¤òÍ¥Àè¤·¤Æ¼Â¹Ô¤¹¤ë¡£
-			$sqlse = "SELECT $col FROM $table WHERE $where " . $this->groupby . " " . $this->order . " " . $this->option;
-		} else {
-			if($this->where != "") {
-					$sqlse = "SELECT $col FROM $table WHERE $this->where " . $this->groupby . " " . $this->order . " " . $this->option;
-				} else {
-					$sqlse = "SELECT $col FROM $table " . $this->groupby . " " . $this->order . " " . $this->option;
-			}
-		}
-		return $sqlse;
-	}
-			
-	function setoption($str) {
-		$this->option = $str;
-	}
-	
-	function setlimitoffset($limit, $offset = 0, $return = false) {
-		if (is_numeric($limit) && is_numeric($offset)){
-			
-			$option.= " LIMIT " . $limit;
-			$option.= " OFFSET " . $offset;
-			
-			if($return){
-				return $option;
-			}else{
-				$this->option.= $option;
-			}
-		}
-	}
-	
-	function setgroupby($str) {
-		$this->groupby = "GROUP BY " . $str;
-	}
-	
-	function andwhere($str) {
-		if($this->where != "") {
-			$this->where .= " AND " . $str;
-		} else {
-			$this->where = $str;
-		}
-	}
-	
-	function orwhere($str) {
-		if($this->where != "") {
-			$this->where .= " OR " . $str;
-		} else {
-			$this->where = $str;
-		}
-	}
-		
-	function setwhere($str) {
-		$this->where = $str;
-	}
-	
-	function setorder($str) {
-		$this->order = "ORDER BY " . $str;
-	}
-	
-		
-	function setlimit($limit){
-		if ( is_numeric($limit)){
-			$this->option = " LIMIT " .$limit;
-		}	
-	}
-	
-	function setoffset($offset) {
-		if ( is_numeric($offset)){
-			$this->offset = " OFFSET " .$offset;
-		}	
-	}
-	
-	
-	// INSERTÊ¸¤ÎÀ¸À®¡¦¼Â¹Ô
-	// $table	:¥Æ¡¼¥Ö¥ëÌ¾
-	// $sqlval	:ÎóÌ¾ => ÃÍ¤Î³ÊÇ¼¤µ¤ì¤¿¥Ï¥Ã¥·¥åÇÛÎó
+    /**
+     *  SELECTÊ¸¤ò¹½ÃÛ¤¹¤ë
+     *
+     *  @access public
+     *  @param  string  $col    ¥«¥é¥àÌ¾
+     *  @param  string  $table  ¥Æ¡¼¥Ö¥ëÌ¾
+     *  @param  string  $where  WHERE¶ç
+     *  @return string  SQLÊ¸
+     */
+    function getsql($col, $table, $where="") {
+        if($where != "") {
+            // °ú¿ô¤Î$where¤òÍ¥Àè¤·¤Æ¼Â¹Ô¤¹¤ë¡£
+            $sqlse = "SELECT $col FROM $table WHERE $where " . $this->groupby . " " . $this->order . " " . $this->option;
+        } else {
+            if($this->where != "") {
+                    $sqlse = "SELECT $col FROM $table WHERE $this->where " . $this->groupby . " " . $this->order . " " . $this->option;
+                } else {
+                    $sqlse = "SELECT $col FROM $table " . $this->groupby . " " . $this->order . " " . $this->option;
+            }
+        }
+        return $sqlse;
+    }
+    
+    /**
+     *  WHERE,GROUPBY,ORDERBY°Ê³°¤Î¥ª¥×¥·¥ç¥Ê¥ë¤Ê¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access public
+     *  @param  string  $str ¥ª¥×¥·¥ç¥ó¤Ë»ÈÍÑ¤¹¤ëÊ¸»úÎó
+     */
+    function setoption($str) {
+        $this->option = $str;
+    }
+    
+    /**
+     *  LIMIT¶ç¡¢OFFSET¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access public
+     *  @param  mixed   $limit  LIMIT¤Î·ï¿ô
+     *  @param  mixed   $offset OFFSET¤Î·ï¿ô
+     *  @param  string  $return À¸À®¤·¤¿LIMIT,OFFSET¶ç¤òreturn¤¹¤ë¤«¤É¤¦¤«
+     *  @return string  À¸À®¤·¤¿LIMIT,OFFSET¶ç
+     */
+    function setlimitoffset($limit, $offset = 0, $return = false) {
+        if (is_numeric($limit) && is_numeric($offset)){
+            
+            $option.= " LIMIT " . $limit;
+            $option.= " OFFSET " . $offset;
+            
+            if($return){
+                return $option;
+            }else{
+                $this->option.= $option;
+            }
+        }
+    }
+
+    /**
+     *  GROUP BY ¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access public
+     *  @param  string  $str ¥«¥é¥àÌ¾
+     */
+    function setgroupby($str) {
+        $this->groupby = "GROUP BY " . $str;
+    }
+    
+    /**
+     *  WHERE ¶ç¤ò¥»¥Ã¥È¤¹¤ë(AND)
+     *
+     *  @access  public
+     *  @param   string  $str WHERE ¶ç
+     *  @example $objQuery->andWhere('product_id = ?');
+     */
+    function andwhere($str) {
+        if($this->where != "") {
+            $this->where .= " AND " . $str;
+        } else {
+            $this->where = $str;
+        }
+    }
+    
+    /**
+     *  WHERE ¶ç¤ò¥»¥Ã¥È¤¹¤ë(OR)
+     *
+     *  @access  public
+     *  @param   string  $str WHERE ¶ç
+     *  @example $objQuery->orWhere('product_id = ?');
+     */
+    function orwhere($str) {
+        if($this->where != "") {
+            $this->where .= " OR " . $str;
+        } else {
+            $this->where = $str;
+        }
+    }
+    
+    /**
+     *  WHERE ¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access  public
+     *  @param   string  $str WHERE ¶ç
+     *  @example $objQuery->setWhere('product_id = ?');
+     */
+    function setwhere($str) {
+        $this->where = $str;
+    }
+    
+    /**
+     *  ORDER BY ¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access  public
+     *  @param   string  $str ¥«¥é¥àÌ¾
+     *  @example $objQuery->setorder("rank DESC");
+     */
+    function setorder($str) {
+        $this->order = "ORDER BY " . $str;
+    }
+    
+    /**
+     *  LIMIT ¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access  public
+     *  @param   mixed  $limit LIMIT¤Î·ï¿ô
+     *  @example $objQuery->setlimit(50);
+     */
+    function setlimit($limit){
+        if ( is_numeric($limit)){
+            $this->option = " LIMIT " .$limit;
+        }   
+    }
+    
+    /**
+     *  OFFSET ¶ç¤ò¥»¥Ã¥È¤¹¤ë
+     *
+     *  @access  public
+     *  @param   mixed  $offset OFFSET¤Î·ï¿ô
+     *  @example $objQuery->setOffset(30);
+     */
+    function setoffset($offset) {
+        if ( is_numeric($offset)){
+            $this->offset = " OFFSET " .$offset;
+        }   
+    }
+    
+    /**
+     *  INSERTÊ¸¤ò¼Â¹Ô¤¹¤ë
+     *
+     *  @access  public
+     *  @param   string  $table  ¥Æ¡¼¥Ö¥ëÌ¾
+     *  @param   array   $sqlval (¥«¥é¥àÌ¾ => ÃÍ)¤ÎÏ¢ÁÛÇÛÎó
+     *  
+     *  @return  mixed   $result DB_Error¥ª¥Ö¥¸¥§¥¯¥È(¼ºÇÔ»þ)¤Þ¤¿¤ÏDB_OK(À®¸ù»þ)¤Þ¤¿¤Ïfalse(¥«¥é¥à¤¬¸«¤Ä¤«¤é¤Ê¤¤)
+     */
 	function insert($table, $sqlval) {
 		$strcol = '';
@@ -218,7 +380,13 @@
 	}
 	
-		// INSERTÊ¸¤ÎÀ¸À®¡¦¼Â¹Ô
-	// $table	:¥Æ¡¼¥Ö¥ëÌ¾
-	// $sqlval	:ÎóÌ¾ => ÃÍ¤Î³ÊÇ¼¤µ¤ì¤¿¥Ï¥Ã¥·¥åÇÛÎó
+    /**
+     *  INSERTÊ¸¤ò¼Â¹Ô¤¹¤ë
+     *
+     *  @access  public
+     *  @param   string  $table  ¥Æ¡¼¥Ö¥ëÌ¾
+     *  @param   array   $sqlval (¥«¥é¥àÌ¾ => ÃÍ)¤ÎÏ¢ÁÛÇÛÎó
+     *  
+     *  @return  mixed   $result DB_Error¥ª¥Ö¥¸¥§¥¯¥È(¼ºÇÔ»þ)¤Þ¤¿¤ÏDB_OK(À®¸ù»þ)¤Þ¤¿¤Ïfalse(¥«¥é¥à¤¬¸«¤Ä¤«¤é¤Ê¤¤)
+     */
 	function fast_insert($table, $sqlval) {
 		$strcol = '';
@@ -248,5 +416,5 @@
 		$ret = $this->conn->query($sqlin);
 		
-		return $ret;		
+		return $ret;
 	}
 	
@@ -373,4 +541,5 @@
 	}
 	
+    //»ØÄê¤·¤¿¥«¥é¥à¤Î°ìÈÖºÇ¸å¤Ë¥ì¥³¡¼¥É¤òÁÞÆþ
 	function nextval($table, $colname) {
 		$sql = "";
@@ -379,8 +548,10 @@
 			$seqtable = $table . "_" . $colname . "_seq";
 			$sql = "SELECT NEXTVAL('$seqtable')";
+            $ret = $this->conn->getOne($sql);
 		}else if (DB_TYPE == "mysql") {
-			$sql = "SELECT last_insert_id();";
-		}
-		$ret = $this->conn->getOne($sql);
+            $sql = "SELECT last_insert_id();";
+		    $ret = $this->conn->getOne($sql);
+        }
+		
 		
 		return $ret;
@@ -437,4 +608,3 @@
 	}
 }
-
 ?>
Index: /branches/beta/data/class/SC_View.php
===================================================================
--- /branches/beta/data/class/SC_View.php	(revision 14392)
+++ /branches/beta/data/class/SC_View.php	(revision 14676)
@@ -44,5 +44,5 @@
 		$this->_smarty->register_function("sfPrintEbisTag","sfPrintEbisTag");
 		$this->_smarty->register_function("sfPrintAffTag","sfPrintAffTag");
-        $this->_smarty->default_modifiers = array('script_escape');
+		$this->_smarty->default_modifiers = array('script_escape');
         
 		if(ADMIN_MODE == '1') {		
@@ -96,4 +96,8 @@
 			print("½èÍý»þ´Ö:" . $time . "ÉÃ");
 		}
+        
+        if (DEBUG_MODE === true) {
+            print($_SERVER["SERVER_ADDR"]."-");
+        }
 	}
   	
Index: /branches/beta/data/class/SC_UploadFile.php
===================================================================
--- /branches/beta/data/class/SC_UploadFile.php	(revision 293)
+++ /branches/beta/data/class/SC_UploadFile.php	(revision 14676)
@@ -7,307 +7,402 @@
 
 $SC_UPLOADFILE_DIR = realpath(dirname( __FILE__));
-require_once($SC_UPLOADFILE_DIR . "/../lib/gdthumb.php");	
+require_once($SC_UPLOADFILE_DIR . "/../lib/gdthumb.php");
+require_once($SC_UPLOADFILE_DIR . "/../include/ftp.php");
 
 /* ¥¢¥Ã¥×¥í¡¼¥É¥Õ¥¡¥¤¥ë´ÉÍý¥¯¥é¥¹ */
 class SC_UploadFile {
-	var $temp_dir;
-	var $save_dir;
-	var $keyname;	// ¥Õ¥¡¥¤¥ëinput¥¿¥°¤Îname
-	var $width;		// ²£¥µ¥¤¥º
-	var $height;	// ½Ä¥µ¥¤¥º
-	var $arrExt;	// »ØÄê¤¹¤ë³ÈÄ¥»Ò
-	var $temp_file;	// ÊÝÂ¸¤µ¤ì¤¿¥Õ¥¡¥¤¥ëÌ¾
-	var $save_file; // DB¤«¤éÆÉ¤ß½Ð¤·¤¿¥Õ¥¡¥¤¥ëÌ¾
-	var $disp_name;	// ¹àÌÜÌ¾
-	var $size;		// À©¸Â¥µ¥¤¥º
-	var $necessary; // É¬¿Ü¤Î¾ì¹ç:true
-	var $image;		// ²èÁü¤Î¾ì¹ç:true
-	
-	// ¥Õ¥¡¥¤¥ë´ÉÍý¥¯¥é¥¹
-	function SC_UploadFile($temp_dir, $save_dir) {
-		$this->temp_dir = $temp_dir;
-		$this->save_dir = $save_dir;
-		$this->file_max = 0;
-	}
-
-	// ¥Õ¥¡¥¤¥ë¾ðÊóÄÉ²Ã
-	function addFile($disp_name, $keyname, $arrExt, $size, $necessary=false, $width=0, $height=0, $image=true) {
-		$this->disp_name[] = $disp_name;
-		$this->keyname[] = $keyname;
-		$this->width[] = $width;
-		$this->height[] = $height;
-		$this->arrExt[] = $arrExt;
-		$this->size[] = $size;
-		$this->necessary[] = $necessary;
-		$this->image[] = $image;
-	}
-	// ¥µ¥à¥Í¥¤¥ë²èÁü¤ÎºîÀ®
-	function makeThumb($src_file, $width, $height) {
-		// °ì°Õ¤ÊID¤ò¼èÆÀ¤¹¤ë¡£
-		$uniqname = date("mdHi") . "_" . uniqid("");
-		
-		$dst_file = $this->temp_dir . $uniqname;
-		
-		$objThumb = new gdthumb();
-		$ret = $objThumb->Main($src_file, $width, $height, $dst_file);
-		
-		if($ret[0] != 1) {
-			// ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¤ÎÉ½¼¨
-			print($ret[1]);
-			exit;
-		}
-		
-		return basename($ret[1]);
-	}
-		
-	// ¥¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤¿¥Õ¥¡¥¤¥ë¤òÊÝÂ¸¤¹¤ë¡£
-	function makeTempFile($keyname, $rename = true) {
-		$objErr = new SC_CheckError();
-		$cnt = 0;
-		$arrKeyname = array_flip($this->keyname);
-		
-		if(!($_FILES[$keyname]['size'] > 0)) {
-			$objErr->arrErr[$keyname] = "¢¨ " . $this->disp_name[$arrKeyname[$keyname]] . "¤¬¥¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤Æ¤¤¤Þ¤»¤ó¡£<br />";
-		} else {
-			foreach($this->keyname as $val) {
-				// °ìÃ×¤·¤¿¥­¡¼¤Î¥Õ¥¡¥¤¥ë¤Ë¾ðÊó¤òÊÝÂ¸¤¹¤ë¡£
-				if ($val == $keyname) {
-					// ³ÈÄ¥»Ò¥Á¥§¥Ã¥¯
-					$objErr->doFunc(array($this->disp_name[$cnt], $keyname, $this->arrExt[$cnt]), array("FILE_EXT_CHECK"));
-					// ¥Õ¥¡¥¤¥ë¥µ¥¤¥º¥Á¥§¥Ã¥¯
-					$objErr->doFunc(array($this->disp_name[$cnt], $keyname, $this->size[$cnt]), array("FILE_SIZE_CHECK"));
-					// ¥¨¥é¡¼¤¬¤Ê¤¤¾ì¹ç
-					if(!isset($objErr->arrErr[$keyname])) {
-						// ²èÁü¥Õ¥¡¥¤¥ë¤Î¾ì¹ç
-						if($this->image[$cnt]) {
-							$this->temp_file[$cnt] = $this->makeThumb($_FILES[$keyname]['tmp_name'], $this->width[$cnt], $this->height[$cnt]);
-						// ²èÁü¥Õ¥¡¥¤¥ë°Ê³°¤Î¾ì¹ç
-						} else {
-							// °ì°Õ¤Ê¥Õ¥¡¥¤¥ëÌ¾¤òºîÀ®¤¹¤ë¡£
-							if($rename) {
-								$uniqname = date("mdHi") . "_" . uniqid("").".";
-								$this->temp_file[$cnt] = ereg_replace("^.*\.",$uniqname, $_FILES[$keyname]['name']);
-							} else {
-								$this->temp_file[$cnt] = $_FILES[$keyname]['name'];	
-							}
-							$result  = copy($_FILES[$keyname]['tmp_name'], $this->temp_dir. "/". $this->temp_file[$cnt]);
-							gfPrintLog($_FILES[$keyname]['name']." -> ".$this->temp_dir. "/". $this->temp_file[$cnt]);
-						}
-					}
-				}
-				$cnt++;
-			}
-		}
-		return $objErr->arrErr[$keyname];
-	}
-
-	// ²èÁü¤òºï½ü¤¹¤ë¡£
-	function deleteFile($keyname) {
-		$objImage = new SC_Image($this->temp_dir);
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if ($val == $keyname) {
-				// °ì»þ¥Õ¥¡¥¤¥ë¤Î¾ì¹çºï½ü¤¹¤ë¡£
-				if($this->temp_file[$cnt] != "") {
-					$objImage->deleteImage($this->temp_file[$cnt], $this->save_dir);
-				}
-				$this->temp_file[$cnt] = "";
-				$this->save_file[$cnt] = "";
-			}
-			$cnt++;
-		}
-	}
-	
-	// °ì»þ¥Õ¥¡¥¤¥ë¥Ñ¥¹¤ò¼èÆÀ¤¹¤ë¡£
-	function getTempFilePath($keyname) {
-		$cnt = 0;
-		$filepath = "";
-		foreach($this->keyname as $val) {
-			if ($val == $keyname) {
-				if($this->temp_file[$cnt] != "") {
-					$filepath = $this->temp_dir . "/" . $this->temp_file[$cnt];
-				}
-			}
-			$cnt++;
-		}
-		return $filepath;
-	}
-	
-	// °ì»þ¥Õ¥¡¥¤¥ë¤òÊÝÂ¸¥Ç¥£¥ì¥¯¥È¥ê¤Ë°Ü¤¹
-	function moveTempFile() {
-		$cnt = 0;
-		$objImage = new SC_Image($this->temp_dir);
-		
-		foreach($this->keyname as $val) {
-			if($this->temp_file[$cnt] != "") {
-													
-				$objImage->moveTempImage($this->temp_file[$cnt], $this->save_dir);
-				// ¤¹¤Ç¤ËÊÝÂ¸¥Õ¥¡¥¤¥ë¤¬¤¢¤Ã¤¿¾ì¹ç¤Ïºï½ü¤¹¤ë¡£
-				if($this->save_file[$cnt] != "" && !ereg("^sub/", $this->save_file[$cnt])) {
-					$objImage->deleteImage($this->save_file[$cnt], $this->save_dir);
-				}
-			}
-			$cnt++;
-		}
-	}
-	
-	// HIDDENÍÑ¤Î¥Õ¥¡¥¤¥ëÌ¾ÇÛÎó¤òÊÖ¤¹
-	function getHiddenFileList() {
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if($this->temp_file[$cnt] != "") {
-				$arrRet["temp_" . $val] = $this->temp_file[$cnt];
-			}
-			if($this->save_file[$cnt] != "") {
-				$arrRet["save_" . $val] = $this->save_file[$cnt];
-			}
-			$cnt++; 
-		}
-		return $arrRet;
-	}
-	
-	// HIDDEN¤ÇÁ÷¤é¤ì¤Æ¤­¤¿¥Õ¥¡¥¤¥ëÌ¾¤ò¼èÆÀ¤¹¤ë
-	function setHiddenFileList($arrPOST) {
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			$key = "temp_" . $val;
-			if($arrPOST[$key] != "") {
-				$this->temp_file[$cnt] = $arrPOST[$key];
-			}
-			$key = "save_" . $val;
-			if($arrPOST[$key] != "") {
-				$this->save_file[$cnt] = $arrPOST[$key];
-			}
-			$cnt++;
-		}
-	}
-	
-	// ¥Õ¥©¡¼¥à¤ËÅÏ¤¹ÍÑ¤Î¥Õ¥¡¥¤¥ë¾ðÊóÇÛÎó¤òÊÖ¤¹
-	function getFormFileList($temp_url, $save_url, $real_size = false) {
-
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if($this->temp_file[$cnt] != "") {
-				// ¥Õ¥¡¥¤¥ë¥Ñ¥¹¥Á¥§¥Ã¥¯(¥Ñ¥¹¤Î¥¹¥é¥Ã¥·¥å/¤¬Ï¢Â³¤·¤Ê¤¤¤è¤¦¤Ë¤¹¤ë¡£)
-				if(ereg("/$", $temp_url)) {
-					$arrRet[$val]['filepath'] = $temp_url . $this->temp_file[$cnt];
-				} else {
-					$arrRet[$val]['filepath'] = $temp_url . "/" . $this->temp_file[$cnt];
-				}
-				$arrRet[$val]['real_filepath'] = $this->temp_dir . $this->temp_file[$cnt];
-			} elseif ($this->save_file[$cnt] != "") {
-				// ¥Õ¥¡¥¤¥ë¥Ñ¥¹¥Á¥§¥Ã¥¯(¥Ñ¥¹¤Î¥¹¥é¥Ã¥·¥å/¤¬Ï¢Â³¤·¤Ê¤¤¤è¤¦¤Ë¤¹¤ë¡£)
-				if(ereg("/$", $save_url)) {
-					$arrRet[$val]['filepath'] = $save_url . $this->save_file[$cnt];
-				} else {
-					$arrRet[$val]['filepath'] = $save_url . "/" . $this->save_file[$cnt];
-				}
-				$arrRet[$val]['real_filepath'] = $this->save_dir . $this->save_file[$cnt];
-			}
-			if($arrRet[$val]['filepath'] != "") {
-				if($real_size){
-					if(is_file($arrRet[$val]['real_filepath'])) {
-						list($width, $height) = getimagesize($arrRet[$val]['real_filepath']);
-					}
-					// ¥Õ¥¡¥¤¥ë²£Éý
-					$arrRet[$val]['width'] = $width;
-					// ¥Õ¥¡¥¤¥ë½ÄÉý
-					$arrRet[$val]['height'] = $height;
-				}else{
-					// ¥Õ¥¡¥¤¥ë²£Éý
-					$arrRet[$val]['width'] = $this->width[$cnt];
-					// ¥Õ¥¡¥¤¥ë½ÄÉý
-					$arrRet[$val]['height'] = $this->height[$cnt];
-				}
-				// É½¼¨Ì¾
-				$arrRet[$val]['disp_name'] = $this->disp_name[$cnt];
-			}
-			$cnt++;
-		}
-		return $arrRet;
-	}
-	
-	// DBÊÝÂ¸ÍÑ¤Î¥Õ¥¡¥¤¥ëÌ¾ÇÛÎó¤òÊÖ¤¹
-	function getDBFileList() {
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if($this->temp_file[$cnt] != "") {
-				$arrRet[$val] = $this->temp_file[$cnt];
-			} else  {
-				$arrRet[$val] = $this->save_file[$cnt];
-			}
-			$cnt++;
-		}
-		return $arrRet;
-	}
-	
-	// DB¤ÇÊÝÂ¸¤µ¤ì¤¿¥Õ¥¡¥¤¥ëÌ¾ÇÛÎó¤ò¥»¥Ã¥È¤¹¤ë
-	function setDBFileList($arrVal) {
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if($arrVal[$val] != "") {
-				$this->save_file[$cnt] = $arrVal[$val];
-			}
-			$cnt++; 
-		}
-	}
-	
-	// ²èÁü¤ò¥»¥Ã¥È¤¹¤ë
-	function setDBImageList($arrVal) {
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if($arrVal[$val] != "" && $val == 'tv_products_image') {
-				$this->save_file[$cnt] = $arrVal[$val];
-			}
-			$cnt++; 
-		}
-	}
-	
-	// DB¾å¤Î¥Õ¥¡¥¤¥ë¤ÎÆâºï½üÍ×µá¤¬¤¢¤Ã¤¿¥Õ¥¡¥¤¥ë¤òºï½ü¤¹¤ë¡£ 
-	function deleteDBFile($arrVal) {
-		$objImage = new SC_Image($this->temp_dir);
-		$cnt = 0;
-		foreach($this->keyname as $val) {
-			if($arrVal[$val] != "") {
-				if($this->save_file[$cnt] == "" && !ereg("^sub/", $arrVal[$val])) {
-					$objImage->deleteImage($arrVal[$val], $this->save_dir);
-				}
-			}
-			$cnt++; 
-		}
-	}
-	
-	// É¬¿ÜÈ½Äê
-	function checkEXISTS($keyname = "") {
-		$cnt = 0;
-		$arrRet = array();
-		foreach($this->keyname as $val) {
-			if($val == $keyname || $keyname == "") {
-				// É¬¿Ü¤Ç¤¢¤ì¤Ð¥¨¥é¡¼¥Á¥§¥Ã¥¯
-				if ($this->necessary[$cnt] == true) {
-					if($this->save_file[$cnt] == "" && $this->temp_file[$cnt] == "") {
-						$arrRet[$val] = "¢¨ " . $this->disp_name[$cnt] . "¤¬¥¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤Æ¤¤¤Þ¤»¤ó¡£<br>";
-					}
-				}
-			}
-			$cnt++;
-		}
-		return $arrRet;
-	}
-		
-	// ³ÈÂçÎ¨¤ò»ØÄê¤·¤Æ²èÁüÊÝÂ¸
-	function saveResizeImage($keyname, $to_w, $to_h) {
-		$path = "";
-		
-		// keyname¤ÎÅºÉÕ¥Õ¥¡¥¤¥ë¤ò¼èÆÀ
-		$arrImageKey = array_flip($this->keyname);
-		$file = $this->temp_file[$arrImageKey[$keyname]];
-		$filepath = $this->temp_dir . $file;
-		
-		$path = $this->makeThumb($filepath, $to_w, $to_h);
-		
-		// ¥Õ¥¡¥¤¥ëÌ¾¤À¤±ÊÖ¤¹
-		return basename($path);
-	}
+    var $temp_dir;                  // °ì»þ¥Õ¥¡¥¤¥ëÊÝÂ¸¥Ç¥£¥ì¥¯¥È¥ê
+    var $save_dir;                  // ¥Õ¥¡¥¤¥ëÊÝÂ¸¥Ç¥£¥ì¥¯¥È
+    var $ftp_temp_dir;              // FTPÀè°ì»þ¥Ç¥£¥ì¥¯¥È¥ê(Éé²ÙÊ¬»¶»þ»ÈÍÑ)
+    var $ftp_save_dir;              // FTPÀè¥Õ¥¡¥¤¥ëÊÝÂ¸¥Ç¥£¥ì¥¯¥È¥ê(Éé²ÙÊ¬»¶»þ»ÈÍÑ)
+    var $multi_web_server_mode;     // Éé²ÙÊ¬»¶¥Õ¥é¥°(Éé²ÙÊ¬»¶»þ»ÈÍÑ)
+    var $keyname;                   // ¥Õ¥¡¥¤¥ëinput¥¿¥°¤Îname
+    var $width;                     // ²£¥µ¥¤¥º
+    var $height;                    // ½Ä¥µ¥¤¥º
+    var $arrExt;                    // »ØÄê¤¹¤ë³ÈÄ¥»Ò
+    var $temp_file;                 // ÊÝÂ¸¤µ¤ì¤¿¥Õ¥¡¥¤¥ëÌ¾
+    var $save_file;                 // DB¤«¤éÆÉ¤ß½Ð¤·¤¿¥Õ¥¡¥¤¥ëÌ¾
+    var $disp_name;                 // ¹àÌÜÌ¾
+    var $size;                      // À©¸Â¥µ¥¤¥º
+    var $necessary;                 // É¬¿Ü¤Î¾ì¹ç:true
+    var $image;                     // ²èÁü¤Î¾ì¹ç:true
+
+    // ¥Õ¥¡¥¤¥ë´ÉÍý¥¯¥é¥¹
+    function SC_UploadFile($temp_dir, $save_dir, $ftp_temp_dir = "", $ftp_save_dir = "", $multi_web_server_mode = false) {
+        $this->temp_dir = $temp_dir;
+        $this->save_dir = $save_dir;
+        $this->ftp_temp_dir = $ftp_temp_dir;
+        $this->ftp_save_dir = $ftp_save_dir;
+        $this->multi_web_server_mode = $multi_web_server_mode;
+        $this->file_max = 0;
+    }
+
+    // ¥Õ¥¡¥¤¥ë¾ðÊóÄÉ²Ã
+    function addFile($disp_name, $keyname, $arrExt, $size, $necessary=false, $width=0, $height=0, $image=true) {
+        $this->disp_name[] = $disp_name;
+        $this->keyname[] = $keyname;
+        $this->width[] = $width;
+        $this->height[] = $height;
+        $this->arrExt[] = $arrExt;
+        $this->size[] = $size;
+        $this->necessary[] = $necessary;
+        $this->image[] = $image;
+    }
+    // ¥µ¥à¥Í¥¤¥ë²èÁü¤ÎºîÀ®
+    function makeThumb($src_file, $width, $height) {
+        // °ì°Õ¤ÊID¤ò¼èÆÀ¤¹¤ë¡£
+        $uniqname = date("mdHi") . "_" . uniqid("");
+        
+        $objThumb = new gdthumb();
+        
+        // WEB¥µ¡¼¥ÐÉé²ÙÊ¬»¶´Ä¶­¤Î¾ì¹ç
+        if($this->multi_web_server_mode === true) {
+            
+            // FTPÍÑ¥Õ¥¡¥¤¥ë°ì»þ³ÊÇ¼ÍÑ¥Ç¥£¥ì¥¯¥È¥êºîÀ®
+            $ftp_temp_dir = $this->makeFtpTempDir($this->temp_dir);
+            $dst_file = $ftp_temp_dir . $uniqname;
+            $ret = $objThumb->Main($src_file, $width, $height, $dst_file);
+            $this->ftpMoveFile($this->ftp_temp_dir . basename($ret[1]), $ret[1], true);
+        } else {
+            $dst_file = $this->temp_dir . $uniqname;
+            $ret = $objThumb->Main($src_file, $width, $height, $dst_file);          
+        }
+        
+        if($ret[0] != 1) {
+            // ¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¤ÎÉ½¼¨
+            print($ret[1]);
+            exit;
+        }
+        
+        return basename($ret[1]);
+    }
+        
+    // ¥¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤¿¥Õ¥¡¥¤¥ë¤òÊÝÂ¸¤¹¤ë¡£
+    function makeTempFile($keyname, $rename = true) {
+        $objErr = new SC_CheckError();
+        $cnt = 0;
+        $arrKeyname = array_flip($this->keyname);
+        
+        if(!($_FILES[$keyname]['size'] > 0)) {
+            $objErr->arrErr[$keyname] = "¢¨ " . $this->disp_name[$arrKeyname[$keyname]] . "¤¬¥¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤Æ¤¤¤Þ¤»¤ó¡£<br />";
+        } else {
+            foreach($this->keyname as $val) {
+                // °ìÃ×¤·¤¿¥­¡¼¤Î¥Õ¥¡¥¤¥ë¤Ë¾ðÊó¤òÊÝÂ¸¤¹¤ë¡£
+                if ($val == $keyname) {
+                    // ³ÈÄ¥»Ò¥Á¥§¥Ã¥¯
+                    $objErr->doFunc(array($this->disp_name[$cnt], $keyname, $this->arrExt[$cnt]), array("FILE_EXT_CHECK"));
+                    // ¥Õ¥¡¥¤¥ë¥µ¥¤¥º¥Á¥§¥Ã¥¯
+                    $objErr->doFunc(array($this->disp_name[$cnt], $keyname, $this->size[$cnt]), array("FILE_SIZE_CHECK"));
+                    // ¥¨¥é¡¼¤¬¤Ê¤¤¾ì¹ç
+                    if(!isset($objErr->arrErr[$keyname])) {
+                        // ²èÁü¥Õ¥¡¥¤¥ë¤Î¾ì¹ç
+                        if($this->image[$cnt]) {
+                            $this->temp_file[$cnt] = $this->makeThumb($_FILES[$keyname]['tmp_name'], $this->width[$cnt], $this->height[$cnt]);
+                        // ²èÁü¥Õ¥¡¥¤¥ë°Ê³°¤Î¾ì¹ç
+                        } else {
+                            // °ì°Õ¤Ê¥Õ¥¡¥¤¥ëÌ¾¤òºîÀ®¤¹¤ë¡£
+                            if($rename) {
+                                $uniqname = date("mdHi") . "_" . uniqid("").".";
+                                $this->temp_file[$cnt] = ereg_replace("^.*\.",$uniqname, $_FILES[$keyname]['name']);
+                            } else {
+                                $this->temp_file[$cnt] = $_FILES[$keyname]['name'];    
+                            }
+                            $result  = copy($_FILES[$keyname]['tmp_name'], $this->temp_dir. "/". $this->temp_file[$cnt]);
+                            gfPrintLog($_FILES[$keyname]['name']." -> ".$this->temp_dir. "/". $this->temp_file[$cnt]);
+                        }
+                    }
+                }
+                $cnt++;
+            }
+        }
+        return $objErr->arrErr[$keyname];
+    }
+
+    // ²èÁü¤òºï½ü¤¹¤ë¡£
+    function deleteFile($keyname) {
+        $objImage = new SC_Image($this->temp_dir);
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if ($val == $keyname) {
+                // °ì»þ¥Õ¥¡¥¤¥ë¤Î¾ì¹çºï½ü¤¹¤ë¡£
+                if($this->temp_file[$cnt] != "") {
+                    // Éé²ÙÊ¬»¶»þ¤Ï¤¹¤Ù¤Æ¤Î¥µ¡¼¥Ð¤«¤éºï½ü
+                    if($this->multi_web_server_mode === true) {
+                        $this->ftpDeleteFile($this->ftp_temp_dir . $this->temp_file[$cnt]);
+                    } else {
+                        $objImage->deleteImage($this->temp_file[$cnt], $this->save_dir);
+                    }
+                }
+                $this->temp_file[$cnt] = "";
+                $this->save_file[$cnt] = "";
+            }
+            $cnt++;
+        }
+    }
+    
+    // °ì»þ¥Õ¥¡¥¤¥ë¥Ñ¥¹¤ò¼èÆÀ¤¹¤ë¡£
+    function getTempFilePath($keyname) {
+        $cnt = 0;
+        $filepath = "";
+        foreach($this->keyname as $val) {
+            if ($val == $keyname) {
+                if($this->temp_file[$cnt] != "") {
+                    $filepath = $this->temp_dir . "/" . $this->temp_file[$cnt];
+                }
+            }
+            $cnt++;
+        }
+        return $filepath;
+    }
+    
+    // °ì»þ¥Õ¥¡¥¤¥ë¤òÊÝÂ¸¥Ç¥£¥ì¥¯¥È¥ê¤Ë°Ü¤¹
+    function moveTempFile() {
+        $cnt = 0;
+        $objImage = new SC_Image($this->temp_dir);
+        
+        foreach($this->keyname as $val) {
+            if($this->temp_file[$cnt] != "") {
+                // Éé²ÙÊ¬»¶»þ¤Ï¤¹¤Ù¤Æ¤Î¥µ¡¼¥Ð¤Ç°ÜÆ°¤ò¼Â¹Ô
+                if($this->multi_web_server_mode === true) {
+                    $dist_path = $this->ftp_save_dir . $this->temp_file[$cnt];
+                    $src_path = $this->temp_dir . $this->temp_file[$cnt];
+                    $this->ftpMoveFile($dist_path, $src_path);
+                } else {
+                    $objImage->moveTempImage($this->temp_file[$cnt], $this->save_dir);
+                }
+                
+                // ¤¹¤Ç¤ËÊÝÂ¸¥Õ¥¡¥¤¥ë¤¬¤¢¤Ã¤¿¾ì¹ç¤Ïºï½ü¤¹¤ë¡£
+                if($this->save_file[$cnt] != "" && !ereg("^sub/", $this->save_file[$cnt])) {
+                    // Éé²ÙÊ¬»¶»þ¤Ï¤¹¤Ù¤Æ¤Î¥µ¡¼¥Ð¤Ç¥Õ¥¡¥¤¥ëºï½ü
+                    if($this->multi_web_server_mode === true) {
+                        $this->ftpDeleteFile($this->ftp_save_dir . $this->save_file[$cnt]);
+                    } else {
+                        $objImage->deleteImage($this->save_file[$cnt], $this->save_dir);
+                    }
+                }
+            }
+            $cnt++;
+        }
+    }
+    
+    // HIDDENÍÑ¤Î¥Õ¥¡¥¤¥ëÌ¾ÇÛÎó¤òÊÖ¤¹
+    function getHiddenFileList() {
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if($this->temp_file[$cnt] != "") {
+                $arrRet["temp_" . $val] = $this->temp_file[$cnt];
+            }
+            if($this->save_file[$cnt] != "") {
+                $arrRet["save_" . $val] = $this->save_file[$cnt];
+            }
+            $cnt++; 
+        }
+        return $arrRet;
+    }
+    
+    // HIDDEN¤ÇÁ÷¤é¤ì¤Æ¤­¤¿¥Õ¥¡¥¤¥ëÌ¾¤ò¼èÆÀ¤¹¤ë
+    function setHiddenFileList($arrPOST) {
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            $key = "temp_" . $val;
+            if($arrPOST[$key] != "") {
+                $this->temp_file[$cnt] = $arrPOST[$key];
+            }
+            $key = "save_" . $val;
+            if($arrPOST[$key] != "") {
+                $this->save_file[$cnt] = $arrPOST[$key];
+            }
+            $cnt++;
+        }
+    }
+    
+    // ¥Õ¥©¡¼¥à¤ËÅÏ¤¹ÍÑ¤Î¥Õ¥¡¥¤¥ë¾ðÊóÇÛÎó¤òÊÖ¤¹
+    function getFormFileList($temp_url, $save_url, $real_size = false) {
+
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if($this->temp_file[$cnt] != "") {
+                // ¥Õ¥¡¥¤¥ë¥Ñ¥¹¥Á¥§¥Ã¥¯(¥Ñ¥¹¤Î¥¹¥é¥Ã¥·¥å/¤¬Ï¢Â³¤·¤Ê¤¤¤è¤¦¤Ë¤¹¤ë¡£)
+                if(ereg("/$", $temp_url)) {
+                    $arrRet[$val]['filepath'] = $temp_url . $this->temp_file[$cnt];
+                } else {
+                    $arrRet[$val]['filepath'] = $temp_url . "/" . $this->temp_file[$cnt];
+                }
+                $arrRet[$val]['real_filepath'] = $this->temp_dir . $this->temp_file[$cnt];
+            } elseif ($this->save_file[$cnt] != "") {
+                // ¥Õ¥¡¥¤¥ë¥Ñ¥¹¥Á¥§¥Ã¥¯(¥Ñ¥¹¤Î¥¹¥é¥Ã¥·¥å/¤¬Ï¢Â³¤·¤Ê¤¤¤è¤¦¤Ë¤¹¤ë¡£)
+                if(ereg("/$", $save_url)) {
+                    $arrRet[$val]['filepath'] = $save_url . $this->save_file[$cnt];
+                } else {
+                    $arrRet[$val]['filepath'] = $save_url . "/" . $this->save_file[$cnt];
+                }
+                $arrRet[$val]['real_filepath'] = $this->save_dir . $this->save_file[$cnt];
+            }
+            if($arrRet[$val]['filepath'] != "") {
+                if($real_size){
+                    if(is_file($arrRet[$val]['real_filepath'])) {
+                        list($width, $height) = getimagesize($arrRet[$val]['real_filepath']);
+                    }
+                    // ¥Õ¥¡¥¤¥ë²£Éý
+                    $arrRet[$val]['width'] = $width;
+                    // ¥Õ¥¡¥¤¥ë½ÄÉý
+                    $arrRet[$val]['height'] = $height;
+                }else{
+                    // ¥Õ¥¡¥¤¥ë²£Éý
+                    $arrRet[$val]['width'] = $this->width[$cnt];
+                    // ¥Õ¥¡¥¤¥ë½ÄÉý
+                    $arrRet[$val]['height'] = $this->height[$cnt];
+                }
+                // É½¼¨Ì¾
+                $arrRet[$val]['disp_name'] = $this->disp_name[$cnt];
+            }
+            $cnt++;
+        }
+        return $arrRet;
+    }
+    
+    // DBÊÝÂ¸ÍÑ¤Î¥Õ¥¡¥¤¥ëÌ¾ÇÛÎó¤òÊÖ¤¹
+    function getDBFileList() {
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if($this->temp_file[$cnt] != "") {
+                $arrRet[$val] = $this->temp_file[$cnt];
+            } else  {
+                $arrRet[$val] = $this->save_file[$cnt];
+            }
+            $cnt++;
+        }
+        return $arrRet;
+    }
+    
+    // DB¤ÇÊÝÂ¸¤µ¤ì¤¿¥Õ¥¡¥¤¥ëÌ¾ÇÛÎó¤ò¥»¥Ã¥È¤¹¤ë
+    function setDBFileList($arrVal) {
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if($arrVal[$val] != "") {
+                $this->save_file[$cnt] = $arrVal[$val];
+            }
+            $cnt++; 
+        }
+    }
+    
+    // ²èÁü¤ò¥»¥Ã¥È¤¹¤ë
+    function setDBImageList($arrVal) {
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if($arrVal[$val] != "" && $val == 'tv_products_image') {
+                $this->save_file[$cnt] = $arrVal[$val];
+            }
+            $cnt++; 
+        }
+    }
+    
+    // DB¾å¤Î¥Õ¥¡¥¤¥ë¤ÎÆâºï½üÍ×µá¤¬¤¢¤Ã¤¿¥Õ¥¡¥¤¥ë¤òºï½ü¤¹¤ë¡£ 
+    function deleteDBFile($arrVal) {
+        $objImage = new SC_Image($this->temp_dir);
+        $cnt = 0;
+        foreach($this->keyname as $val) {
+            if($arrVal[$val] != "") {
+                if($this->save_file[$cnt] == "" && !ereg("^sub/", $arrVal[$val])) {
+                    
+                    // Éé²ÙÊ¬»¶»þ¤Ï¤¹¤Ù¤Æ¤Î¥µ¡¼¥Ð¤Ç¥Õ¥¡¥¤¥ëºï½ü
+                    if($this->multi_web_server_mode === true) {
+                        $this->ftpDeleteFile($this->ftp_save_dir . $arrVal[$val]);
+                    } else {
+                        $objImage->deleteImage($arrVal[$val], $this->save_dir);
+                    }
+                }
+            }
+            $cnt++; 
+        }
+    }
+    
+    // É¬¿ÜÈ½Äê
+    function checkEXISTS($keyname = "") {
+        $cnt = 0;
+        $arrRet = array();
+        foreach($this->keyname as $val) {
+            if($val == $keyname || $keyname == "") {
+                // É¬¿Ü¤Ç¤¢¤ì¤Ð¥¨¥é¡¼¥Á¥§¥Ã¥¯
+                if ($this->necessary[$cnt] == true) {
+                    if($this->save_file[$cnt] == "" && $this->temp_file[$cnt] == "") {
+                        $arrRet[$val] = "¢¨ " . $this->disp_name[$cnt] . "¤¬¥¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤Æ¤¤¤Þ¤»¤ó¡£<br>";
+                    }
+                }
+            }
+            $cnt++;
+        }
+        return $arrRet;
+    }
+        
+    // ³ÈÂçÎ¨¤ò»ØÄê¤·¤Æ²èÁüÊÝÂ¸
+    function saveResizeImage($keyname, $to_w, $to_h) {
+        $path = "";
+        
+        // keyname¤ÎÅºÉÕ¥Õ¥¡¥¤¥ë¤ò¼èÆÀ
+        $arrImageKey = array_flip($this->keyname);
+        $file = $this->temp_file[$arrImageKey[$keyname]];
+        $filepath = $this->temp_dir . $file;
+        
+        $path = $this->makeThumb($filepath, $to_w, $to_h);
+        
+        // ¥Õ¥¡¥¤¥ëÌ¾¤À¤±ÊÖ¤¹
+        return basename($path);
+    }
+
+    /**         
+     * ¥Õ¥¡¥¤¥ë¤òÁ´¤Æ¤ÎWEB¥µ¡¼¥Ð¤Ø¥³¥Ô¡¼
+     *
+     * @param string $dst_path ¥³¥Ô¡¼Àè¥Õ¥¡¥¤¥ë¥Ñ¥¹(ÁêÂÐ¥Ñ¥¹)
+     * @param string $src_path ¥³¥Ô¡¼¸µ¥Õ¥¡¥¤¥ë¥Ñ¥¹(ÀäÂÐ¥Ñ¥¹)
+     * @param boolean $del_flag °ÜÆ°¥Õ¥¡¥¤¥ë¤òºï½ü¤¹¤ë¥Õ¥é¥°
+     * @return void
+     */
+    function ftpMoveFile($dst_path, $src_path, $del_flag = false) {
+        global $arrWEB_SERVERS;
+
+        // Á´¤Æ¤Î¥µ¡¼¥Ð¤Ë¥Õ¥¡¥¤¥ë¤ò¥³¥Ô¡¼¤¹¤ë
+        foreach($arrWEB_SERVERS as $array) {
+            sfFtpCopy($array['host'], $array['user'], $array['pass'], $dst_path, $src_path);
+        }
+        // °ÜÆ°¸å¤Ï¥Õ¥¡¥¤¥ë¤òºï½ü
+        if($del_flag === true) {
+            @unlink($src_path);
+        }
+    }
+
+    /**         
+     * ¥Õ¥¡¥¤¥ë¤òÁ´¤Æ¤ÎWEB¥µ¡¼¥Ð¾å¤«¤éºï½ü
+     *
+     * @param string $dst_path ¥³¥Ô¡¼Àè¥Õ¥¡¥¤¥ë¥Ñ¥¹(ÁêÂÐ¥Ñ¥¹)
+     * @return void
+     */
+    function ftpDeleteFile($dst_path) {
+        global $arrWEB_SERVERS;
+
+        // Á´¤Æ¤Î¥µ¡¼¥Ð¤Ë¥Õ¥¡¥¤¥ë¤ò¥³¥Ô¡¼¤¹¤ë
+        foreach($arrWEB_SERVERS as $array) {
+            sfFtpDelete($array['host'], $array['user'], $array['pass'], $dst_path);
+        }
+    }
+
+
+    /**
+     * FTPÍÑ¥Õ¥¡¥¤¥ë°ì»þ³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥êºîÀ®
+     *
+     * @param string $dir ºîÀ®¥Ç¥£¥ì¥¯¥È¥ê
+     * @return string $ftp_temp_dir ºîÀ®°ì»þ³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥ê¥Ñ¥¹
+     */
+    function makeFtpTempDir($dir) {
+        // FTPÍÑ¥Õ¥¡¥¤¥ë°ì»þ³ÊÇ¼ÍÑ¥Ç¥£¥ì¥¯¥È¥ê
+        $ftp_temp_dir = $this->temp_dir . "ftp_temp/";
+        // ¥Ç¥£¥ì¥¯¥È¥ê¤¬Â¸ºß¤·¤Ê¤«¤Ã¤¿¤éºîÀ®
+        if(!file_exists($ftp_temp_dir)) {
+            mkdir($ftp_temp_dir);
+            chmod($ftp_temp_dir, 0777);
+        }
+        
+        return $ftp_temp_dir;
+    }
 }
 ?>
Index: /branches/beta/data/conf/conf.php
===================================================================
--- /branches/beta/data/conf/conf.php	(revision 12224)
+++ /branches/beta/data/conf/conf.php	(revision 14676)
@@ -90,5 +90,4 @@
 // ¥¢¥Ã¥×¥Ç¡¼¥È´ÉÍýÍÑ¥Õ¥¡¥¤¥ë³ÊÇ¼¾ì½ê¡¡
 define("UPDATE_HTTP", "http://www.lockon.co.jp/share/");
-
 // ¥¢¥Ã¥×¥Ç¡¼¥È´ÉÍýÍÑCSV1¹ÔÊÕ¤ê¤ÎºÇÂçÊ¸»ú¿ô
 define("UPDATE_CSV_LINE_MAX", 4096);
@@ -97,4 +96,6 @@
 // ¥â¥¸¥å¡¼¥ë´ÉÍýÍÑCSV¥«¥é¥à¿ô
 define("MODULE_CSV_COL_MAX", 16);
+// ¥â¥¸¥å¡¼¥ë´ÉÍýÍÑCSV¥Õ¥¡¥¤¥ë
+define("MODULE_CSV", "module.txt");
 //--------------------------------------------------------------------------------------------------------
 
@@ -119,5 +120,5 @@
 
 // EC-CUBE¥Ð¡¼¥¸¥ç¥ó¾ðÊó
-define("ECCUBE_VERSION", "1.3.1-beta");
+define("ECCUBE_VERSION", "1.4.0a-beta");
 
 // ·èºÑ¥â¥¸¥å¡¼¥ëÉÕÍ¿Ê¸¸À
@@ -185,8 +186,9 @@
 define("REVIEW_REGIST_MAX", 5);
 
-/*
+/*F
  * ¥µ¥¤¥ÈÄêµÁÄê¿ô
  */
 /* ¥·¥¹¥Æ¥à´ØÏ¢ */
+define ('DEBUG_MODE', false);                          // ¥Ç¥Ð¥Ã¥°¥â¡¼¥É(true¡§sfPrintR¤äDB¤Î¥¨¥é¡¼¥á¥Ã¥»¡¼¥¸¤ò½ÐÎÏ¤¹¤ë¡¢false¡§½ÐÎÏ¤·¤Ê¤¤)
 define ("ADMIN_ID", "1");								// ´ÉÍý¥æ¡¼¥¶ID(¥á¥ó¥Æ¥Ê¥ó¥¹ÍÑÉ½¼¨¤µ¤ì¤Ê¤¤¡£)
 define ("CUSTOMER_CONFIRM_MAIL", false);				// ²ñ°÷ÅÐÏ¿»þ¤Ë²¾²ñ°÷³ÎÇ§¥á¡¼¥ë¤òÁ÷¿®¤¹¤ë¤«¡Êtrue:²¾²ñ°÷¡¢false:ËÜ²ñ°÷¡Ë
@@ -230,6 +232,10 @@
 
 /* ¥¯¥ì¥¸¥Ã¥È¥«¡¼¥É(¥Ù¥ê¥È¥é¥ó¥¹) */
-define ("CGI_DIR", HTML_PATH . "../cgi-bin/");									// ¥â¥¸¥å¡¼¥ë³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥ê
+define ("CGI_DIR", HTML_PATH . "../cgi-bin/");								// ¥â¥¸¥å¡¼¥ë³ÊÇ¼¥Ç¥£¥ì¥¯¥È¥ê
 define ("CGI_FILE", "mauthonly.cgi");										// ¥³¥¢CGI
+
+/* ¥Ö¥ì¥¤¥óSMTP¾ðÊó */
+// define ("SMTP_HOST_BLAYN", "210.188.254.83");					// ¥Ö¥ì¥¤¥óSMTP¥µ¡¼¥Ð
+define ("SMTP_PORT_BLAYN", 25);									// ¥Ö¥ì¥¤¥óSMTP¥Ý¡¼¥ÈÈÖ¹æ
 
 // ¥ë¡¼¥È¥«¥Æ¥´¥êID
@@ -289,4 +295,6 @@
 /* ¥·¥¹¥Æ¥à¥Ñ¥¹ */
 define ("LOG_PATH", DATA_PATH . "logs/site.log");							// ¥í¥°¥Õ¥¡¥¤¥ë
+define ("DB_ERR_LOG_PATH", DATA_PATH . "logs/db_err.log");                  // ¥í¥°¥Õ¥¡¥¤¥ë(DB¥¨¥é¡¼ÍÑ)
+define ("DEBUG_LOG_PATH", DATA_PATH . "logs/debug.log");                    // ¥í¥°¥Õ¥¡¥¤¥ë(DEBUGÍÑ)
 define ("CUSTOMER_LOG_PATH", DATA_PATH . "logs/customer.log");				// ²ñ°÷¥í¥°¥¤¥ó ¥í¥°¥Õ¥¡¥¤¥ë
 define ("TEMPLATE_ADMIN_DIR", DATA_PATH . "Smarty/templates/admin");		// SMARTY¥Æ¥ó¥×¥ì¡¼¥È
@@ -295,5 +303,5 @@
 define ("COMPILE_DIR", DATA_PATH . "Smarty/templates_c");					// SMARTY¥³¥ó¥Ñ¥¤¥ë
 
-define ("TEMPLATE_FTP_DIR", USER_PATH . "templates/");			// SMARTY¥Æ¥ó¥×¥ì¡¼¥È(FTPµö²Ä)
+define ("TEMPLATE_FTP_DIR", USER_PATH . "templates/");                      // SMARTY¥Æ¥ó¥×¥ì¡¼¥È(FTPµö²Ä)
 define ("COMPILE_FTP_DIR", DATA_PATH . "Smarty/templates_c/user_data/");	// SMARTY¥³¥ó¥Ñ¥¤¥ë
 
@@ -304,4 +312,6 @@
 define ("IMAGE_TEMP_URL_RSS", SITE_URL . "upload/temp_image/");				// RSSÍÑ²èÁü°ì»þÊÝÂ¸URL
 define ("IMAGE_SAVE_URL_RSS", SITE_URL . "upload/save_image/");				// RSSÍÑ²èÁüÊÝÂ¸ÀèURL
+define ("FTP_IMAGE_SAVE_DIR", "./html" . URL_DIR . "upload/save_image/");   // FTP²èÁüÊÝÂ¸(ÁêÂÐ¥Ñ¥¹)
+define ("FTP_IMAGE_TEMP_DIR", "./html" . URL_DIR . "upload/temp_image/");   // FTP²èÁü°ì»þÊÝÂ¸(ÁêÂÐ¥Ñ¥¹)
 define ("CSV_TEMP_DIR", HTML_PATH . "upload/csv/");							// ¥¨¥ó¥³¡¼¥ÉCSV¤Î°ì»þÊÝÂ¸Àè
 define ("NO_IMAGE_URL", URL_DIR . "misc/blank.gif");						// ²èÁü¤¬¤Ê¤¤¾ì¹ç¤ËÉ½¼¨
@@ -579,15 +589,16 @@
 // ¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È¤Î¼ïÎà
 $arrMAILTEMPLATE = array(
-	 1 => "ÃíÊ¸¼õÉÕ¥á¡¼¥ë"
-	,2 => "ÃíÊ¸¥­¥ã¥ó¥»¥ë¼õÉÕ¥á¡¼¥ë"
-	,3 => "¼è¤ê´ó¤»³ÎÇ§¥á¡¼¥ë"
+	 1 => "PC¡§ÃíÊ¸¼õÉÕ¥á¡¼¥ë"
+	,2 => "PC¡§ÃíÊ¸¥­¥ã¥ó¥»¥ë¼õÉÕ¥á¡¼¥ë"
+	,3 => "PC¡§¼è¤ê´ó¤»³ÎÇ§¥á¡¼¥ë"
+	,4 => "·ÈÂÓ¡§ÃíÊ¸¼õÉÕ¥á¡¼¥ë"
+	,5 => "·ÈÂÓ¡§ÃíÊ¸¥­¥ã¥ó¥»¥ë¼õÉÕ¥á¡¼¥ë"
+	,6 => "·ÈÂÓ¡§¼è¤ê´ó¤»³ÎÇ§¥á¡¼¥ë"
 );
 
 // ³Æ¥Æ¥ó¥×¥ì¡¼¥È¤Î¥Ñ¥¹
 $arrMAILTPLPATH = array(
-	1 => "mail_templates/order_mail.tpl",
-	2 => "mail_templates/order_mail.tpl",
-	3 => "mail_templates/order_mail.tpl",
-	4 => "mail_templates/contact_mail.tpl",
+	0 => "mail_templates/order_mail.tpl",
+    1 => "mobile/mail_templates/order_mail.tpl"
 );
 
@@ -667,5 +678,5 @@
 /* ¥Ñ¥¹¥ï¡¼¥É¤ÎÅú¤¨ÇÛÎó */
 $arrReminder = array(
-						1 => "Êì¿Æ¤ÎµìÀ«¤Ï¡©",
+						1 => "¿Æ¤ÎµìÀ«¤Ï¡©",
 						2 => "¤ªµ¤¤ËÆþ¤ê¤Î¥Þ¥ó¥¬¤Ï¡©",
 						3 => "Âç¹¥¤­¤Ê¥Ú¥Ã¥È¤ÎÌ¾Á°¤Ï¡©",
@@ -685,8 +696,34 @@
 define ("MAIL_TYPE_MOBILE",2);
 $arrMailType = array(
-					MAIL_TYPE_PC => "¥Ñ¥½¥³¥óÍÑ¥¢¥É¥ì¥¹",
-					MAIL_TYPE_MOBILE => "·ÈÂÓÍÑ¥¢¥É¥ì¥¹",
-				);		
+					MAIL_TYPE_PC => "¥Ñ¥½¥³¥óÍÑ¥á¡¼¥ë¥¢¥É¥ì¥¹",
+					MAIL_TYPE_MOBILE => "·ÈÂÓÍÑ¥á¡¼¥ë¥¢¥É¥ì¥¹"
+				);	
+
+/*  ·ÈÂÓ¥É¥á¥¤¥ó»ØÄê¡¡*/
+$arrDOMAIN = array(
+                        1 => "PC¥É¥á¥¤¥ó",
+                        2 => "·ÈÂÓ¥É¥á¥¤¥ó"
+                    );
 				
+
+$arrDomainType = array(
+                      1 => "@docomo.ne.jp",
+                      2 => "@ezweb.ne.jp",
+                      3 => "@softbank.ne.jp",
+                      4 => "@t.vodafone.ne.jp",
+                      5 => "@d.vodafone.ne.jp",
+                      6 => "@h.vodafone.ne.jp",
+                      7 => "@c.vodafone.ne.jp",
+                      8 => "@k.vodafone.ne.jp",
+                      9 => "@r.vodafone.ne.jp",
+                      10 => "@n.vodafone.ne.jp",
+                      11 => "@s.vodafone.ne.jp",
+                      12 => "@q.vodafone.ne.jp",
+                      13 => "@pdx.ne.jp",
+                      14 => "@di.pdx.ne.jp",
+                      15 => "@dj.pdx.ne.jp",
+                      16 => "@dk.pdx.ne.jp",
+                      17 => "@wm.pdx.ne.jp"
+                  );				
 				
 /*¡¡1¹Ô¿ô¡¡*/		
@@ -884,4 +921,5 @@
 
 // ViewÊÑ´¹ÍÑ(MySQLÂÐ±þ)
+
 $arrView = array(
 	"vw_cross_class" => '
@@ -895,84 +933,4 @@
 		FROM dtb_classcategory AS T1, dtb_classcategory AS T2 ) AS T1 LEFT JOIN dtb_products_class AS T2 
 		ON T1.classcategory_id1 = T2.classcategory_id1 AND T1.classcategory_id2 = T2.classcategory_id2) ',
-
-	"vw_products_nonclass" => '
-		(SELECT 
-		    T1.product_id,
-		    T1.name,
-		    T1.deliv_fee,
-		    T1.sale_limit,
-		    T1.sale_unlimited,
-		    T1.category_id,
-		    T1.rank,
-		    T1.status,
-		    T1.product_flag,
-		    T1.point_rate,
-		    T1.comment1,
-		    T1.comment2,
-		    T1.comment3,
-		    T1.comment4,
-		    T1.comment5,
-		    T1.comment6,
-		    T1.file1,
-		    T1.file2,
-		    T1.file3,
-		    T1.file4,
-		    T1.file5,
-		    T1.file6,
-		    T1.main_list_comment,
-		    T1.main_list_image,
-		    T1.main_comment,
-		    T1.main_image,
-		    T1.main_large_image,
-		    T1.sub_title1,
-		    T1.sub_comment1,
-		    T1.sub_image1,
-		    T1.sub_large_image1,
-		    T1.sub_title2,
-		    T1.sub_comment2,
-		    T1.sub_image2,
-		    T1.sub_large_image2,
-		    T1.sub_title3,
-		    T1.sub_comment3,
-		    T1.sub_image3,
-		    T1.sub_large_image3,
-		    T1.sub_title4,
-		    T1.sub_comment4,
-		    T1.sub_image4,
-		    T1.sub_large_image4,
-		    T1.sub_title5,
-		    T1.sub_comment5,
-		    T1.sub_image5,
-		    T1.sub_large_image5,
-		    T1.sub_title6,
-		    T1.sub_comment6,
-		    T1.sub_image6,
-		    T1.sub_large_image6,
-		    T1.del_flg,
-		    T1.creator_id,
-		    T1.create_date,
-		    T1.update_date,
-		    T1.deliv_date_id,
-		    T2.product_id_sub,
-		    T2.product_code,
-		    T2.price01,
-		    T2.price02,
-		    T2.stock,
-		    T2.stock_unlimited,
-		    T2.classcategory_id1,
-		    T2.classcategory_id2
-		FROM (SELECT * FROM dtb_products &&noncls_where&&) AS T1 LEFT JOIN 
-		(SELECT
-		product_id AS product_id_sub,
-		product_code,
-		price01,
-		price02,
-		stock,
-		stock_unlimited,
-		classcategory_id1,
-		classcategory_id2
-		FROM dtb_products_class WHERE classcategory_id1 = 0 AND classcategory_id2 = 0) 
-		AS T2
-		ON T1.product_id = T2.product_id_sub) ',
 
 	"vw_products_allclass" => '
@@ -1065,3 +1023,70 @@
 );
 
+$vw_products_nonclass = "
+		(SELECT 
+		    T1.product_id,
+		    T1.name,
+		    T1.deliv_fee,
+		    T1.sale_limit,
+		    T1.sale_unlimited,
+		    T1.category_id,
+		    T1.rank,
+		    T1.status,
+		    T1.product_flag,
+		    T1.point_rate,
+		    T1.comment1,
+		    T1.comment2,
+		    T1.comment3,
+		    T1.comment4,
+		    T1.comment5,
+		    T1.comment6,
+		    T1.file1,
+		    T1.file2,
+		    T1.file3,
+		    T1.file4,
+		    T1.file5,
+		    T1.file6,
+		    T1.main_list_comment,
+		    T1.main_list_image,
+		    T1.main_comment,
+		    T1.main_image,
+		    T1.main_large_image,";
+            
+for ($cnt = 1; $cnt <= PRODUCTSUB_MAX; $cnt++) {
+            $vw_products_nonclass.= "
+		    T1.sub_title$cnt,
+		    T1.sub_comment$cnt,
+		    T1.sub_image$cnt,
+            T1.sub_large_image$cnt,";
+}
+
+$vw_products_nonclass.= "
+		    T1.del_flg,
+		    T1.creator_id,
+		    T1.create_date,
+		    T1.update_date,
+		    T1.deliv_date_id,
+		    T2.product_id_sub,
+		    T2.product_code,
+		    T2.price01,
+		    T2.price02,
+		    T2.stock,
+		    T2.stock_unlimited,
+		    T2.classcategory_id1,
+		    T2.classcategory_id2
+		FROM (SELECT * FROM dtb_products &&noncls_where&&) AS T1 LEFT JOIN 
+		(SELECT
+		product_id AS product_id_sub,
+		product_code,
+		price01,
+		price02,
+		stock,
+		stock_unlimited,
+		classcategory_id1,
+		classcategory_id2
+		FROM dtb_products_class WHERE classcategory_id1 = 0 AND classcategory_id2 = 0) 
+		AS T2
+		ON T1.product_id = T2.product_id_sub) ";
+
+$arrView['vw_products_nonclass'] = $vw_products_nonclass;
 ?>
Index: /branches/beta/data/conf/core.php
===================================================================
--- /branches/beta/data/conf/core.php	(revision 321)
+++ /branches/beta/data/conf/core.php	(revision 14676)
@@ -31,3 +31,20 @@
 define ("AUTH_MAGIC", "31eafcbd7a81d7b401a7fdc12bba047c02d1fae6");
 
+//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
+// WEBÉé²ÙÊ¬»¶ÀßÄê
+
+define ("MULTI_WEB_SERVER_MODE", false);    // Éé²ÙÊ¬»¶¥â¡¼¥É(true:ON false:OFF)
+
+/*
+ *  host:IP¥¢¥É¥ì¥¹¤Ç»ØÄê¤¹¤ë¡£
+ *  user:FTP¥æ¡¼¥¶
+ *  pass:FTP¥Ñ¥¹¥ï¡¼¥É
+ */
+$arrWEB_SERVERS = array(
+    array('host_name' => 'web1', 'host' => '127.0.0.1',   'user' => 'users', 'pass' => 'pass'),        // WEB¥µ¡¼¥Ð1
+    array('host_name' => 'web2', 'host' => 'host2',   'user' => 'users', 'pass' => 'pass'),        // WEB¥µ¡¼¥Ð2
+);
+//////////////////////////////////////////////////////////////////////////////////?///////////////////////////////////////////
+
+
 ?>
Index: /branches/beta/data/module/Auth/Auth.php
===================================================================
--- /branches/beta/data/module/Auth/Auth.php	(revision 14676)
+++ /branches/beta/data/module/Auth/Auth.php	(revision 14676)
@@ -0,0 +1,1266 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4 foldmethod=marker: */
+
+/**
+ * The main include file for Auth package
+ *
+ * PHP versions 4 and 5
+ *
+ * LICENSE: This source file is subject to version 3.01 of the PHP license
+ * that is available through the world-wide-web at the following URI:
+ * http://www.php.net/license/3_01.txt.  If you did not receive a copy of
+ * the PHP License and are unable to obtain it through the web, please
+ * send a note to license@php.net so we can mail you a copy immediately.
+ *
+ * @category   Authentication
+ * @package    Auth
+ * @author     Martin Jansen <mj@php.net>
+ * @author     Adam Ashley <aashley@php.net>
+ * @copyright  2001-2006 The PHP Group
+ * @license    http://www.php.net/license/3_01.txt  PHP License 3.01
+ * @version    CVS: $Id: Auth.php,v 1.115 2007/02/02 00:41:14 aashley Exp $
+ * @link       http://pear.php.net/package/Auth
+ */
+
+/**
+ * Returned if session exceeds idle time
+ */
+define('AUTH_IDLED',                    -1);
+/**
+ * Returned if session has expired
+ */
+define('AUTH_EXPIRED',                  -2);
+/** 
+ * Returned if container is unable to authenticate user/password pair
+ */
+define('AUTH_WRONG_LOGIN',              -3);
+/**
+ * Returned if a container method is not supported.
+ */
+define('AUTH_METHOD_NOT_SUPPORTED',     -4);
+/**
+ * Returned if new Advanced security system detects a breach
+ */
+define('AUTH_SECURITY_BREACH',          -5);
+/**
+ * Returned if checkAuthCallback says session should not continue.
+ */
+define('AUTH_CALLBACK_ABORT',           -6);
+
+/**
+ * Auth Log level - INFO
+ */
+define('AUTH_LOG_INFO',     6);
+/**
+ * Auth Log level - DEBUG
+ */
+define('AUTH_LOG_DEBUG',    7);
+
+
+/**
+ * PEAR::Auth
+ *
+ * The PEAR::Auth class provides methods for creating an
+ * authentication system using PHP.
+ *
+ * @category   Authentication
+ * @package    Auth
+ * @author     Martin Jansen <mj@php.net>
+ * @author     Adam Ashley <aashley@php.net>
+ * @copyright  2001-2006 The PHP Group
+ * @license    http://www.php.net/license/3_01.txt  PHP License 3.01
+ * @version    Release: 1.5.1  File: $Revision: 1.115 $
+ * @link       http://pear.php.net/package/Auth
+ */
+class Auth {
+
+    // {{{ properties
+
+    /**
+     * Auth lifetime in seconds
+     *
+     * If this variable is set to 0, auth never expires
+     *
+     * @var  integer
+     * @see  setExpire(), checkAuth()
+     */
+    var $expire = 0;
+
+    /**
+     * Has the auth session expired?
+     *
+     * @var   bool
+     * @see   checkAuth()
+     */
+    var $expired = false;
+
+    /**
+     * Maximum idletime in seconds
+     *
+     * The difference to $expire is, that the idletime gets
+     * refreshed each time checkAuth() is called. If this
+     * variable is set to 0, idletime is never checked.
+     *
+     * @var integer
+     * @see setIdle(), checkAuth()
+     */
+    var $idle = 0;
+
+    /**
+     * Is the maximum idletime over?
+     *
+     * @var boolean
+     * @see checkAuth()
+     */
+    var $idled = false;
+
+    /**
+     * Storage object
+     *
+     * @var object
+     * @see Auth(), validateLogin()
+     */
+    var $storage = '';
+
+    /**
+     * User-defined function that creates the login screen
+     *
+     * @var string
+     */
+    var $loginFunction = '';
+
+    /**
+     * Should the login form be displayed
+     *
+     * @var   bool
+     * @see   setShowlogin()
+     */
+    var $showLogin = true;
+    
+    /**
+      * Is Login Allowed from this page
+      *
+      * @var  bool
+      * @see setAllowLogin
+      */
+    var $allowLogin = true;
+
+    /**
+     * Current authentication status
+     *
+     * @var string
+     */
+    var $status = '';
+
+    /**
+     * Username
+     *
+     * @var string
+     */
+    var $username = '';
+
+    /**
+     * Password
+     *
+     * @var string
+     */
+    var $password = '';
+
+    /**
+     * checkAuth callback function name
+     *
+     * @var string
+     * @see setCheckAuthCallback()
+     */
+    var $checkAuthCallback = '';
+
+    /**
+     * Login callback function name
+     *
+     * @var string
+     * @see setLoginCallback()
+     */
+    var $loginCallback = '';
+
+    /**
+     * Failed Login callback function name
+     *
+     * @var string
+     * @see setFailedLoginCallback()
+     */
+    var $loginFailedCallback = '';
+
+    /**
+     * Logout callback function name
+     *
+     * @var string
+     * @see setLogoutCallback()
+     */
+    var $logoutCallback = '';
+
+    /**
+     * Auth session-array name
+     *
+     * @var string
+     */
+    var $_sessionName = '_authsession';
+
+    /**
+     * Package Version
+     *
+     * @var string
+     */
+    var $version = "@version@";
+
+    /**
+     * Flag to use advanced security
+     * When set extra checks will be made to see if the 
+     * user's IP or useragent have changed across requests. 
+     * Turned off by default to preserve BC.
+     *
+     * @var boolean
+     */     
+    var $advancedsecurity = false;
+
+    /**
+     * Username key in POST array
+     *
+     * @var string
+     */
+    var $_postUsername = 'username';
+
+    /**
+     * Password key in POST array
+     *
+     * @var string
+     */
+    var $_postPassword = 'password';
+
+    /**
+     * Holds a reference to the session auth variable
+     * @var array
+     */
+    var $session;
+
+    /**
+     * Holds a reference to the global server variable
+     * @var array
+     */
+    var $server;
+
+    /**
+     * Holds a reference to the global post variable
+     * @var array
+     */
+    var $post;
+
+    /**
+     * Holds a reference to the global cookie variable
+     * @var array
+     */
+    var $cookie;
+
+    /**
+     * A hash to hold various superglobals as reference
+     * @var array
+     */
+    var $authdata;
+    
+    /**
+      * How many times has checkAuth been called
+      * @var int
+      */
+    var $authChecks = 0;
+
+    /**
+     * PEAR::Log object
+     *
+     * @var object Log
+     */
+    var $logger = null;
+
+    /**
+     * Whether to enable logging of behaviour
+     *
+     * @var boolean
+     */
+    var $enableLogging = false;
+
+    // }}}
+    // {{{ Auth() [constructor]
+
+    /**
+     * Constructor
+     *
+     * Set up the storage driver.
+     *
+     * @param string    Type of the storage driver
+     * @param mixed     Additional options for the storage driver
+     *                  (example: if you are using DB as the storage
+     *                   driver, you have to pass the dsn string here)
+     *
+     * @param string    Name of the function that creates the login form
+     * @param boolean   Should the login form be displayed if neccessary?
+     * @return void
+     */
+    function Auth($storageDriver, $options = '', $loginFunction = '', $showLogin = true)
+    {
+        $this->applyAuthOptions($options);
+
+        // Start the session suppress error if already started
+        if(!session_id()){
+            @session_start();
+            if(!session_id()) {
+                // Throw error
+                include_once 'PEAR.php';
+                PEAR::throwError('Session could not be started by Auth, '
+                        .'possibly headers are already sent, try putting '
+                        .'ob_start in the beginning of your script');
+            }
+        }
+
+        // Make Sure Auth session variable is there
+        if(!isset($_SESSION[$this->_sessionName])) {
+            $_SESSION[$this->_sessionName] = array();
+        }
+
+        // Assign Some globals to internal references, this will replace _importGlobalVariable
+        $this->session =& $_SESSION[$this->_sessionName];
+        $this->server =& $_SERVER;
+        $this->post =& $_POST;
+        $this->cookie =& $_COOKIE;
+
+        if ($loginFunction != '' && is_callable($loginFunction)) {
+            $this->loginFunction = $loginFunction;
+        }
+
+        if (is_bool($showLogin)) {
+            $this->showLogin = $showLogin;
+        }
+
+        if (is_object($storageDriver)) {
+            $this->storage =& $storageDriver;
+            // Pass a reference to auth to the container, ugly but works
+            // this is used by the DB container to use method setAuthData not staticaly.
+            $this->storage->_auth_obj =& $this;
+        } else {
+            // $this->storage = $this->_factory($storageDriver, $options);
+            // 
+            $this->storage_driver = $storageDriver;
+            $this->storage_options =& $options;
+        }
+    }
+
+    // }}}
+    // {{{ applyAuthOptions()
+
+    /**
+      * Set the Auth options 
+      *
+      * Some options which are Auth specific will be applied
+      * the rest will be left for usage by the container
+      * 
+      * @param array    An array of Auth options
+      * @return array   The options which were not applied
+      * @access private
+      */
+    function &applyAuthOptions(&$options)
+    {
+        if(is_array($options)){
+            if (!empty($options['sessionName'])) {
+                $this->_sessionName = $options['sessionName'];
+                unset($options['sessionName']);
+            }
+            if (isset($options['allowLogin'])) {
+                $this->allowLogin = $options['allowLogin'];
+                unset($options['allowLogin']);
+            }
+            if (!empty($options['postUsername'])) {
+                $this->_postUsername = $options['postUsername'];
+                unset($options['postUsername']);
+            }
+            if (!empty($options['postPassword'])) {
+                $this->_postPassword = $options['postPassword'];
+                unset($options['postPassword']);
+            }
+            if (isset($options['advancedsecurity'])) {
+                $this->advancedsecurity = $options['advancedsecurity'];
+                unset($options['advancedsecurity']);
+            }
+            if (isset($options['enableLogging'])) {
+                $this->enableLogging = $options['enableLogging'];
+                unset($options['enableLogging']);
+            }
+        }
+        return($options);
+    }
+
+    // }}}
+    // {{{ _loadStorage()
+    
+    /**
+      * Load Storage Driver if not already loaded
+      *
+      * Suspend storage instantiation to make Auth lighter to use 
+      * for calls which do not require login
+      *
+      * @return bool    True if the conainer is loaded, false if the container
+      *                 is already loaded
+      * @access private
+      */
+    function _loadStorage()
+    {
+        if(!is_object($this->storage)) {
+            $this->storage =& $this->_factory($this->storage_driver, 
+                    $this->storage_options);
+            $this->storage->_auth_obj =& $this;
+            $this->log('Loaded storage container ('.$this->storage_driver.')', AUTH_LOG_DEBUG);
+            return(true);
+        }
+        return(false);
+    }
+
+    // }}}
+    // {{{ _factory()
+
+    /**
+     * Return a storage driver based on $driver and $options
+     *
+     * @static
+     * @param  string $driver  Type of storage class to return
+     * @param  string $options Optional parameters for the storage class
+     * @return object Object   Storage object
+     * @access private
+     */
+    function &_factory($driver, $options = '')
+    {
+        $storage_class = 'Auth_Container_' . $driver;
+        include_once 'Auth/Container/' . $driver . '.php';
+        $obj =& new $storage_class($options);
+        return $obj;
+    }
+
+    // }}}
+    // {{{ assignData()
+
+    /**
+     * Assign data from login form to internal values
+     *
+     * This function takes the values for username and password
+     * from $HTTP_POST_VARS/$_POST and assigns them to internal variables.
+     * If you wish to use another source apart from $HTTP_POST_VARS/$_POST,
+     * you have to derive this function.
+     *
+     * @global $HTTP_POST_VARS, $_POST
+     * @see    Auth
+     * @return void
+     * @access private
+     */
+    function assignData()
+    {
+        $this->log('Auth::assignData() called.', AUTH_LOG_DEBUG);
+
+        if (   isset($this->post[$this->_postUsername]) 
+            && $this->post[$this->_postUsername] != '') {
+            $this->username = (get_magic_quotes_gpc() == 1 
+                    ? stripslashes($this->post[$this->_postUsername]) 
+                    : $this->post[$this->_postUsername]);
+        }
+        if (   isset($this->post[$this->_postPassword]) 
+            && $this->post[$this->_postPassword] != '') {
+            $this->password = (get_magic_quotes_gpc() == 1 
+                    ? stripslashes($this->post[$this->_postPassword]) 
+                    : $this->post[$this->_postPassword] );
+        }
+    }
+
+    // }}}
+    // {{{ start()
+
+    /**
+     * Start new auth session
+     *
+     * @return void
+     * @access public
+     */
+    function start()
+    {
+        $this->log('Auth::start() called.', AUTH_LOG_DEBUG);
+
+        $this->assignData();
+        if (!$this->checkAuth() && $this->allowLogin) {
+            $this->login();
+        }
+    }
+
+    // }}}
+    // {{{ login()
+
+    /**
+     * Login function
+     *
+     * @return void
+     * @access private
+     */
+    function login()
+    {
+        $this->log('Auth::login() called.', AUTH_LOG_DEBUG);
+
+        $login_ok = false;
+        $this->_loadStorage();
+        
+        // Check if using challenge response
+        (isset($this->post['authsecret']) && $this->post['authsecret'] == 1) 
+            ? $usingChap = true 
+            : $usingChap = false;
+
+        
+        // When the user has already entered a username, we have to validate it.
+        if (!empty($this->username)) {
+            if (true === $this->storage->fetchData($this->username, $this->password, $usingChap)) {
+                $this->session['challengekey'] = md5($this->username.$this->password);
+                $login_ok = true;
+                $this->log('Successful login.', AUTH_LOG_INFO);
+            }
+        }
+
+        if (!empty($this->username) && $login_ok) {
+            $this->setAuth($this->username);
+            if (is_callable($this->loginCallback)) {
+                $this->log('Calling loginCallback ('.$this->loginCallback.').', AUTH_LOG_DEBUG);
+                call_user_func_array($this->loginCallback, array($this->username, &$this));
+            }
+        }
+
+        // If the login failed or the user entered no username, 
+        // output the login screen again.
+        if (!empty($this->username) && !$login_ok) {
+            $this->log('Incorrect login.', AUTH_LOG_INFO);
+            $this->status = AUTH_WRONG_LOGIN;
+            if (is_callable($this->loginFailedCallback)) {
+                $this->log('Calling loginFailedCallback ('.$this->loginFailedCallback.').', AUTH_LOG_DEBUG);
+                call_user_func_array($this->loginFailedCallback, array($this->username, &$this));
+            }
+        }
+
+        if ((empty($this->username) || !$login_ok) && $this->showLogin) {
+            $this->log('Rendering Login Form.', AUTH_LOG_INFO);
+            if (is_callable($this->loginFunction)) {
+                $this->log('Calling loginFunction ('.$this->loginFunction.').', AUTH_LOG_DEBUG);
+                call_user_func_array($this->loginFunction, array($this->username, $this->status, &$this));
+            } else {
+                // BC fix Auth used to use drawLogin for this
+                // call is sub classes implement this
+                if (is_callable(array($this, 'drawLogin'))) {
+                    $this->log('Calling Auth::drawLogin()', AUTH_LOG_DEBUG);
+                    return $this->drawLogin($this->username, $this);
+                }
+
+                $this->log('Using default Auth_Frontend_Html', AUTH_LOG_DEBUG);
+
+                // New Login form
+                include_once 'Auth/Frontend/Html.php';
+                return Auth_Frontend_Html::render($this, $this->username);
+            }
+        } else {
+            return;
+        }
+    }
+
+    // }}}
+    // {{{ setExpire()
+
+    /**
+     * Set the maximum expire time
+     *
+     * @param  integer time in seconds
+     * @param  bool    add time to current expire time or not
+     * @return void
+     * @access public
+     */
+    function setExpire($time, $add = false)
+    {
+        $add ? $this->expire += $time : $this->expire = $time;
+    }
+
+    // }}}
+    // {{{ setIdle()
+
+    /**
+     * Set the maximum idle time
+     *
+     * @param  integer time in seconds
+     * @param  bool    add time to current maximum idle time or not
+     * @return void
+     * @access public
+     */
+    function setIdle($time, $add = false)
+    {
+        $add ? $this->idle += $time : $this->idle = $time;
+    }
+
+    // }}}
+    // {{{ setSessionName()
+
+    /**
+     * Set name of the session to a customized value.
+     *
+     * If you are using multiple instances of PEAR::Auth
+     * on the same domain, you can change the name of
+     * session per application via this function.
+     * This will chnage the name of the session variable 
+     * auth uses to store it's data in the session
+     *
+     * @param  string New name for the session
+     * @return void
+     * @access public
+     */
+    function setSessionName($name = 'session')
+    {
+        $this->_sessionName = '_auth_'.$name;
+        $this->session =& $_SESSION[$this->_sessionName];
+    }
+
+    // }}}
+    // {{{ setShowLogin()
+
+    /**
+     * Should the login form be displayed if neccessary?
+     *
+     * @param  bool    show login form or not
+     * @return void
+     * @access public
+     */
+    function setShowLogin($showLogin = true)
+    {
+        $this->showLogin = $showLogin;
+    }
+
+    // }}}
+    // {{{ setAllowLogin()
+
+    /**
+     * Should the login form be displayed if neccessary?
+     *
+     * @param  bool    show login form or not
+     * @return void
+     * @access public
+     */
+    function setAllowLogin($allowLogin = true)
+    {
+        $this->allowLogin = $allowLogin;
+    }
+
+    // }}}
+    // {{{ setCheckAuthCallback()
+
+    /**
+     * Register a callback function to be called whenever the validity of the login is checked
+     * The function will receive two parameters, the username and a reference to the auth object.
+     *
+     * @param  string  callback function name
+     * @return void
+     * @access public
+     * @since Method available since Release 1.4.3
+     */
+    function setCheckAuthCallback($checkAuthCallback)
+    {
+        $this->checkAuthCallback = $checkAuthCallback;
+    }
+
+    // }}}
+    // {{{ setLoginCallback()
+    
+    /**
+     * Register a callback function to be called on user login.
+     * The function will receive two parameters, the username and a reference to the auth object.
+     *
+     * @param  string  callback function name
+     * @return void
+     * @see    setLogoutCallback()
+     * @access public
+     */
+    function setLoginCallback($loginCallback)
+    {
+        $this->loginCallback = $loginCallback;
+    }
+
+    // }}}
+    // {{{ setFailedLoginCallback()
+
+    /**
+     * Register a callback function to be called on failed user login.
+     * The function will receive two parameters, the username and a reference to the auth object.
+     *
+     * @param  string  callback function name
+     * @return void
+     * @access public
+     */
+    function setFailedLoginCallback($loginFailedCallback)
+    {
+        $this->loginFailedCallback = $loginFailedCallback;
+    }
+
+    // }}}
+    // {{{ setLogoutCallback()
+
+    /**
+     * Register a callback function to be called on user logout.
+     * The function will receive three parameters, the username and a reference to the auth object.
+     *
+     * @param  string  callback function name
+     * @return void
+     * @see    setLoginCallback()
+     * @access public
+     */
+    function setLogoutCallback($logoutCallback)
+    {
+        $this->logoutCallback = $logoutCallback;
+    }
+
+    // }}}
+    // {{{ setAuthData()
+
+    /**
+     * Register additional information that is to be stored
+     * in the session.
+     *
+     * @param  string  Name of the data field
+     * @param  mixed   Value of the data field
+     * @param  boolean Should existing data be overwritten? (default
+     *                 is true)
+     * @return void
+     * @access public
+     */
+    function setAuthData($name, $value, $overwrite = true)
+    {
+        if (!empty($this->session['data'][$name]) && $overwrite == false) {
+            return;
+        }
+        $this->session['data'][$name] = $value;
+    }
+
+    // }}}
+    // {{{ getAuthData()
+
+    /**
+     * Get additional information that is stored in the session.
+     *
+     * If no value for the first parameter is passed, the method will
+     * return all data that is currently stored.
+     *
+     * @param  string Name of the data field
+     * @return mixed  Value of the data field.
+     * @access public
+     */
+    function getAuthData($name = null)
+    {
+        if (!isset($this->session['data'])) {
+            return null;
+        }    
+        if(!isset($name)) {
+            return $this->session['data'];
+        }
+        if (isset($name) && isset($this->session['data'][$name])) {
+            return $this->session['data'][$name];
+        }
+        return null;        
+    }
+
+    // }}}
+    // {{{ setAuth()
+
+    /**
+     * Register variable in a session telling that the user
+     * has logged in successfully
+     *
+     * @param  string Username
+     * @return void
+     * @access public
+     */
+    function setAuth($username)
+    {
+        $this->log('Auth::setAuth() called.', AUTH_LOG_DEBUG);
+    
+        // #2021 - Change the session id to avoid session fixation attacks php 4.3.3 > 
+        session_regenerate_id(true);
+
+        if (!isset($this->session) || !is_array($this->session)) {
+            $this->session = array();
+        }
+
+        if (!isset($this->session['data'])) {
+            $this->session['data'] = array();
+        }
+
+        $this->session['sessionip'] = isset($this->server['REMOTE_ADDR']) 
+            ? $this->server['REMOTE_ADDR'] 
+            : '';
+        $this->session['sessionuseragent'] = isset($this->server['HTTP_USER_AGENT']) 
+            ? $this->server['HTTP_USER_AGENT'] 
+            : '';
+        $this->session['sessionforwardedfor'] = isset($this->server['HTTP_X_FORWARDED_FOR']) 
+            ? $this->server['HTTP_X_FORWARDED_FOR'] 
+            : '';
+
+        // This should be set by the container to something more safe
+        // Like md5(passwd.microtime)
+        if(empty($this->session['challengekey'])) {
+            $this->session['challengekey'] = md5($username.microtime());
+        }
+
+        $this->session['challengecookie'] = md5($this->session['challengekey'].microtime());
+        setcookie('authchallenge', $this->session['challengecookie']);
+
+        $this->session['registered'] = true;
+        $this->session['username']   = $username;
+        $this->session['timestamp']  = time();
+        $this->session['idle']       = time();
+    }
+
+    // }}}
+    // {{{ setAdvancedSecurity()
+    
+    /**
+      * Enables advanced security checks
+      *
+      * Currently only ip change and useragent change 
+      * are detected
+      * @todo Add challenge cookies - Create a cookie which changes every time 
+      *       and contains some challenge key which the server can verify with
+      *       a session var cookie might need to be crypted (user pass)
+      * @param bool Enable or disable
+      * @return void
+      * @access public
+      */
+    function setAdvancedSecurity($flag=true)
+    {
+        $this->advancedsecurity = $flag;
+    }
+
+    // }}}
+    // {{{ checkAuth()
+
+    /**
+     * Checks if there is a session with valid auth information.
+     *
+     * @access public
+     * @return boolean  Whether or not the user is authenticated.
+     */
+    function checkAuth()
+    {
+        $this->log('Auth::checkAuth() called.', AUTH_LOG_DEBUG);
+        $this->authChecks++;
+        if (isset($this->session)) {
+            // Check if authentication session is expired
+            if (   $this->expire > 0
+                && isset($this->session['timestamp'])
+                && ($this->session['timestamp'] + $this->expire) < time()) {
+                $this->log('Session Expired', AUTH_LOG_INFO);
+                $this->expired = true;
+                $this->status = AUTH_EXPIRED;
+                $this->logout();
+                return false;
+            }
+
+            // Check if maximum idle time is reached
+            if (   $this->idle > 0
+                && isset($this->session['idle']) 
+                && ($this->session['idle'] + $this->idle) < time()) {
+                $this->log('Session Idle Time Reached', AUTH_LOG_INFO);
+                $this->idled = true;
+                $this->status = AUTH_IDLED;
+                $this->logout();
+                return false;
+            }
+
+            if (   isset($this->session['registered']) 
+                && isset($this->session['username']) 
+                && $this->session['registered'] == true 
+                && $this->session['username'] != '') {
+                Auth::updateIdle();
+
+                if ($this->advancedsecurity) {
+                    $this->log('Advanced Security Mode Enabled.', AUTH_LOG_DEBUG);
+                    
+                    // Only Generate the challenge once
+                    if($this->authChecks == 1) {
+                        $this->log('Generating new Challenge Cookie.', AUTH_LOG_DEBUG);
+                        $this->session['challengecookieold'] = $this->session['challengecookie'];
+                        $this->session['challengecookie'] = md5($this->session['challengekey'].microtime());
+                        setcookie('authchallenge', $this->session['challengecookie']);
+                    }
+                    
+                    // Check for ip change
+                    if (   isset($this->server['REMOTE_ADDR']) 
+                        && $this->session['sessionip'] != $this->server['REMOTE_ADDR']) {
+                        $this->log('Security Breach. Remote IP Address changed.', AUTH_LOG_INFO);
+                        // Check if the IP of the user has changed, if so we 
+                        // assume a man in the middle attack and log him out
+                        $this->expired = true;
+                        $this->status = AUTH_SECURITY_BREACH;
+                        $this->logout();
+                        return false;
+                    }
+
+                    // Check for ip change (if connected via proxy)
+                    if (   isset($this->server['HTTP_X_FORWARDED_FOR'])
+                        && $this->session['sessionforwardedfor'] != $this->server['HTTP_X_FORWARDED_FOR']) {
+                        $this->log('Security Breach. Forwarded For IP Address changed.', AUTH_LOG_INFO);
+                        // Check if the IP of the user connecting via proxy has 
+                        // changed, if so we assume a man in the middle attack 
+                        // and log him out.
+                        $this->expired = true;
+                        $this->status = AUTH_SECURITY_BREACH;
+                        $this->logout();
+                        return false;
+                    }
+                    
+                    // Check for useragent change
+                    if (   isset($this->server['HTTP_USER_AGENT']) 
+                        && $this->session['sessionuseragent'] != $this->server['HTTP_USER_AGENT']) {
+                        $this->log('Security Breach. User Agent changed.', AUTH_LOG_INFO);
+                        // Check if the User-Agent of the user has changed, if 
+                        // so we assume a man in the middle attack and log him out
+                        $this->expired = true;
+                        $this->status = AUTH_SECURITY_BREACH;
+                        $this->logout();
+                        return false;
+                    }
+    
+                    // Check challenge cookie here, if challengecookieold is not set 
+                    // this is the first time and check is skipped
+                    // TODO when user open two pages similtaneuly (open in new window,open 
+                    // in tab) auth breach is caused find out a way around that if possible
+                    if (   isset($this->session['challengecookieold']) 
+                        && $this->session['challengecookieold'] != $this->cookie['authchallenge']) {
+                        $this->log('Security Breach. Challenge Cookie mismatch.', AUTH_LOG_INFO);
+                        $this->expired = true;
+                        $this->status = AUTH_SECURITY_BREACH;
+                        $this->logout();
+                        $this->login();
+                        return false;
+                    }
+                }
+
+                if (is_callable($this->checkAuthCallback)) {
+                    $this->log('Calling checkAuthCallback ('.$this->checkAuthCallback.').', AUTH_LOG_DEBUG);
+                    $checkCallback = call_user_func_array($this->checkAuthCallback, array($this->username, &$this));
+                    if ($checkCallback == false) {
+                        $this->log('checkAuthCallback failed.', AUTH_LOG_INFO);
+                        $this->expired = true;
+                        $this->status = AUTH_CALLBACK_ABORT;
+                        $this->logout();
+                        return false;
+                    }
+                }
+
+                $this->log('Session OK.', AUTH_LOG_INFO);
+                return true;
+            }
+        }
+        $this->log('Unable to locate session storage.', AUTH_LOG_DEBUG);
+        return false;
+    }
+
+    // }}}
+    // {{{ staticCheckAuth() [static]
+
+    /**
+     * Statically checks if there is a session with valid auth information.
+     *
+     * @access public
+     * @see checkAuth
+     * @return boolean  Whether or not the user is authenticated.
+     * @static
+     */
+    function staticCheckAuth($options = null)
+    {
+        static $staticAuth;
+        if(!isset($staticAuth)) {
+            $staticAuth = new Auth('null', $options);
+        }
+        $staticAuth->log('Auth::staticCheckAuth() called', AUTH_LOG_DEBUG);
+        return $staticAuth->checkAuth();
+    }
+
+    // }}}
+    // {{{ getAuth()
+
+    /**
+     * Has the user been authenticated?
+     *
+     * @access public
+     * @return bool  True if the user is logged in, otherwise false.
+     */
+    function getAuth()
+    {
+        $this->log('Auth::getAuth() called.', AUTH_LOG_DEBUG);
+        return $this->checkAuth();
+    }
+
+    // }}}
+    // {{{ logout()
+
+    /**
+     * Logout function
+     *
+     * This function clears any auth tokens in the currently
+     * active session and executes the logout callback function,
+     * if any
+     *
+     * @access public
+     * @return void
+     */
+    function logout()
+    {
+        $this->log('Auth::logout() called.', AUTH_LOG_DEBUG);
+
+        if (is_callable($this->logoutCallback)) {
+            $this->log('Calling logoutCallback ('.$this->logoutCallback.').', AUTH_LOG_DEBUG);
+            call_user_func_array($this->logoutCallback, array($this->session['username'], &$this));
+        }
+
+        $this->username = '';
+        $this->password = '';
+        
+        $this->session = null;
+    }
+
+    // }}}
+    // {{{ updateIdle()
+
+    /**
+     * Update the idletime
+     *
+     * @access private
+     * @return void
+     */
+    function updateIdle()
+    {
+        $this->session['idle'] = time();
+    }
+
+    // }}}
+    // {{{ getUsername()
+
+    /**
+     * Get the username
+     *
+     * @return string
+     * @access public
+     */
+    function getUsername()
+    {
+        if (isset($this->session['username'])) {
+            return($this->session['username']);
+        }
+        return('');
+    }
+
+    // }}}
+    // {{{ getStatus()
+
+    /**
+     * Get the current status
+     *
+     * @return string
+     * @access public
+     */
+    function getStatus()
+    {
+        return $this->status;
+    }
+
+    // }}}
+    // {{{ getPostUsernameField()
+    
+    /**
+     * Gets the post varible used for the username
+     * 
+     * @return string
+     * @access public
+     */
+    function getPostUsernameField()
+    {
+        return($this->_postUsername);
+    }
+
+    // }}}
+    // {{{ getPostPasswordField()
+
+    /**
+     * Gets the post varible used for the username
+     * 
+     * @return string
+     * @access public
+     */
+    function getPostPasswordField()
+    {
+        return($this->_postPassword);
+    }
+
+    // }}}
+    // {{{ sessionValidThru()
+
+    /**
+     * Returns the time up to the session is valid
+     *
+     * @access public
+     * @return integer
+     */
+    function sessionValidThru()
+    {
+        if (!isset($this->session['idle'])) {
+            return 0;
+        }
+        if ($this->idle == 0) {
+            return 0;
+        }
+        return ($this->session['idle'] + $this->idle);
+    }
+
+    // }}}
+    // {{{ listUsers()
+
+    /**
+     * List all users that are currently available in the storage
+     * container
+     *
+     * @access public
+     * @return array
+     */
+    function listUsers()
+    {
+        $this->log('Auth::listUsers() called.', AUTH_LOG_DEBUG);
+        $this->_loadStorage();
+        return $this->storage->listUsers();
+    }
+
+    // }}}
+    // {{{ addUser()
+
+    /**
+     * Add user to the storage container
+     *
+     * @access public
+     * @param  string Username
+     * @param  string Password
+     * @param  mixed  Additional parameters
+     * @return mixed  True on success, PEAR error object on error
+     *                and AUTH_METHOD_NOT_SUPPORTED otherwise.
+     */
+    function addUser($username, $password, $additional = '')
+    {
+        $this->log('Auth::addUser() called.', AUTH_LOG_DEBUG);
+        $this->_loadStorage();
+        return $this->storage->addUser($username, $password, $additional);
+    }
+
+    // }}}
+    // {{{ removeUser()
+
+    /**
+     * Remove user from the storage container
+     *
+     * @access public
+     * @param  string Username
+     * @return mixed  True on success, PEAR error object on error
+     *                and AUTH_METHOD_NOT_SUPPORTED otherwise.
+     */
+    function removeUser($username)
+    {
+        $this->log('Auth::removeUser() called.', AUTH_LOG_DEBUG);
+        $this->_loadStorage();
+        return $this->storage->removeUser($username);
+    }
+
+    // }}}
+    // {{{ changePassword()
+
+    /**
+     * Change password for user in the storage container
+     *
+     * @access public
+     * @param string Username
+     * @param string The new password 
+     * @return mixed True on success, PEAR error object on error
+     *               and AUTH_METHOD_NOT_SUPPORTED otherwise.
+     */
+    function changePassword($username, $password)
+    {
+        $this->log('Auth::changePassword() called', AUTH_LOG_DEBUG);
+        $this->_loadStorage();
+        return $this->storage->changePassword($username, $password);
+    }
+
+    // }}}
+    // {{{ log()
+
+    /**
+     * Log a message from the Auth system
+     *
+     * @access public
+     * @param string The message to log
+     * @param string The log level to log the message under. See the Log documentation for more info.
+     * @return boolean
+     */
+    function log($message, $level = AUTH_LOG_DEBUG)
+    {
+        if (!$this->enableLogging) return false;
+
+        $this->_loadLogger();
+
+        $this->logger->log('AUTH: '.$message, $level);
+    }
+
+    // }}}
+    // {{{ _loadLogger()
+
+    /**
+      * Load Log object if not already loaded
+      *
+      * Suspend logger instantiation to make Auth lighter to use 
+      * for calls which do not require logging
+      *
+      * @return bool    True if the logger is loaded, false if the logger
+      *                 is already loaded
+      * @access private
+      */
+    function _loadLogger()
+    {
+        if(is_null($this->logger)) {
+            if (!class_exists('Log')) {
+                include_once 'Log.php';
+            }
+            $this->logger =& Log::singleton('null',
+                    null,
+                    'auth['.getmypid().']',
+                    array(),
+                    AUTH_LOG_DEBUG);
+            return(true);
+        }
+        return(false);
+    }
+
+    // }}}
+    // {{{ attachLogObserver()
+
+    /**
+     * Attach an Observer to the Auth Log Source
+     *
+     * @param object Log_Observer A Log Observer instance
+     * @return boolean
+     */
+    function attachLogObserver(&$observer) {
+
+        $this->_loadLogger();
+
+        return $this->logger->attach($observer);
+
+    }
+
+    // }}}
+
+}
+?>
Index: /branches/beta/data/module/Auth/SASL.php
===================================================================
--- /branches/beta/data/module/Auth/SASL.php	(revision 14676)
+++ /branches/beta/data/module/Auth/SASL.php	(revision 14676)
@@ -0,0 +1,98 @@
+<?php
+// +-----------------------------------------------------------------------+ 
+// | Copyright (c) 2002-2003 Richard Heyes                                 | 
+// | All rights reserved.                                                  | 
+// |                                                                       | 
+// | Redistribution and use in source and binary forms, with or without    | 
+// | modification, are permitted provided that the following conditions    | 
+// | are met:                                                              | 
+// |                                                                       | 
+// | o Redistributions of source code must retain the above copyright      | 
+// |   notice, this list of conditions and the following disclaimer.       | 
+// | o Redistributions in binary form must reproduce the above copyright   | 
+// |   notice, this list of conditions and the following disclaimer in the | 
+// |   documentation and/or other materials provided with the distribution.| 
+// | o The names of the authors may not be used to endorse or promote      | 
+// |   products derived from this software without specific prior written  | 
+// |   permission.                                                         | 
+// |                                                                       | 
+// | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS   | 
+// | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT     | 
+// | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | 
+// | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT  | 
+// | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | 
+// | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT      | 
+// | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 
+// | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 
+// | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT   | 
+// | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 
+// | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.  | 
+// |                                                                       | 
+// +-----------------------------------------------------------------------+ 
+// | Author: Richard Heyes <richard@php.net>                               | 
+// +-----------------------------------------------------------------------+ 
+// 
+// $Id: SASL.php,v 1.4 2003/02/21 16:07:17 mj Exp $
+
+/**
+* Client implementation of various SASL mechanisms 
+*
+* @author  Richard Heyes <richard@php.net>
+* @access  public
+* @version 1.0
+* @package Auth_SASL
+*/
+
+require_once('../PEAR.php');
+
+class Auth_SASL
+{
+    /**
+    * Factory class. Returns an object of the request
+    * type.
+    *
+    * @param string $type One of: Anonymous
+    *                             Plain
+    *                             CramMD5
+    *                             DigestMD5
+    *                     Types are not case sensitive
+    */
+    function &factory($type)
+    {
+        switch (strtolower($type)) {
+            case 'anonymous':
+                $filename  = 'Auth/SASL/Anonymous.php';
+                $classname = 'Auth_SASL_Anonymous';
+                break;
+
+            case 'login':
+                $filename  = 'Auth/SASL/Login.php';
+                $classname = 'Auth_SASL_Login';
+                break;
+
+            case 'plain':
+                $filename  = 'Auth/SASL/Plain.php';
+                $classname = 'Auth_SASL_Plain';
+                break;
+
+            case 'crammd5':
+                $filename  = 'Auth/SASL/CramMD5.php';
+                $classname = 'Auth_SASL_CramMD5';
+                break;
+
+            case 'digestmd5':
+                $filename  = 'Auth/SASL/DigestMD5.php';
+                $classname = 'Auth_SASL_DigestMD5';
+                break;
+
+            default:
+                return PEAR::raiseError('Invalid SASL mechanism type');
+                break;
+        }
+
+        require_once($filename);
+        return new $classname();
+    }
+}
+
+?>
Index: /branches/beta/data/module/Mail/Mail.php
===================================================================
--- /branches/beta/data/module/Mail/Mail.php	(revision 14676)
+++ /branches/beta/data/module/Mail/Mail.php	(revision 14676)
@@ -0,0 +1,240 @@
+<?php
+//
+// +----------------------------------------------------------------------+
+// | PHP Version 4                                                        |
+// +----------------------------------------------------------------------+
+// | Copyright (c) 1997-2003 The PHP Group                                |
+// +----------------------------------------------------------------------+
+// | This source file is subject to version 2.02 of the PHP license,      |
+// | that is bundled with this package in the file LICENSE, and is        |
+// | available at through the world-wide-web at                           |
+// | http://www.php.net/license/2_02.txt.                                 |
+// | If you did not receive a copy of the PHP license and are unable to   |
+// | obtain it through the world-wide-web, please send a note to          |
+// | license@php.net so we can mail you a copy immediately.               |
+// +----------------------------------------------------------------------+
+// | Author: Chuck Hagenbuch <chuck@horde.org>                            |
+// +----------------------------------------------------------------------+
+//
+// $Id: Mail.php,v 1.17 2006/09/15 03:41:18 jon Exp $
+
+require_once dirname(__FILE__) . "/../PEAR.php";
+
+/**
+ * PEAR's Mail:: interface. Defines the interface for implementing
+ * mailers under the PEAR hierarchy, and provides supporting functions
+ * useful in multiple mailer backends.
+ *
+ * @access public
+ * @version $Revision: 1.17 $
+ * @package Mail
+ */
+class Mail
+{
+    /**
+     * Line terminator used for separating header lines.
+     * @var string
+     */
+    var $sep = "\r\n";
+
+    /**
+     * Provides an interface for generating Mail:: objects of various
+     * types
+     *
+     * @param string $driver The kind of Mail:: object to instantiate.
+     * @param array  $params The parameters to pass to the Mail:: object.
+     * @return object Mail a instance of the driver class or if fails a PEAR Error
+     * @access public
+     */
+    function &factory($driver, $params = array())
+    {
+        $driver = strtolower($driver);
+        $include_dir = realpath(dirname( __FILE__));
+        include_once $include_dir ."/../Mail/" . $driver . ".php";
+        $class = 'Mail_' . $driver;
+        if (class_exists($class)) {
+            $mailer = new $class($params);
+            return $mailer;
+        } else {
+            return PEAR::raiseError('Unable to find class for driver ' . $driver);
+        }
+    }
+
+    /**
+     * Implements Mail::send() function using php's built-in mail()
+     * command.
+     *
+     * @param mixed $recipients Either a comma-seperated list of recipients
+     *              (RFC822 compliant), or an array of recipients,
+     *              each RFC822 valid. This may contain recipients not
+     *              specified in the headers, for Bcc:, resending
+     *              messages, etc.
+     *
+     * @param array $headers The array of headers to send with the mail, in an
+     *              associative array, where the array key is the
+     *              header name (ie, 'Subject'), and the array value
+     *              is the header value (ie, 'test'). The header
+     *              produced from those values would be 'Subject:
+     *              test'.
+     *
+     * @param string $body The full text of the message body, including any
+     *               Mime parts, etc.
+     *
+     * @return mixed Returns true on success, or a PEAR_Error
+     *               containing a descriptive error message on
+     *               failure.
+     * @access public
+     * @deprecated use Mail_mail::send instead
+     */
+    function send($recipients, $headers, $body)
+    {
+        $this->_sanitizeHeaders($headers);
+
+        // if we're passed an array of recipients, implode it.
+        if (is_array($recipients)) {
+            $recipients = implode(', ', $recipients);
+        }
+
+        // get the Subject out of the headers array so that we can
+        // pass it as a seperate argument to mail().
+        $subject = '';
+        if (isset($headers['Subject'])) {
+            $subject = $headers['Subject'];
+            unset($headers['Subject']);
+        }
+
+        // flatten the headers out.
+        list(,$text_headers) = Mail::prepareHeaders($headers);
+
+        return mail($recipients, $subject, $body, $text_headers);
+
+    }
+
+    /**
+     * Sanitize an array of mail headers by removing any additional header
+     * strings present in a legitimate header's value.  The goal of this
+     * filter is to prevent mail injection attacks.
+     *
+     * @param array $headers The associative array of headers to sanitize.
+     *
+     * @access private
+     */
+    function _sanitizeHeaders(&$headers)
+    {
+        foreach ($headers as $key => $value) {
+            $headers[$key] =
+                preg_replace('=((<CR>|<LF>|0x0A/%0A|0x0D/%0D|\\n|\\r)\S).*=i',
+                             null, $value);
+        }
+    }
+
+    /**
+     * Take an array of mail headers and return a string containing
+     * text usable in sending a message.
+     *
+     * @param array $headers The array of headers to prepare, in an associative
+     *              array, where the array key is the header name (ie,
+     *              'Subject'), and the array value is the header
+     *              value (ie, 'test'). The header produced from those
+     *              values would be 'Subject: test'.
+     *
+     * @return mixed Returns false if it encounters a bad address,
+     *               otherwise returns an array containing two
+     *               elements: Any From: address found in the headers,
+     *               and the plain text version of the headers.
+     * @access private
+     */
+    function prepareHeaders($headers)
+    {
+        $lines = array();
+        $from = null;
+
+        foreach ($headers as $key => $value) {
+            if (strcasecmp($key, 'From') === 0) {
+                $include_dir = realpath(dirname( __FILE__));
+                include_once $include_dir ."/../Mail/RFC822.php";
+                $parser = &new Mail_RFC822();
+                $addresses = $parser->parseAddressList($value, 'localhost', false);
+                if (PEAR::isError($addresses)) {
+                    return $addresses;
+                }
+
+                $from = $addresses[0]->mailbox . '@' . $addresses[0]->host;
+
+                // Reject envelope From: addresses with spaces.
+                if (strstr($from, ' ')) {
+                    return false;
+                }
+
+                $lines[] = $key . ': ' . $value;
+            } elseif (strcasecmp($key, 'Received') === 0) {
+                $received = array();
+                if (is_array($value)) {
+                    foreach ($value as $line) {
+                        $received[] = $key . ': ' . $line;
+                    }
+                }
+                else {
+                    $received[] = $key . ': ' . $value;
+                }
+                // Put Received: headers at the top.  Spam detectors often
+                // flag messages with Received: headers after the Subject:
+                // as spam.
+                $lines = array_merge($received, $lines);
+            } else {
+                // If $value is an array (i.e., a list of addresses), convert
+                // it to a comma-delimited string of its elements (addresses).
+                if (is_array($value)) {
+                    $value = implode(', ', $value);
+                }
+                $lines[] = $key . ': ' . $value;
+            }
+        }
+
+        return array($from, join($this->sep, $lines));
+    }
+
+    /**
+     * Take a set of recipients and parse them, returning an array of
+     * bare addresses (forward paths) that can be passed to sendmail
+     * or an smtp server with the rcpt to: command.
+     *
+     * @param mixed Either a comma-seperated list of recipients
+     *              (RFC822 compliant), or an array of recipients,
+     *              each RFC822 valid.
+     *
+     * @return mixed An array of forward paths (bare addresses) or a PEAR_Error
+     *               object if the address list could not be parsed.
+     * @access private
+     */
+    function parseRecipients($recipients)
+    {
+        include_once 'Mail/RFC822.php';
+
+        // if we're passed an array, assume addresses are valid and
+        // implode them before parsing.
+        if (is_array($recipients)) {
+            $recipients = implode(', ', $recipients);
+        }
+
+        // Parse recipients, leaving out all personal info. This is
+        // for smtp recipients, etc. All relevant personal information
+        // should already be in the headers.
+        $addresses = Mail_RFC822::parseAddressList($recipients, 'localhost', false);
+
+        // If parseAddressList() returned a PEAR_Error object, just return it.
+        if (PEAR::isError($addresses)) {
+            return $addresses;
+        }
+
+        $recipients = array();
+        if (is_array($addresses)) {
+            foreach ($addresses as $ob) {
+                $recipients[] = $ob->mailbox . '@' . $ob->host;
+            }
+        }
+
+        return $recipients;
+    }
+
+}
Index: /branches/beta/data/module/Mail/smtp.php
===================================================================
--- /branches/beta/data/module/Mail/smtp.php	(revision 14676)
+++ /branches/beta/data/module/Mail/smtp.php	(revision 14676)
@@ -0,0 +1,349 @@
+<?php
+//
+// +----------------------------------------------------------------------+
+// | PHP Version 4                                                        |
+// +----------------------------------------------------------------------+
+// | Copyright (c) 1997-2003 The PHP Group                                |
+// +----------------------------------------------------------------------+
+// | This source file is subject to version 2.02 of the PHP license,      |
+// | that is bundled with this package in the file LICENSE, and is        |
+// | available at through the world-wide-web at                           |
+// | http://www.php.net/license/2_02.txt.                                 |
+// | If you did not receive a copy of the PHP license and are unable to   |
+// | obtain it through the world-wide-web, please send a note to          |
+// | license@php.net so we can mail you a copy immediately.               |
+// +----------------------------------------------------------------------+
+// | Authors: Chuck Hagenbuch <chuck@horde.org>                           |
+// |          Jon Parise <jon@php.net>                                    |
+// +----------------------------------------------------------------------+
+
+/** Error: Failed to create a Net_SMTP object */
+define('PEAR_MAIL_SMTP_ERROR_CREATE', 10000);
+
+/** Error: Failed to connect to SMTP server */
+define('PEAR_MAIL_SMTP_ERROR_CONNECT', 10001);
+
+/** Error: SMTP authentication failure */
+define('PEAR_MAIL_SMTP_ERROR_AUTH', 10002);
+
+/** Error: No From: address has been provided */
+define('PEAR_MAIL_SMTP_ERROR_FROM', 10003);
+
+/** Error: Failed to set sender */
+define('PEAR_MAIL_SMTP_ERROR_SENDER', 10004);
+
+/** Error: Failed to add recipient */
+define('PEAR_MAIL_SMTP_ERROR_RECIPIENT', 10005);
+
+/** Error: Failed to send data */
+define('PEAR_MAIL_SMTP_ERROR_DATA', 10006);
+
+/**
+ * SMTP implementation of the PEAR Mail interface. Requires the Net_SMTP class.
+ * @access public
+ * @package Mail
+ * @version $Revision: 1.28 $
+ */
+class Mail_smtp extends Mail {
+
+    /**
+     * SMTP connection object.
+     *
+     * @var object
+     * @access private
+     */
+    var $_smtp = null;
+
+    /**
+     * The SMTP host to connect to.
+     * @var string
+     */
+    var $host = 'localhost';
+
+    /**
+     * The port the SMTP server is on.
+     * @var integer
+     */
+    var $port = 25;
+
+    /**
+     * Should SMTP authentication be used?
+     *
+     * This value may be set to true, false or the name of a specific
+     * authentication method.
+     *
+     * If the value is set to true, the Net_SMTP package will attempt to use
+     * the best authentication method advertised by the remote SMTP server.
+     *
+     * @var mixed
+     */
+    var $auth = false;
+
+    /**
+     * The username to use if the SMTP server requires authentication.
+     * @var string
+     */
+    var $username = '';
+
+    /**
+     * The password to use if the SMTP server requires authentication.
+     * @var string
+     */
+    var $password = '';
+
+    /**
+     * Hostname or domain that will be sent to the remote SMTP server in the
+     * HELO / EHLO message.
+     *
+     * @var string
+     */
+    var $localhost = 'localhost';
+
+    /**
+     * SMTP connection timeout value.  NULL indicates no timeout.
+     *
+     * @var integer
+     */
+    var $timeout = null;
+
+    /**
+     * Whether to use VERP or not. If not a boolean, the string value
+     * will be used as the VERP separators.
+     *
+     * @var mixed boolean or string
+     */
+    var $verp = false;
+
+    /**
+     * Turn on Net_SMTP debugging?
+     *
+     * @var boolean $debug
+     */
+    var $debug = false;
+
+    /**
+     * Indicates whether or not the SMTP connection should persist over
+     * multiple calls to the send() method.
+     *
+     * @var boolean
+     */
+    var $persist = false;
+
+    /**
+     * Constructor.
+     *
+     * Instantiates a new Mail_smtp:: object based on the parameters
+     * passed in. It looks for the following parameters:
+     *     host        The server to connect to. Defaults to localhost.
+     *     port        The port to connect to. Defaults to 25.
+     *     auth        SMTP authentication.  Defaults to none.
+     *     username    The username to use for SMTP auth. No default.
+     *     password    The password to use for SMTP auth. No default.
+     *     localhost   The local hostname / domain. Defaults to localhost.
+     *     timeout     The SMTP connection timeout. Defaults to none.
+     *     verp        Whether to use VERP or not. Defaults to false.
+     *     debug       Activate SMTP debug mode? Defaults to false.
+     *     persist     Should the SMTP connection persist?
+     *
+     * If a parameter is present in the $params array, it replaces the
+     * default.
+     *
+     * @param array Hash containing any parameters different from the
+     *              defaults.
+     * @access public
+     */
+    function Mail_smtp($params)
+    {
+        if (isset($params['host'])) $this->host = $params['host'];
+        if (isset($params['port'])) $this->port = $params['port'];
+        if (isset($params['auth'])) $this->auth = $params['auth'];
+        if (isset($params['username'])) $this->username = $params['username'];
+        if (isset($params['password'])) $this->password = $params['password'];
+        if (isset($params['localhost'])) $this->localhost = $params['localhost'];
+        if (isset($params['timeout'])) $this->timeout = $params['timeout'];
+        if (isset($params['verp'])) $this->verp = $params['verp'];
+        if (isset($params['debug'])) $this->debug = (boolean)$params['debug'];
+        if (isset($params['persist'])) $this->persist = (boolean)$params['persist'];
+
+        register_shutdown_function(array(&$this, '_Mail_smtp'));
+    }
+
+    /**
+     * Destructor implementation to ensure that we disconnect from any
+     * potentially-alive persistent SMTP connections.
+     */
+    function _Mail_smtp()
+    {
+        $this->disconnect();
+    }
+
+    /**
+     * Implements Mail::send() function using SMTP.
+     *
+     * @param mixed $recipients Either a comma-seperated list of recipients
+     *              (RFC822 compliant), or an array of recipients,
+     *              each RFC822 valid. This may contain recipients not
+     *              specified in the headers, for Bcc:, resending
+     *              messages, etc.
+     *
+     * @param array $headers The array of headers to send with the mail, in an
+     *              associative array, where the array key is the
+     *              header name (e.g., 'Subject'), and the array value
+     *              is the header value (e.g., 'test'). The header
+     *              produced from those values would be 'Subject:
+     *              test'.
+     *
+     * @param string $body The full text of the message body, including any
+     *               Mime parts, etc.
+     *
+     * @return mixed Returns true on success, or a PEAR_Error
+     *               containing a descriptive error message on
+     *               failure.
+     * @access public
+     */
+    function send($recipients, $headers, $body)
+    {
+        $include_dir = realpath(dirname( __FILE__));
+        include_once $include_dir . "/../Net/SMTP.php";
+
+        /* If we don't already have an SMTP object, create one. */
+        if (is_object($this->_smtp) === false) {
+            $this->_smtp =& new Net_SMTP($this->host, $this->port,
+                                         $this->localhost);
+
+            /* If we still don't have an SMTP object at this point, fail. */
+            if (is_object($this->_smtp) === false) {
+                return PEAR::raiseError('Failed to create a Net_SMTP object',
+                                        PEAR_MAIL_SMTP_ERROR_CREATE);
+            }
+
+            /* Configure the SMTP connection. */
+            if ($this->debug) {
+                $this->_smtp->setDebug(true);
+            }
+
+            /* Attempt to connect to the configured SMTP server. */
+            if (PEAR::isError($res = $this->_smtp->connect($this->timeout))) {
+                $error = $this->_error('Failed to connect to ' .
+                                       $this->host . ':' . $this->port,
+                                       $res);
+                return PEAR::raiseError($error, PEAR_MAIL_SMTP_ERROR_CONNECT);
+            }
+
+            /* Attempt to authenticate if authentication has been enabled. */
+            if ($this->auth) {
+                $method = is_string($this->auth) ? $this->auth : '';
+
+                if (PEAR::isError($res = $this->_smtp->auth($this->username,
+                                                            $this->password,
+                                                            $method))) {
+                    $error = $this->_error("$method authentication failure",
+                                           $res);
+                    $this->_smtp->rset();
+                    return PEAR::raiseError($error, PEAR_MAIL_SMTP_ERROR_AUTH);
+                }
+            }
+        }
+
+        $this->_sanitizeHeaders($headers);
+        $headerElements = $this->prepareHeaders($headers);
+        if (PEAR::isError($headerElements)) {
+            $this->_smtp->rset();
+            return $headerElements;
+        }
+        list($from, $textHeaders) = $headerElements;
+
+        /* Since few MTAs are going to allow this header to be forged
+         * unless it's in the MAIL FROM: exchange, we'll use
+         * Return-Path instead of From: if it's set. */
+        if (!empty($headers['Return-Path'])) {
+            $from = $headers['Return-Path'];
+        }
+
+        if (!isset($from)) {
+            $this->_smtp->rset();
+            return PEAR::raiseError('No From: address has been provided',
+                                    PEAR_MAIL_SMTP_ERROR_FROM);
+        }
+
+        $args['verp'] = $this->verp;
+        if (PEAR::isError($res = $this->_smtp->mailFrom($from, $args))) {
+            $error = $this->_error("Failed to set sender: $from", $res);
+            $this->_smtp->rset();
+            return PEAR::raiseError($error, PEAR_MAIL_SMTP_ERROR_SENDER);
+        }
+
+        $recipients = $this->parseRecipients($recipients);
+        if (PEAR::isError($recipients)) {
+            $this->_smtp->rset();
+            return $recipients;
+        }
+
+        foreach ($recipients as $recipient) {
+            if (PEAR::isError($res = $this->_smtp->rcptTo($recipient))) {
+                $error = $this->_error("Failed to add recipient: $recipient",
+                                       $res);
+                $this->_smtp->rset();
+                return PEAR::raiseError($error, PEAR_MAIL_SMTP_ERROR_RECIPIENT);
+            }
+        }
+
+        /* Send the message's headers and the body as SMTP data. */
+        if (PEAR::isError($res = $this->_smtp->data($textHeaders . "\r\n\r\n" . $body))) {
+            $error = $this->_error('Failed to send data', $res);
+            $this->_smtp->rset();
+            return PEAR::raiseError($error, PEAR_MAIL_SMTP_ERROR_DATA);
+        }
+
+        /* If persistent connections are disabled, destroy our SMTP object. */
+        if ($this->persist === false) {
+            $this->disconnect();
+        }
+
+        return true;
+    }
+
+    /**
+     * Disconnect and destroy the current SMTP connection.
+     *
+     * @return boolean True if the SMTP connection no longer exists.
+     *
+     * @since  1.1.9
+     * @access public
+     */
+    function disconnect()
+    {
+        /* If we have an SMTP object, disconnect and destroy it. */
+        if (is_object($this->_smtp) && $this->_smtp->disconnect()) {
+            $this->_smtp = null;
+        }
+
+        /* We are disconnected if we no longer have an SMTP object. */
+        return ($this->_smtp === null);
+    }
+
+    /**
+     * Build a standardized string describing the current SMTP error.
+     *
+     * @param string $text  Custom string describing the error context.
+     * @param object $error Reference to the current PEAR_Error object.
+     *
+     * @return string       A string describing the current SMTP error.
+     *
+     * @since  1.1.7
+     * @access private
+     */
+    function _error($text, &$error)
+    {
+        /* Split the SMTP response into a code and a response string. */
+        list($code, $response) = $this->_smtp->getResponse();
+
+        /* Build our standardized error string. */
+        $msg = $text;
+        $msg .= ' [SMTP: ' . $error->getMessage();
+        $msg .= " (code: $code, response: $response)]";
+
+        return $msg;
+    }
+
+}
Index: /branches/beta/data/module/Mail/RFC822.php
===================================================================
--- /branches/beta/data/module/Mail/RFC822.php	(revision 14676)
+++ /branches/beta/data/module/Mail/RFC822.php	(revision 14676)
@@ -0,0 +1,923 @@
+<?php
+// +-----------------------------------------------------------------------+
+// | Copyright (c) 2001-2002, Richard Heyes                                |
+// | All rights reserved.                                                  |
+// |                                                                       |
+// | Redistribution and use in source and binary forms, with or without    |
+// | modification, are permitted provided that the following conditions    |
+// | are met:                                                              |
+// |                                                                       |
+// | o Redistributions of source code must retain the above copyright      |
+// |   notice, this list of conditions and the following disclaimer.       |
+// | o Redistributions in binary form must reproduce the above copyright   |
+// |   notice, this list of conditions and the following disclaimer in the |
+// |   documentation and/or other materials provided with the distribution.|
+// | o The names of the authors may not be used to endorse or promote      |
+// |   products derived from this software without specific prior written  |
+// |   permission.                                                         |
+// |                                                                       |
+// | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS   |
+// | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT     |
+// | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
+// | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT  |
+// | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
+// | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT      |
+// | LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
+// | DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
+// | THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT   |
+// | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
+// | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.  |
+// |                                                                       |
+// +-----------------------------------------------------------------------+
+// | Authors: Richard Heyes <richard@phpguru.org>                          |
+// |          Chuck Hagenbuch <chuck@horde.org>                            |
+// +-----------------------------------------------------------------------+
+
+/**
+ * RFC 822 Email address list validation Utility
+ *
+ * What is it?
+ *
+ * This class will take an address string, and parse it into it's consituent
+ * parts, be that either addresses, groups, or combinations. Nested groups
+ * are not supported. The structure it returns is pretty straight forward,
+ * and is similar to that provided by the imap_rfc822_parse_adrlist(). Use
+ * print_r() to view the structure.
+ *
+ * How do I use it?
+ *
+ * $address_string = 'My Group: "Richard" <richard@localhost> (A comment), ted@example.com (Ted Bloggs), Barney;';
+ * $structure = Mail_RFC822::parseAddressList($address_string, 'example.com', true)
+ * print_r($structure);
+ *
+ * @author  Richard Heyes <richard@phpguru.org>
+ * @author  Chuck Hagenbuch <chuck@horde.org>
+ * @version $Revision: 1.23 $
+ * @license BSD
+ * @package Mail
+ */
+class Mail_RFC822 {
+
+    /**
+     * The address being parsed by the RFC822 object.
+     * @var string $address
+     */
+    var $address = '';
+
+    /**
+     * The default domain to use for unqualified addresses.
+     * @var string $default_domain
+     */
+    var $default_domain = 'localhost';
+
+    /**
+     * Should we return a nested array showing groups, or flatten everything?
+     * @var boolean $nestGroups
+     */
+    var $nestGroups = true;
+
+    /**
+     * Whether or not to validate atoms for non-ascii characters.
+     * @var boolean $validate
+     */
+    var $validate = true;
+
+    /**
+     * The array of raw addresses built up as we parse.
+     * @var array $addresses
+     */
+    var $addresses = array();
+
+    /**
+     * The final array of parsed address information that we build up.
+     * @var array $structure
+     */
+    var $structure = array();
+
+    /**
+     * The current error message, if any.
+     * @var string $error
+     */
+    var $error = null;
+
+    /**
+     * An internal counter/pointer.
+     * @var integer $index
+     */
+    var $index = null;
+
+    /**
+     * The number of groups that have been found in the address list.
+     * @var integer $num_groups
+     * @access public
+     */
+    var $num_groups = 0;
+
+    /**
+     * A variable so that we can tell whether or not we're inside a
+     * Mail_RFC822 object.
+     * @var boolean $mailRFC822
+     */
+    var $mailRFC822 = true;
+
+    /**
+    * A limit after which processing stops
+    * @var int $limit
+    */
+    var $limit = null;
+
+    /**
+     * Sets up the object. The address must either be set here or when
+     * calling parseAddressList(). One or the other.
+     *
+     * @access public
+     * @param string  $address         The address(es) to validate.
+     * @param string  $default_domain  Default domain/host etc. If not supplied, will be set to localhost.
+     * @param boolean $nest_groups     Whether to return the structure with groups nested for easier viewing.
+     * @param boolean $validate        Whether to validate atoms. Turn this off if you need to run addresses through before encoding the personal names, for instance.
+     *
+     * @return object Mail_RFC822 A new Mail_RFC822 object.
+     */
+    function Mail_RFC822($address = null, $default_domain = null, $nest_groups = null, $validate = null, $limit = null)
+    {
+        if (isset($address))        $this->address        = $address;
+        if (isset($default_domain)) $this->default_domain = $default_domain;
+        if (isset($nest_groups))    $this->nestGroups     = $nest_groups;
+        if (isset($validate))       $this->validate       = $validate;
+        if (isset($limit))          $this->limit          = $limit;
+    }
+
+    /**
+     * Starts the whole process. The address must either be set here
+     * or when creating the object. One or the other.
+     *
+     * @access public
+     * @param string  $address         The address(es) to validate.
+     * @param string  $default_domain  Default domain/host etc.
+     * @param boolean $nest_groups     Whether to return the structure with groups nested for easier viewing.
+     * @param boolean $validate        Whether to validate atoms. Turn this off if you need to run addresses through before encoding the personal names, for instance.
+     *
+     * @return array A structured array of addresses.
+     */
+    function parseAddressList($address = null, $default_domain = null, $nest_groups = null, $validate = null, $limit = null)
+    {
+        if (!isset($this) || !isset($this->mailRFC822)) {
+            $obj = new Mail_RFC822($address, $default_domain, $nest_groups, $validate, $limit);
+            return $obj->parseAddressList();
+        }
+
+        if (isset($address))        $this->address        = $address;
+        if (isset($default_domain)) $this->default_domain = $default_domain;
+        if (isset($nest_groups))    $this->nestGroups     = $nest_groups;
+        if (isset($validate))       $this->validate       = $validate;
+        if (isset($limit))          $this->limit          = $limit;
+
+        $this->structure  = array();
+        $this->addresses  = array();
+        $this->error      = null;
+        $this->index      = null;
+
+        // Unfold any long lines in $this->address.
+        $this->address = preg_replace('/\r?\n/', "\r\n", $this->address);
+        $this->address = preg_replace('/\r\n(\t| )+/', ' ', $this->address);
+
+        while ($this->address = $this->_splitAddresses($this->address));
+
+        if ($this->address === false || isset($this->error)) {
+            require_once 'PEAR.php';
+            return PEAR::raiseError($this->error);
+        }
+
+        // Validate each address individually.  If we encounter an invalid
+        // address, stop iterating and return an error immediately.
+        foreach ($this->addresses as $address) {
+            $valid = $this->_validateAddress($address);
+
+            if ($valid === false || isset($this->error)) {
+                require_once 'PEAR.php';
+                return PEAR::raiseError($this->error);
+            }
+
+            if (!$this->nestGroups) {
+                $this->structure = array_merge($this->structure, $valid);
+            } else {
+                $this->structure[] = $valid;
+            }
+        }
+
+        return $this->structure;
+    }
+
+    /**
+     * Splits an address into separate addresses.
+     *
+     * @access private
+     * @param string $address The addresses to split.
+     * @return boolean Success or failure.
+     */
+    function _splitAddresses($address)
+    {
+        if (!empty($this->limit) && count($this->addresses) == $this->limit) {
+            return '';
+        }
+
+        if ($this->_isGroup($address) && !isset($this->error)) {
+            $split_char = ';';
+            $is_group   = true;
+        } elseif (!isset($this->error)) {
+            $split_char = ',';
+            $is_group   = false;
+        } elseif (isset($this->error)) {
+            return false;
+        }
+
+        // Split the string based on the above ten or so lines.
+        $parts  = explode($split_char, $address);
+        $string = $this->_splitCheck($parts, $split_char);
+
+        // If a group...
+        if ($is_group) {
+            // If $string does not contain a colon outside of
+            // brackets/quotes etc then something's fubar.
+
+            // First check there's a colon at all:
+            if (strpos($string, ':') === false) {
+                $this->error = 'Invalid address: ' . $string;
+                return false;
+            }
+
+            // Now check it's outside of brackets/quotes:
+            if (!$this->_splitCheck(explode(':', $string), ':')) {
+                return false;
+            }
+
+            // We must have a group at this point, so increase the counter:
+            $this->num_groups++;
+        }
+
+        // $string now contains the first full address/group.
+        // Add to the addresses array.
+        $this->addresses[] = array(
+                                   'address' => trim($string),
+                                   'group'   => $is_group
+                                   );
+
+        // Remove the now stored address from the initial line, the +1
+        // is to account for the explode character.
+        $address = trim(substr($address, strlen($string) + 1));
+
+        // If the next char is a comma and this was a group, then
+        // there are more addresses, otherwise, if there are any more
+        // chars, then there is another address.
+        if ($is_group && substr($address, 0, 1) == ','){
+            $address = trim(substr($address, 1));
+            return $address;
+
+        } elseif (strlen($address) > 0) {
+            return $address;
+
+        } else {
+            return '';
+        }
+
+        // If you got here then something's off
+        return false;
+    }
+
+    /**
+     * Checks for a group at the start of the string.
+     *
+     * @access private
+     * @param string $address The address to check.
+     * @return boolean Whether or not there is a group at the start of the string.
+     */
+    function _isGroup($address)
+    {
+        // First comma not in quotes, angles or escaped:
+        $parts  = explode(',', $address);
+        $string = $this->_splitCheck($parts, ',');
+
+        // Now we have the first address, we can reliably check for a
+        // group by searching for a colon that's not escaped or in
+        // quotes or angle brackets.
+        if (count($parts = explode(':', $string)) > 1) {
+            $string2 = $this->_splitCheck($parts, ':');
+            return ($string2 !== $string);
+        } else {
+            return false;
+        }
+    }
+
+    /**
+     * A common function that will check an exploded string.
+     *
+     * @access private
+     * @param array $parts The exloded string.
+     * @param string $char  The char that was exploded on.
+     * @return mixed False if the string contains unclosed quotes/brackets, or the string on success.
+     */
+    function _splitCheck($parts, $char)
+    {
+        $string = $parts[0];
+
+        for ($i = 0; $i < count($parts); $i++) {
+            if ($this->_hasUnclosedQuotes($string)
+                || $this->_hasUnclosedBrackets($string, '<>')
+                || $this->_hasUnclosedBrackets($string, '[]')
+                || $this->_hasUnclosedBrackets($string, '()')
+                || substr($string, -1) == '\\') {
+                if (isset($parts[$i + 1])) {
+                    $string = $string . $char . $parts[$i + 1];
+                } else {
+                    $this->error = 'Invalid address spec. Unclosed bracket or quotes';
+                    return false;
+                }
+            } else {
+                $this->index = $i;
+                break;
+            }
+        }
+
+        return $string;
+    }
+
+    /**
+     * Checks if a string has an unclosed quotes or not.
+     *
+     * @access private
+     * @param string $string The string to check.
+     * @return boolean True if there are unclosed quotes inside the string, false otherwise.
+     */
+    function _hasUnclosedQuotes($string)
+    {
+        $string     = explode('"', $string);
+        $string_cnt = count($string);
+
+        for ($i = 0; $i < (count($string) - 1); $i++)
+            if (substr($string[$i], -1) == '\\')
+                $string_cnt--;
+
+        return ($string_cnt % 2 === 0);
+    }
+
+    /**
+     * Checks if a string has an unclosed brackets or not. IMPORTANT:
+     * This function handles both angle brackets and square brackets;
+     *
+     * @access private
+     * @param string $string The string to check.
+     * @param string $chars  The characters to check for.
+     * @return boolean True if there are unclosed brackets inside the string, false otherwise.
+     */
+    function _hasUnclosedBrackets($string, $chars)
+    {
+        $num_angle_start = substr_count($string, $chars[0]);
+        $num_angle_end   = substr_count($string, $chars[1]);
+
+        $this->_hasUnclosedBracketsSub($string, $num_angle_start, $chars[0]);
+        $this->_hasUnclosedBracketsSub($string, $num_angle_end, $chars[1]);
+
+        if ($num_angle_start < $num_angle_end) {
+            $this->error = 'Invalid address spec. Unmatched quote or bracket (' . $chars . ')';
+            return false;
+        } else {
+            return ($num_angle_start > $num_angle_end);
+        }
+    }
+
+    /**
+     * Sub function that is used only by hasUnclosedBrackets().
+     *
+     * @access private
+     * @param string $string The string to check.
+     * @param integer &$num    The number of occurences.
+     * @param string $char   The character to count.
+     * @return integer The number of occurences of $char in $string, adjusted for backslashes.
+     */
+    function _hasUnclosedBracketsSub($string, &$num, $char)
+    {
+        $parts = explode($char, $string);
+        for ($i = 0; $i < count($parts); $i++){
+            if (substr($parts[$i], -1) == '\\' || $this->_hasUnclosedQuotes($parts[$i]))
+                $num--;
+            if (isset($parts[$i + 1]))
+                $parts[$i + 1] = $parts[$i] . $char . $parts[$i + 1];
+        }
+
+        return $num;
+    }
+
+    /**
+     * Function to begin checking the address.
+     *
+     * @access private
+     * @param string $address The address to validate.
+     * @return mixed False on failure, or a structured array of address information on success.
+     */
+    function _validateAddress($address)
+    {
+        $is_group = false;
+        $addresses = array();
+
+        if ($address['group']) {
+            $is_group = true;
+
+            // Get the group part of the name
+            $parts     = explode(':', $address['address']);
+            $groupname = $this->_splitCheck($parts, ':');
+            $structure = array();
+
+            // And validate the group part of the name.
+            if (!$this->_validatePhrase($groupname)){
+                $this->error = 'Group name did not validate.';
+                return false;
+            } else {
+                // Don't include groups if we are not nesting
+                // them. This avoids returning invalid addresses.
+                if ($this->nestGroups) {
+                    $structure = new stdClass;
+                    $structure->groupname = $groupname;
+                }
+            }
+
+            $address['address'] = ltrim(substr($address['address'], strlen($groupname . ':')));
+        }
+
+        // If a group then split on comma and put into an array.
+        // Otherwise, Just put the whole address in an array.
+        if ($is_group) {
+            while (strlen($address['address']) > 0) {
+                $parts       = explode(',', $address['address']);
+                $addresses[] = $this->_splitCheck($parts, ',');
+                $address['address'] = trim(substr($address['address'], strlen(end($addresses) . ',')));
+            }
+        } else {
+            $addresses[] = $address['address'];
+        }
+
+        // Check that $addresses is set, if address like this:
+        // Groupname:;
+        // Then errors were appearing.
+        if (!count($addresses)){
+            $this->error = 'Empty group.';
+            return false;
+        }
+
+        // Trim the whitespace from all of the address strings.
+        array_map('trim', $addresses);
+
+        // Validate each mailbox.
+        // Format could be one of: name <geezer@domain.com>
+        //                         geezer@domain.com
+        //                         geezer
+        // ... or any other format valid by RFC 822.
+        for ($i = 0; $i < count($addresses); $i++) {
+            if (!$this->validateMailbox($addresses[$i])) {
+                if (empty($this->error)) {
+                    $this->error = 'Validation failed for: ' . $addresses[$i];
+                }
+                return false;
+            }
+        }
+
+        // Nested format
+        if ($this->nestGroups) {
+            if ($is_group) {
+                $structure->addresses = $addresses;
+            } else {
+                $structure = $addresses[0];
+            }
+
+        // Flat format
+        } else {
+            if ($is_group) {
+                $structure = array_merge($structure, $addresses);
+            } else {
+                $structure = $addresses;
+            }
+        }
+
+        return $structure;
+    }
+
+    /**
+     * Function to validate a phrase.
+     *
+     * @access private
+     * @param string $phrase The phrase to check.
+     * @return boolean Success or failure.
+     */
+    function _validatePhrase($phrase)
+    {
+        // Splits on one or more Tab or space.
+        $parts = preg_split('/[ \\x09]+/', $phrase, -1, PREG_SPLIT_NO_EMPTY);
+
+        $phrase_parts = array();
+        while (count($parts) > 0){
+            $phrase_parts[] = $this->_splitCheck($parts, ' ');
+            for ($i = 0; $i < $this->index + 1; $i++)
+                array_shift($parts);
+        }
+
+        foreach ($phrase_parts as $part) {
+            // If quoted string:
+            if (substr($part, 0, 1) == '"') {
+                if (!$this->_validateQuotedString($part)) {
+                    return false;
+                }
+                continue;
+            }
+
+            // Otherwise it's an atom:
+            if (!$this->_validateAtom($part)) return false;
+        }
+
+        return true;
+    }
+
+    /**
+     * Function to validate an atom which from rfc822 is:
+     * atom = 1*<any CHAR except specials, SPACE and CTLs>
+     *
+     * If validation ($this->validate) has been turned off, then
+     * validateAtom() doesn't actually check anything. This is so that you
+     * can split a list of addresses up before encoding personal names
+     * (umlauts, etc.), for example.
+     *
+     * @access private
+     * @param string $atom The string to check.
+     * @return boolean Success or failure.
+     */
+    function _validateAtom($atom)
+    {
+        if (!$this->validate) {
+            // Validation has been turned off; assume the atom is okay.
+            return true;
+        }
+
+        // Check for any char from ASCII 0 - ASCII 127
+        if (!preg_match('/^[\\x00-\\x7E]+$/i', $atom, $matches)) {
+            return false;
+        }
+
+        // Check for specials:
+        if (preg_match('/[][()<>@,;\\:". ]/', $atom)) {
+            return false;
+        }
+
+        // Check for control characters (ASCII 0-31):
+        if (preg_match('/[\\x00-\\x1F]+/', $atom)) {
+            return false;
+        }
+
+        return true;
+    }
+
+    /**
+     * Function to validate quoted string, which is:
+     * quoted-string = <"> *(qtext/quoted-pair) <">
+     *
+     * @access private
+     * @param string $qstring The string to check
+     * @return boolean Success or failure.
+     */
+    function _validateQuotedString($qstring)
+    {
+        // Leading and trailing "
+        $qstring = substr($qstring, 1, -1);
+
+        // Perform check, removing quoted characters first.
+        return !preg_match('/[\x0D\\\\"]/', preg_replace('/\\\\./', '', $qstring));
+    }
+
+    /**
+     * Function to validate a mailbox, which is:
+     * mailbox =   addr-spec         ; simple address
+     *           / phrase route-addr ; name and route-addr
+     *
+     * @access public
+     * @param string &$mailbox The string to check.
+     * @return boolean Success or failure.
+     */
+    function validateMailbox(&$mailbox)
+    {
+        // A couple of defaults.
+        $phrase  = '';
+        $comment = '';
+        $comments = array();
+
+        // Catch any RFC822 comments and store them separately.
+        $_mailbox = $mailbox;
+        while (strlen(trim($_mailbox)) > 0) {
+            $parts = explode('(', $_mailbox);
+            $before_comment = $this->_splitCheck($parts, '(');
+            if ($before_comment != $_mailbox) {
+                // First char should be a (.
+                $comment    = substr(str_replace($before_comment, '', $_mailbox), 1);
+                $parts      = explode(')', $comment);
+                $comment    = $this->_splitCheck($parts, ')');
+                $comments[] = $comment;
+
+                // +1 is for the trailing )
+                $_mailbox   = substr($_mailbox, strpos($_mailbox, $comment)+strlen($comment)+1);
+            } else {
+                break;
+            }
+        }
+
+        foreach ($comments as $comment) {
+            $mailbox = str_replace("($comment)", '', $mailbox);
+        }
+
+        $mailbox = trim($mailbox);
+
+        // Check for name + route-addr
+        if (substr($mailbox, -1) == '>' && substr($mailbox, 0, 1) != '<') {
+            $parts  = explode('<', $mailbox);
+            $name   = $this->_splitCheck($parts, '<');
+
+            $phrase     = trim($name);
+            $route_addr = trim(substr($mailbox, strlen($name.'<'), -1));
+
+            if ($this->_validatePhrase($phrase) === false || ($route_addr = $this->_validateRouteAddr($route_addr)) === false) {
+                return false;
+            }
+
+        // Only got addr-spec
+        } else {
+            // First snip angle brackets if present.
+            if (substr($mailbox, 0, 1) == '<' && substr($mailbox, -1) == '>') {
+                $addr_spec = substr($mailbox, 1, -1);
+            } else {
+                $addr_spec = $mailbox;
+            }
+
+            if (($addr_spec = $this->_validateAddrSpec($addr_spec)) === false) {
+                return false;
+            }
+        }
+
+        // Construct the object that will be returned.
+        $mbox = new stdClass();
+
+        // Add the phrase (even if empty) and comments
+        $mbox->personal = $phrase;
+        $mbox->comment  = isset($comments) ? $comments : array();
+
+        if (isset($route_addr)) {
+            $mbox->mailbox = $route_addr['local_part'];
+            $mbox->host    = $route_addr['domain'];
+            $route_addr['adl'] !== '' ? $mbox->adl = $route_addr['adl'] : '';
+        } else {
+            $mbox->mailbox = $addr_spec['local_part'];
+            $mbox->host    = $addr_spec['domain'];
+        }
+
+        $mailbox = $mbox;
+        return true;
+    }
+
+    /**
+     * This function validates a route-addr which is:
+     * route-addr = "<" [route] addr-spec ">"
+     *
+     * Angle brackets have already been removed at the point of
+     * getting to this function.
+     *
+     * @access private
+     * @param string $route_addr The string to check.
+     * @return mixed False on failure, or an array containing validated address/route information on success.
+     */
+    function _validateRouteAddr($route_addr)
+    {
+        // Check for colon.
+        if (strpos($route_addr, ':') !== false) {
+            $parts = explode(':', $route_addr);
+            $route = $this->_splitCheck($parts, ':');
+        } else {
+            $route = $route_addr;
+        }
+
+        // If $route is same as $route_addr then the colon was in
+        // quotes or brackets or, of course, non existent.
+        if ($route === $route_addr){
+            unset($route);
+            $addr_spec = $route_addr;
+            if (($addr_spec = $this->_validateAddrSpec($addr_spec)) === false) {
+                return false;
+            }
+        } else {
+            // Validate route part.
+            if (($route = $this->_validateRoute($route)) === false) {
+                return false;
+            }
+
+            $addr_spec = substr($route_addr, strlen($route . ':'));
+
+            // Validate addr-spec part.
+            if (($addr_spec = $this->_validateAddrSpec($addr_spec)) === false) {
+                return false;
+            }
+        }
+
+        if (isset($route)) {
+            $return['adl'] = $route;
+        } else {
+            $return['adl'] = '';
+        }
+
+        $return = array_merge($return, $addr_spec);
+        return $return;
+    }
+
+    /**
+     * Function to validate a route, which is:
+     * route = 1#("@" domain) ":"
+     *
+     * @access private
+     * @param string $route The string to check.
+     * @return mixed False on failure, or the validated $route on success.
+     */
+    function _validateRoute($route)
+    {
+        // Split on comma.
+        $domains = explode(',', trim($route));
+
+        foreach ($domains as $domain) {
+            $domain = str_replace('@', '', trim($domain));
+            if (!$this->_validateDomain($domain)) return false;
+        }
+
+        return $route;
+    }
+
+    /**
+     * Function to validate a domain, though this is not quite what
+     * you expect of a strict internet domain.
+     *
+     * domain = sub-domain *("." sub-domain)
+     *
+     * @access private
+     * @param string $domain The string to check.
+     * @return mixed False on failure, or the validated domain on success.
+     */
+    function _validateDomain($domain)
+    {
+        // Note the different use of $subdomains and $sub_domains
+        $subdomains = explode('.', $domain);
+
+        while (count($subdomains) > 0) {
+            $sub_domains[] = $this->_splitCheck($subdomains, '.');
+            for ($i = 0; $i < $this->index + 1; $i++)
+                array_shift($subdomains);
+        }
+
+        foreach ($sub_domains as $sub_domain) {
+            if (!$this->_validateSubdomain(trim($sub_domain)))
+                return false;
+        }
+
+        // Managed to get here, so return input.
+        return $domain;
+    }
+
+    /**
+     * Function to validate a subdomain:
+     *   subdomain = domain-ref / domain-literal
+     *
+     * @access private
+     * @param string $subdomain The string to check.
+     * @return boolean Success or failure.
+     */
+    function _validateSubdomain($subdomain)
+    {
+        if (preg_match('|^\[(.*)]$|', $subdomain, $arr)){
+            if (!$this->_validateDliteral($arr[1])) return false;
+        } else {
+            if (!$this->_validateAtom($subdomain)) return false;
+        }
+
+        // Got here, so return successful.
+        return true;
+    }
+
+    /**
+     * Function to validate a domain literal:
+     *   domain-literal =  "[" *(dtext / quoted-pair) "]"
+     *
+     * @access private
+     * @param string $dliteral The string to check.
+     * @return boolean Success or failure.
+     */
+    function _validateDliteral($dliteral)
+    {
+        return !preg_match('/(.)[][\x0D\\\\]/', $dliteral, $matches) && $matches[1] != '\\';
+    }
+
+    /**
+     * Function to validate an addr-spec.
+     *
+     * addr-spec = local-part "@" domain
+     *
+     * @access private
+     * @param string $addr_spec The string to check.
+     * @return mixed False on failure, or the validated addr-spec on success.
+     */
+    function _validateAddrSpec($addr_spec)
+    {
+        $addr_spec = trim($addr_spec);
+
+        // Split on @ sign if there is one.
+        if (strpos($addr_spec, '@') !== false) {
+            $parts      = explode('@', $addr_spec);
+            $local_part = $this->_splitCheck($parts, '@');
+            $domain     = substr($addr_spec, strlen($local_part . '@'));
+
+        // No @ sign so assume the default domain.
+        } else {
+            $local_part = $addr_spec;
+            $domain     = $this->default_domain;
+        }
+
+        if (($local_part = $this->_validateLocalPart($local_part)) === false) return false;
+        if (($domain     = $this->_validateDomain($domain)) === false) return false;
+
+        // Got here so return successful.
+        return array('local_part' => $local_part, 'domain' => $domain);
+    }
+
+    /**
+     * Function to validate the local part of an address:
+     *   local-part = word *("." word)
+     *
+     * @access private
+     * @param string $local_part
+     * @return mixed False on failure, or the validated local part on success.
+     */
+    function _validateLocalPart($local_part)
+    {
+        $parts = explode('.', $local_part);
+        $words = array();
+
+        // Split the local_part into words.
+        while (count($parts) > 0){
+            $words[] = $this->_splitCheck($parts, '.');
+            for ($i = 0; $i < $this->index + 1; $i++) {
+                array_shift($parts);
+            }
+        }
+
+        // Validate each word.
+        foreach ($words as $word) {
+            // If this word contains an unquoted space, it is invalid. (6.2.4)
+            if (strpos($word, ' ') && $word[0] !== '"')
+            {
+                return false;
+            }
+
+            if ($this->_validatePhrase(trim($word)) === false) return false;
+        }
+
+        // Managed to get here, so return the input.
+        return $local_part;
+    }
+
+    /**
+     * Returns an approximate count of how many addresses are in the
+     * given string. This is APPROXIMATE as it only splits based on a
+     * comma which has no preceding backslash. Could be useful as
+     * large amounts of addresses will end up producing *large*
+     * structures when used with parseAddressList().
+     *
+     * @param  string $data Addresses to count
+     * @return int          Approximate count
+     */
+    function approximateCount($data)
+    {
+        return count(preg_split('/(?<!\\\\),/', $data));
+    }
+
+    /**
+     * This is a email validating function separate to the rest of the
+     * class. It simply validates whether an email is of the common
+     * internet form: <user>@<domain>. This can be sufficient for most
+     * people. Optional stricter mode can be utilised which restricts
+     * mailbox characters allowed to alphanumeric, full stop, hyphen
+     * and underscore.
+     *
+     * @param  string  $data   Address to check
+     * @param  boolean $strict Optional stricter mode
+     * @return mixed           False if it fails, an indexed array
+     *                         username/domain if it matches
+     */
+    function isValidInetAddress($data, $strict = false)
+    {
+        $regex = $strict ? '/^([.0-9a-z_+-]+)@(([0-9a-z-]+\.)+[0-9a-z]{2,})$/i' : '/^([*+!.&#$|\'\\%\/0-9a-z^_`{}=?~:-]+)@(([0-9a-z-]+\.)+[0-9a-z]{2,})$/i';
+        if (preg_match($regex, trim($data), $matches)) {
+            return array($matches[1], $matches[2]);
+        } else {
+            return false;
+        }
+    }
+
+}
Index: /branches/beta/data/module/Mail/mimePart.php
===================================================================
--- /branches/beta/data/module/Mail/mimePart.php	(revision 11460)
+++ /branches/beta/data/module/Mail/mimePart.php	(revision 14676)
@@ -1,5 +1,5 @@
 <?php
 // +-----------------------------------------------------------------------+
-// | Copyright (c) 2002-2003  Richard Heyes                                     |
+// | Copyright (c) 2002-2003  Richard Heyes                                |
 // | All rights reserved.                                                  |
 // |                                                                       |
Index: /branches/beta/data/module/Net/SMTP.php
===================================================================
--- /branches/beta/data/module/Net/SMTP.php	(revision 14676)
+++ /branches/beta/data/module/Net/SMTP.php	(revision 14676)
@@ -0,0 +1,1035 @@
+<?php
+/* vim: set expandtab softtabstop=4 tabstop=4 shiftwidth=4: */
+// +----------------------------------------------------------------------+
+// | PHP Version 4                                                        |
+// +----------------------------------------------------------------------+
+// | Copyright (c) 1997-2003 The PHP Group                                |
+// +----------------------------------------------------------------------+
+// | This source file is subject to version 2.02 of the PHP license,      |
+// | that is bundled with this package in the file LICENSE, and is        |
+// | available at through the world-wide-web at                           |
+// | http://www.php.net/license/2_02.txt.                                 |
+// | If you did not receive a copy of the PHP license and are unable to   |
+// | obtain it through the world-wide-web, please send a note to          |
+// | license@php.net so we can mail you a copy immediately.               |
+// +----------------------------------------------------------------------+
+// | Authors: Chuck Hagenbuch <chuck@horde.org>                           |
+// |          Jon Parise <jon@php.net>                                    |
+// |          Damian Alejandro Fernandez Sosa <damlists@cnba.uba.ar>      |
+// +----------------------------------------------------------------------+
+//
+// $Id: SMTP.php,v 1.58 2007/03/28 04:53:34 chagenbu Exp $
+
+$include_dir = realpath(dirname( __FILE__));
+require_once $include_dir . "/../PEAR.php";
+require_once $include_dir . "/../Net/Socket.php";
+
+/**
+ * Provides an implementation of the SMTP protocol using PEAR's
+ * Net_Socket:: class.
+ *
+ * @package Net_SMTP
+ * @author  Chuck Hagenbuch <chuck@horde.org>
+ * @author  Jon Parise <jon@php.net>
+ * @author  Damian Alejandro Fernandez Sosa <damlists@cnba.uba.ar>
+ *
+ * @example basic.php   A basic implementation of the Net_SMTP package.
+ */
+class Net_SMTP
+{
+    /**
+     * The server to connect to.
+     * @var string
+     * @access public
+     */
+    var $host = 'localhost';
+
+    /**
+     * The port to connect to.
+     * @var int
+     * @access public
+     */
+    var $port = 25;
+
+    /**
+     * The value to give when sending EHLO or HELO.
+     * @var string
+     * @access public
+     */
+    var $localhost = 'localhost';
+
+    /**
+     * List of supported authentication methods, in preferential order.
+     * @var array
+     * @access public
+     */
+    var $auth_methods = array('DIGEST-MD5', 'CRAM-MD5', 'LOGIN', 'PLAIN');
+
+    /**
+     * Should debugging output be enabled?
+     * @var boolean
+     * @access private
+     */
+    var $_debug = false;
+
+    /**
+     * The socket resource being used to connect to the SMTP server.
+     * @var resource
+     * @access private
+     */
+    var $_socket = null;
+
+    /**
+     * The most recent server response code.
+     * @var int
+     * @access private
+     */
+    var $_code = -1;
+
+    /**
+     * The most recent server response arguments.
+     * @var array
+     * @access private
+     */
+    var $_arguments = array();
+
+    /**
+     * Stores detected features of the SMTP server.
+     * @var array
+     * @access private
+     */
+    var $_esmtp = array();
+
+    /**
+     * Instantiates a new Net_SMTP object, overriding any defaults
+     * with parameters that are passed in.
+     *
+     * If you have SSL support in PHP, you can connect to a server
+     * over SSL using an 'ssl://' prefix:
+     *
+     *   // 465 is a common smtps port.
+     *   $smtp = new Net_SMTP('ssl://mail.host.com', 465);
+     *   $smtp->connect();
+     *
+     * @param string  $host       The server to connect to.
+     * @param integer $port       The port to connect to.
+     * @param string  $localhost  The value to give when sending EHLO or HELO.
+     *
+     * @access  public
+     * @since   1.0
+     */
+    function Net_SMTP($host = null, $port = null, $localhost = null)
+    {
+        if (isset($host)) $this->host = $host;
+        if (isset($port)) $this->port = $port;
+        if (isset($localhost)) $this->localhost = $localhost;
+
+        $this->_socket = new Net_Socket();
+
+        /*
+         * Include the Auth_SASL package.  If the package is not available,
+         * we disable the authentication methods that depend upon it.
+         */
+        if ((@include_once '../Auth/SASL.php') === false) {
+            $pos = array_search('DIGEST-MD5', $this->auth_methods);
+            unset($this->auth_methods[$pos]);
+            $pos = array_search('CRAM-MD5', $this->auth_methods);
+            unset($this->auth_methods[$pos]);
+        }
+    }
+
+    /**
+     * Set the value of the debugging flag.
+     *
+     * @param   boolean $debug      New value for the debugging flag.
+     *
+     * @access  public
+     * @since   1.1.0
+     */
+    function setDebug($debug)
+    {
+        $this->_debug = $debug;
+    }
+
+    /**
+     * Send the given string of data to the server.
+     *
+     * @param   string  $data       The string of data to send.
+     *
+     * @return  mixed   True on success or a PEAR_Error object on failure.
+     *
+     * @access  private
+     * @since   1.1.0
+     */
+    function _send($data)
+    {
+        if ($this->_debug) {
+            echo "DEBUG: Send: $data\n";
+        }
+
+        if (PEAR::isError($error = $this->_socket->write($data))) {
+            return PEAR::raiseError('Failed to write to socket: ' .
+                                    $error->getMessage());
+        }
+
+        return true;
+    }
+
+    /**
+     * Send a command to the server with an optional string of
+     * arguments.  A carriage return / linefeed (CRLF) sequence will
+     * be appended to each command string before it is sent to the
+     * SMTP server - an error will be thrown if the command string
+     * already contains any newline characters. Use _send() for
+     * commands that must contain newlines.
+     *
+     * @param   string  $command    The SMTP command to send to the server.
+     * @param   string  $args       A string of optional arguments to append
+     *                              to the command.
+     *
+     * @return  mixed   The result of the _send() call.
+     *
+     * @access  private
+     * @since   1.1.0
+     */
+    function _put($command, $args = '')
+    {
+        if (!empty($args)) {
+            $command .= ' ' . $args;
+        }
+
+        if (strcspn($command, "\r\n") !== strlen($command)) {
+            return PEAR::raiseError('Commands cannot contain newlines');
+        }
+
+        return $this->_send($command . "\r\n");
+    }
+
+    /**
+     * Read a reply from the SMTP server.  The reply consists of a response
+     * code and a response message.
+     *
+     * @param   mixed   $valid      The set of valid response codes.  These
+     *                              may be specified as an array of integer
+     *                              values or as a single integer value.
+     *
+     * @return  mixed   True if the server returned a valid response code or
+     *                  a PEAR_Error object is an error condition is reached.
+     *
+     * @access  private
+     * @since   1.1.0
+     *
+     * @see     getResponse
+     */
+    function _parseResponse($valid)
+    {
+        $this->_code = -1;
+        $this->_arguments = array();
+
+        while ($line = $this->_socket->readLine()) {
+            if ($this->_debug) {
+                echo "DEBUG: Recv: $line\n";
+            }
+
+            /* If we receive an empty line, the connection has been closed. */
+            if (empty($line)) {
+                $this->disconnect();
+                return PEAR::raiseError('Connection was unexpectedly closed');
+            }
+
+            /* Read the code and store the rest in the arguments array. */
+            $code = substr($line, 0, 3);
+            $this->_arguments[] = trim(substr($line, 4));
+
+            /* Check the syntax of the response code. */
+            if (is_numeric($code)) {
+                $this->_code = (int)$code;
+            } else {
+                $this->_code = -1;
+                break;
+            }
+
+            /* If this is not a multiline response, we're done. */
+            if (substr($line, 3, 1) != '-') {
+                break;
+            }
+        }
+
+        /* Compare the server's response code with the valid code. */
+        if (is_int($valid) && ($this->_code === $valid)) {
+            return true;
+        }
+
+        /* If we were given an array of valid response codes, check each one. */
+        if (is_array($valid)) {
+            foreach ($valid as $valid_code) {
+                if ($this->_code === $valid_code) {
+                    return true;
+                }
+            }
+        }
+
+        return PEAR::raiseError('Invalid response code received from server',
+                                $this->_code);
+    }
+
+    /**
+     * Return a 2-tuple containing the last response from the SMTP server.
+     *
+     * @return  array   A two-element array: the first element contains the
+     *                  response code as an integer and the second element
+     *                  contains the response's arguments as a string.
+     *
+     * @access  public
+     * @since   1.1.0
+     */
+    function getResponse()
+    {
+        return array($this->_code, join("\n", $this->_arguments));
+    }
+
+    /**
+     * Attempt to connect to the SMTP server.
+     *
+     * @param   int     $timeout    The timeout value (in seconds) for the
+     *                              socket connection.
+     * @param   bool    $persistent Should a persistent socket connection
+     *                              be used?
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function connect($timeout = null, $persistent = false)
+    {
+        $result = $this->_socket->connect($this->host, $this->port,
+                                          $persistent, $timeout);
+        if (PEAR::isError($result)) {
+            return PEAR::raiseError('Failed to connect socket: ' .
+                                    $result->getMessage());
+        }
+
+        if (PEAR::isError($error = $this->_parseResponse(220))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_negotiate())) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Attempt to disconnect from the SMTP server.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function disconnect()
+    {
+        if (PEAR::isError($error = $this->_put('QUIT'))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(221))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_socket->disconnect())) {
+            return PEAR::raiseError('Failed to disconnect socket: ' .
+                                    $error->getMessage());
+        }
+
+        return true;
+    }
+
+    /**
+     * Attempt to send the EHLO command and obtain a list of ESMTP
+     * extensions available, and failing that just send HELO.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     *
+     * @access private
+     * @since  1.1.0
+     */
+    function _negotiate()
+    {
+        if (PEAR::isError($error = $this->_put('EHLO', $this->localhost))) {
+            return $error;
+        }
+
+        if (PEAR::isError($this->_parseResponse(250))) {
+            /* If we receive a 503 response, we're already authenticated. */
+            if ($this->_code === 503) {
+                return true;
+            }
+
+            /* If the EHLO failed, try the simpler HELO command. */
+            if (PEAR::isError($error = $this->_put('HELO', $this->localhost))) {
+                return $error;
+            }
+            if (PEAR::isError($this->_parseResponse(250))) {
+                return PEAR::raiseError('HELO was not accepted: ', $this->_code);
+            }
+
+            return true;
+        }
+
+        foreach ($this->_arguments as $argument) {
+            $verb = strtok($argument, ' ');
+            $arguments = substr($argument, strlen($verb) + 1,
+                                strlen($argument) - strlen($verb) - 1);
+            $this->_esmtp[$verb] = $arguments;
+        }
+
+        return true;
+    }
+
+    /**
+     * Returns the name of the best authentication method that the server
+     * has advertised.
+     *
+     * @return mixed    Returns a string containing the name of the best
+     *                  supported authentication method or a PEAR_Error object
+     *                  if a failure condition is encountered.
+     * @access private
+     * @since  1.1.0
+     */
+    function _getBestAuthMethod()
+    {
+        $available_methods = explode(' ', $this->_esmtp['AUTH']);
+
+        foreach ($this->auth_methods as $method) {
+            if (in_array($method, $available_methods)) {
+                return $method;
+            }
+        }
+
+        return PEAR::raiseError('No supported authentication methods');
+    }
+
+    /**
+     * Attempt to do SMTP authentication.
+     *
+     * @param string The userid to authenticate as.
+     * @param string The password to authenticate with.
+     * @param string The requested authentication method.  If none is
+     *               specified, the best supported method will be used.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function auth($uid, $pwd , $method = '')
+    {
+        if (empty($this->_esmtp['AUTH'])) {
+            if (version_compare(PHP_VERSION, '5.1.0', '>=')) {
+                if (!isset($this->_esmtp['STARTTLS'])) {
+                    return PEAR::raiseError('SMTP server does not support authentication');
+                }
+                if (PEAR::isError($result = $this->_put('STARTTLS'))) {
+                    return $result;
+                }
+                if (PEAR::isError($result = $this->_parseResponse(220))) {
+                    return $result;
+                }
+                if (PEAR::isError($result = $this->_socket->enableCrypto(true, STREAM_CRYPTO_METHOD_TLS_CLIENT))) {
+                    return $result;
+                } elseif ($result !== true) {
+                    return PEAR::raiseError('STARTTLS failed');
+                }
+
+                /* Send EHLO again to recieve the AUTH string from the
+                 * SMTP server. */
+                $this->_negotiate();
+                if (empty($this->_esmtp['AUTH'])) {
+                    return PEAR::raiseError('SMTP server does not support authentication');
+                }
+            } else {
+                return PEAR::raiseError('SMTP server does not support authentication');
+            }
+        }
+
+        /* If no method has been specified, get the name of the best
+         * supported method advertised by the SMTP server. */
+        if (empty($method)) {
+            if (PEAR::isError($method = $this->_getBestAuthMethod())) {
+                /* Return the PEAR_Error object from _getBestAuthMethod(). */
+                return $method;
+            }
+        } else {
+            $method = strtoupper($method);
+            if (!in_array($method, $this->auth_methods)) {
+                return PEAR::raiseError("$method is not a supported authentication method");
+            }
+        }
+
+        switch ($method) {
+        case 'DIGEST-MD5':
+            $result = $this->_authDigest_MD5($uid, $pwd);
+            break;
+
+        case 'CRAM-MD5':
+            $result = $this->_authCRAM_MD5($uid, $pwd);
+            break;
+
+        case 'LOGIN':
+            $result = $this->_authLogin($uid, $pwd);
+            break;
+
+        case 'PLAIN':
+            $result = $this->_authPlain($uid, $pwd);
+            break;
+
+        default:
+            $result = PEAR::raiseError("$method is not a supported authentication method");
+            break;
+        }
+
+        /* If an error was encountered, return the PEAR_Error object. */
+        if (PEAR::isError($result)) {
+            return $result;
+        }
+
+        return true;
+    }
+
+    /**
+     * Authenticates the user using the DIGEST-MD5 method.
+     *
+     * @param string The userid to authenticate as.
+     * @param string The password to authenticate with.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access private
+     * @since  1.1.0
+     */
+    function _authDigest_MD5($uid, $pwd)
+    {
+        if (PEAR::isError($error = $this->_put('AUTH', 'DIGEST-MD5'))) {
+            return $error;
+        }
+        /* 334: Continue authentication request */
+        if (PEAR::isError($error = $this->_parseResponse(334))) {
+            /* 503: Error: already authenticated */
+            if ($this->_code === 503) {
+                return true;
+            }
+            return $error;
+        }
+
+        $challenge = base64_decode($this->_arguments[0]);
+        $digest = &Auth_SASL::factory('digestmd5');
+        $auth_str = base64_encode($digest->getResponse($uid, $pwd, $challenge,
+                                                       $this->host, "smtp"));
+
+        if (PEAR::isError($error = $this->_put($auth_str))) {
+            return $error;
+        }
+        /* 334: Continue authentication request */
+        if (PEAR::isError($error = $this->_parseResponse(334))) {
+            return $error;
+        }
+
+        /* We don't use the protocol's third step because SMTP doesn't
+         * allow subsequent authentication, so we just silently ignore
+         * it. */
+        if (PEAR::isError($error = $this->_put(' '))) {
+            return $error;
+        }
+        /* 235: Authentication successful */
+        if (PEAR::isError($error = $this->_parseResponse(235))) {
+            return $error;
+        }
+    }
+
+    /**
+     * Authenticates the user using the CRAM-MD5 method.
+     *
+     * @param string The userid to authenticate as.
+     * @param string The password to authenticate with.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access private
+     * @since  1.1.0
+     */
+    function _authCRAM_MD5($uid, $pwd)
+    {
+        if (PEAR::isError($error = $this->_put('AUTH', 'CRAM-MD5'))) {
+            return $error;
+        }
+        /* 334: Continue authentication request */
+        if (PEAR::isError($error = $this->_parseResponse(334))) {
+            /* 503: Error: already authenticated */
+            if ($this->_code === 503) {
+                return true;
+            }
+            return $error;
+        }
+
+        $challenge = base64_decode($this->_arguments[0]);
+        $cram = &Auth_SASL::factory('crammd5');
+        $auth_str = base64_encode($cram->getResponse($uid, $pwd, $challenge));
+
+        if (PEAR::isError($error = $this->_put($auth_str))) {
+            return $error;
+        }
+
+        /* 235: Authentication successful */
+        if (PEAR::isError($error = $this->_parseResponse(235))) {
+            return $error;
+        }
+    }
+
+    /**
+     * Authenticates the user using the LOGIN method.
+     *
+     * @param string The userid to authenticate as.
+     * @param string The password to authenticate with.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access private
+     * @since  1.1.0
+     */
+    function _authLogin($uid, $pwd)
+    {
+        if (PEAR::isError($error = $this->_put('AUTH', 'LOGIN'))) {
+            return $error;
+        }
+        /* 334: Continue authentication request */
+        if (PEAR::isError($error = $this->_parseResponse(334))) {
+            /* 503: Error: already authenticated */
+            if ($this->_code === 503) {
+                return true;
+            }
+            return $error;
+        }
+
+        if (PEAR::isError($error = $this->_put(base64_encode($uid)))) {
+            return $error;
+        }
+        /* 334: Continue authentication request */
+        if (PEAR::isError($error = $this->_parseResponse(334))) {
+            return $error;
+        }
+
+        if (PEAR::isError($error = $this->_put(base64_encode($pwd)))) {
+            return $error;
+        }
+
+        /* 235: Authentication successful */
+        if (PEAR::isError($error = $this->_parseResponse(235))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Authenticates the user using the PLAIN method.
+     *
+     * @param string The userid to authenticate as.
+     * @param string The password to authenticate with.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access private
+     * @since  1.1.0
+     */
+    function _authPlain($uid, $pwd)
+    {
+        if (PEAR::isError($error = $this->_put('AUTH', 'PLAIN'))) {
+            return $error;
+        }
+        /* 334: Continue authentication request */
+        if (PEAR::isError($error = $this->_parseResponse(334))) {
+            /* 503: Error: already authenticated */
+            if ($this->_code === 503) {
+                return true;
+            }
+            return $error;
+        }
+
+        $auth_str = base64_encode(chr(0) . $uid . chr(0) . $pwd);
+
+        if (PEAR::isError($error = $this->_put($auth_str))) {
+            return $error;
+        }
+
+        /* 235: Authentication successful */
+        if (PEAR::isError($error = $this->_parseResponse(235))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Send the HELO command.
+     *
+     * @param string The domain name to say we are.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function helo($domain)
+    {
+        if (PEAR::isError($error = $this->_put('HELO', $domain))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Send the MAIL FROM: command.
+     *
+     * @param string $sender    The sender (reverse path) to set.
+     * @param string $params    String containing additional MAIL parameters,
+     *                          such as the NOTIFY flags defined by RFC 1891
+     *                          or the VERP protocol.
+     *
+     *                          If $params is an array, only the 'verp' option
+     *                          is supported.  If 'verp' is true, the XVERP
+     *                          parameter is appended to the MAIL command.  If
+     *                          the 'verp' value is a string, the full
+     *                          XVERP=value parameter is appended.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function mailFrom($sender, $params = null)
+    {
+        $args = "FROM:<$sender>";
+
+        /* Support the deprecated array form of $params. */
+        if (is_array($params) && isset($params['verp'])) {
+            /* XVERP */
+            if ($params['verp'] === true) {
+                $args .= ' XVERP';
+
+            /* XVERP=something */
+            } elseif (trim($params['verp'])) {
+                $args .= ' XVERP=' . $params['verp'];
+            }
+        } elseif (is_string($params)) {
+            $args .= ' ' . $params;
+        }
+
+        if (PEAR::isError($error = $this->_put('MAIL', $args))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Send the RCPT TO: command.
+     *
+     * @param string $recipient The recipient (forward path) to add.
+     * @param string $params    String containing additional RCPT parameters,
+     *                          such as the NOTIFY flags defined by RFC 1891.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     *
+     * @access public
+     * @since  1.0
+     */
+    function rcptTo($recipient, $params = null)
+    {
+        $args = "TO:<$recipient>";
+        if (is_string($params)) {
+            $args .= ' ' . $params;
+        }
+
+        if (PEAR::isError($error = $this->_put('RCPT', $args))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(array(250, 251)))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Quote the data so that it meets SMTP standards.
+     *
+     * This is provided as a separate public function to facilitate
+     * easier overloading for the cases where it is desirable to
+     * customize the quoting behavior.
+     *
+     * @param string $data  The message text to quote. The string must be passed
+     *                      by reference, and the text will be modified in place.
+     *
+     * @access public
+     * @since  1.2
+     */
+    function quotedata(&$data)
+    {
+        /* Change Unix (\n) and Mac (\r) linefeeds into
+         * Internet-standard CRLF (\r\n) linefeeds. */
+        $data = preg_replace(array('/(?<!\r)\n/','/\r(?!\n)/'), "\r\n", $data);
+
+        /* Because a single leading period (.) signifies an end to the
+         * data, legitimate leading periods need to be "doubled"
+         * (e.g. '..'). */
+        $data = str_replace("\n.", "\n..", $data);
+    }
+
+    /**
+     * Send the DATA command.
+     *
+     * @param string $data  The message body to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function data($data)
+    {
+        /* RFC 1870, section 3, subsection 3 states "a value of zero
+         * indicates that no fixed maximum message size is in force".
+         * Furthermore, it says that if "the parameter is omitted no
+         * information is conveyed about the server's fixed maximum
+         * message size". */
+        if (isset($this->_esmtp['SIZE']) && ($this->_esmtp['SIZE'] > 0)) {
+            if (strlen($data) >= $this->_esmtp['SIZE']) {
+                $this->disconnect();
+                return PEAR::raiseError('Message size excedes the server limit');
+            }
+        }
+
+        /* Quote the data based on the SMTP standards. */
+        $this->quotedata($data);
+
+        if (PEAR::isError($error = $this->_put('DATA'))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(354))) {
+            return $error;
+        }
+
+        if (PEAR::isError($result = $this->_send($data . "\r\n.\r\n"))) {
+            return $result;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Send the SEND FROM: command.
+     *
+     * @param string The reverse path to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.2.6
+     */
+    function sendFrom($path)
+    {
+        if (PEAR::isError($error = $this->_put('SEND', "FROM:<$path>"))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Backwards-compatibility wrapper for sendFrom().
+     *
+     * @param string The reverse path to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     *
+     * @access      public
+     * @since       1.0
+     * @deprecated  1.2.6
+     */
+    function send_from($path)
+    {
+        return sendFrom($path);
+    }
+
+    /**
+     * Send the SOML FROM: command.
+     *
+     * @param string The reverse path to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.2.6
+     */
+    function somlFrom($path)
+    {
+        if (PEAR::isError($error = $this->_put('SOML', "FROM:<$path>"))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Backwards-compatibility wrapper for somlFrom().
+     *
+     * @param string The reverse path to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     *
+     * @access      public
+     * @since       1.0
+     * @deprecated  1.2.6
+     */
+    function soml_from($path)
+    {
+        return somlFrom($path);
+    }
+
+    /**
+     * Send the SAML FROM: command.
+     *
+     * @param string The reverse path to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.2.6
+     */
+    function samlFrom($path)
+    {
+        if (PEAR::isError($error = $this->_put('SAML', "FROM:<$path>"))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Backwards-compatibility wrapper for samlFrom().
+     *
+     * @param string The reverse path to send.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     *
+     * @access      public
+     * @since       1.0
+     * @deprecated  1.2.6
+     */
+    function saml_from($path)
+    {
+        return samlFrom($path);
+    }
+
+    /**
+     * Send the RSET command.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function rset()
+    {
+        if (PEAR::isError($error = $this->_put('RSET'))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Send the VRFY command.
+     *
+     * @param string The string to verify
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function vrfy($string)
+    {
+        /* Note: 251 is also a valid response code */
+        if (PEAR::isError($error = $this->_put('VRFY', $string))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(array(250, 252)))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Send the NOOP command.
+     *
+     * @return mixed Returns a PEAR_Error with an error message on any
+     *               kind of failure, or true on success.
+     * @access public
+     * @since  1.0
+     */
+    function noop()
+    {
+        if (PEAR::isError($error = $this->_put('NOOP'))) {
+            return $error;
+        }
+        if (PEAR::isError($error = $this->_parseResponse(250))) {
+            return $error;
+        }
+
+        return true;
+    }
+
+    /**
+     * Backwards-compatibility method.  identifySender()'s functionality is
+     * now handled internally.
+     *
+     * @return  boolean     This method always return true.
+     *
+     * @access  public
+     * @since   1.0
+     */
+    function identifySender()
+    {
+        return true;
+    }
+
+}
Index: /branches/beta/data/lib/slib.php
===================================================================
--- /branches/beta/data/lib/slib.php	(revision 13286)
+++ /branches/beta/data/lib/slib.php	(revision 14676)
@@ -1659,6 +1659,8 @@
 }
 
-/* ¼õÃí´°Î»¥á¡¼¥ëÁ÷¿® */
-function sfSendOrderMail($order_id, $template_id, $subject = "", $header = "", $footer = "", $send = true) {
+/** ¼õÃí´°Î»¥á¡¼¥ëÁ÷¿®
+ *  $template_id ¤¬ 1¡§·ÈÂÓÍÑ¥Æ¥ó¥×¥ì¡¼¥È¡¢0¡§PCÍÑ¥Æ¥ó¥×¥ì¡¼¥È
+ */
+function sfSendOrderMail($order_id, $template_id, $subject = "", $body, $send = true) {
 	global $arrMAILTPLPATH;
 	
@@ -1670,14 +1672,12 @@
 	$objQuery = new SC_Query();
 		
-	if($subject == "" && $header == "" && $footer == "") {
+	if($subject == "" && $body == "" ) {
 		// ¥á¡¼¥ë¥Æ¥ó¥×¥ì¡¼¥È¾ðÊó¤Î¼èÆÀ
 		$where = "template_id = ?";
-		$arrRet = $objQuery->select("subject, header, footer", "dtb_mailtemplate", $where, array('1'));
-		$objPage->tpl_header = $arrRet[0]['header'];
-		$objPage->tpl_footer = $arrRet[0]['footer'];
+		$arrRet = $objQuery->select("subject, body", "dtb_mailtemplate", $where, array($template_id));
+		$objPage->tpl_body = $arrRet[0]['body'];
 		$tmp_subject = $arrRet[0]['subject'];
 	} else {
-		$objPage->tpl_header = $header;
-		$objPage->tpl_footer = $footer;
+		$objPage->tpl_body = $body;
 		$tmp_subject = $subject;
 	}
@@ -1693,5 +1693,5 @@
 	// ¸ÜµÒ¾ðÊó¤Î¼èÆÀ
 	$customer_id = $arrOrder['customer_id'];
-	$arrRet = $objQuery->select("point", "dtb_customer", "customer_id = ?", array($customer_id));
+	$arrRet = $objQuery->select("point,name01,name02", "dtb_customer", "customer_id = ?", array($customer_id));
 	$arrCustomer = $arrRet[0];
 
@@ -1724,6 +1724,17 @@
 	// ¥á¡¼¥ëËÜÊ¸¤Î¼èÆÀ
 	$objMailView->assignobj($objPage);
-	$body = $objMailView->fetch($arrMAILTPLPATH[$template_id]);
-	
+    $name = $objPage->arrCustomer['name01']." ".$objPage->arrCustomer['name02'];
+    $objPage->tpl_body = ereg_replace( "(\{name\})", $name ,  $objPage->tpl_body );
+    $tmp_subject = ereg_replace( "(\{name\})", $name ,  $tmp_subject );
+    
+    // $template_id==1¤Ï·ÈÂÓÍÑ
+    if($template_id == '1'){
+	   $body = $objMailView->fetch($arrMAILTPLPATH[1]);
+       $body = ereg_replace( "(\{order\})", $body ,  $objPage->tpl_body );
+    }else{
+       $body = $objMailView->fetch($arrMAILTPLPATH[0]); 
+       $body = ereg_replace( "(\{order\})", $body ,  $objPage->tpl_body );
+    }
+    
 	// ¥á¡¼¥ëÁ÷¿®½èÍý
 	$objSendMail = new GC_SendMail();
@@ -1744,5 +1755,4 @@
 		}
 	}
-
 	return $objSendMail;
 }
@@ -2923,12 +2933,37 @@
 }
 
-/* ¥Ç¥Ð¥Ã¥°ÍÑ ------------------------------------------------------------------------------------------------*/
-function sfPrintR($obj) {
-	print("<div style='font-size: 12px;color: #00FF00;'>\n");
-	print("<strong>**¥Ç¥Ð¥Ã¥°Ãæ**</strong><br />\n");
-	print("<pre>\n");
-	print_r($obj);
-	print("</pre>\n");
-	print("<strong>**¥Ç¥Ð¥Ã¥°Ãæ**</strong></div>\n");
+/** ¥Ç¥Ð¥Ã¥°ÍÑ´Ø¿ô **/
+
+/**
+ *  ÅÏ¤µ¤ì¤¿ÊÑ¿ô¤òDump¤¹¤ë
+ *
+ *  @param  mixed  $obj   Dump¤·¤¿¤¤ÊÑ¿ô
+ *  @param  string $color ½ÐÎÏ¤¹¤ë¿§
+ *  
+ *  @return void ¤Ê¤·
+ */
+function sfPrintR($obj, $color='green') {
+    if ( DEBUG_MODE === false ) {
+        return;
+    }
+    
+    $arrColor = array(
+        'green' => '#00FF00',
+        'red'   => '#FF0000',
+        'blue'  => '#0000FF'
+    );
+    
+    if ( empty($arrColor[$color]) ) {
+        $color = $arrColor['green'];
+    } else {
+        $color = $arrColor[$color];
+    }
+    
+    print("<div style='font-size: 12px;color: $color;'>\n");
+    print("<strong>**¥Ç¥Ð¥Ã¥°Ãæ**</strong><br />\n");
+    print("<pre>\n");
+    print_r($obj);
+    print("</pre>\n");
+    print("<strong>**¥Ç¥Ð¥Ã¥°Ãæ**</strong></div>\n");
 }
 
Index: /branches/beta/data/lib/glib.php
===================================================================
--- /branches/beta/data/lib/glib.php	(revision 241)
+++ /branches/beta/data/lib/glib.php	(revision 14676)
@@ -86,5 +86,5 @@
  * [Ãí¼á] -
  *----------------------------------------------------------------------*/
-function gfDebugLog($obj){
+function gfDebugLog($obj, $path = DEBUG_LOG_PATH){
 		gfPrintLog("*** start Debug ***");
 		ob_start();
@@ -92,5 +92,5 @@
 		$buffer = ob_get_contents();
 		ob_end_clean();
-		$fp = fopen(LOG_PATH, "a+");
+		$fp = fopen($path, "a+");
 		fwrite( $fp, $buffer."\n" );
 		fclose( $fp );
@@ -98,5 +98,5 @@
 
 		// ¥í¥°¥Æ¡¼¥·¥ç¥ó
-		gfLogRotation(MAX_LOG_QUANTITY, MAX_LOG_SIZE, LOG_PATH);
+		gfLogRotation(MAX_LOG_QUANTITY, MAX_LOG_SIZE, $path);
 }
 
Index: /branches/beta/data/smarty_extends/modifier.script_escape.php
===================================================================
--- /branches/beta/data/smarty_extends/modifier.script_escape.php	(revision 14530)
+++ /branches/beta/data/smarty_extends/modifier.script_escape.php	(revision 14676)
@@ -11,5 +11,5 @@
     
     $pattern = "/<script.*?>|<\/script>/";
-    $convert = "#####";
+    $convert = "#script tag escaped#";
     
     if ( preg_match_all($pattern, $value, $matches) ) {
Index: /branches/beta/data/downloads/module/module.txt
===================================================================
--- /branches/beta/data/downloads/module/module.txt	(revision 11887)
+++ /branches/beta/data/downloads/module/module.txt	(revision 14676)
@@ -3,2 +3,4 @@
 "4", "¥¤¥×¥·¥í¥ó·èºÑ¥â¥¸¥å¡¼¥ë", "", "1.2", "¥¤¥×¥·¥í¥ó·èºÑ¥â¥¸¥å¡¼¥ë¤ò»ÈÍÑ¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£(¤³¤Î¥â¥¸¥å¡¼¥ë¤ò»ÈÍÑ¤¹¤ë¤Ë¤Ï<a href="#" onClick="window.open('http://www.rapidsite.jp/product/support/shop/epsilon.html'); return false;" >¥¤¥×¥·¥í¥ó</a>¤Ë·ÀÌó¤¹¤ëÉ¬Í×¤¬¤¢¤ê¤Þ¤¹¡£)", "mdl_epsilon/mdl_epsilon.php", "mdl_epsilon/mdl_epsilon.php", "", "", "mdl_epsilon/mdl_epsilon.tpl|mdl_epsilon/card.php|mdl_epsilon/convenience.php|mdl_epsilon/convenience.tpl|mdl_epsilon/mdl_epsilon.inc", "0", "", "2006-12-19 00:00:00","1.0.2","500","460"
 "5", "¥ë¥ß¡¼¥º·èºÑ¥â¥¸¥å¡¼¥ë", "", "1.0", "¥ë¥ß¡¼¥º·èºÑ¥â¥¸¥å¡¼¥ë¤ò»ÈÍÑ¤¹¤ë¤³¤È¤¬¤Ç¤­¤Þ¤¹¡£(¤³¤Î¥â¥¸¥å¡¼¥ë¤ò»ÈÍÑ¤¹¤ë¤Ë¤Ï<a href="#" onClick="window.open('http://www.remise.jp/'); return false;" >¥ë¥ß¡¼¥º</a>¤Ë·ÀÌó¤¹¤ëÉ¬Í×¤¬¤¢¤ê¤Þ¤¹¡£)", "mdl_remise/mdl_remise.php", "mdl_remise/mdl_remise.php", "", "", "mdl_remise/mdl_remise.tpl|mdl_remise/card.php|mdl_remise/convenience.php|mdl_remise/card.tpl|mdl_remise/convenience.tpl|mdl_remise/mdl_remise.inc", "0", "", "2007-03-15 00:00:00","1.2.0-beta","500","600"
+"6", "¥»¥­¥å¥ê¥Æ¥£¥Á¥§¥Ã¥¯¥Ä¡¼¥ë", "", "1.0", "¥µ¥¤¥È¤ÎÀÈ¼åÀ­¤ò¥Á¥§¥Ã¥¯¤·¤Þ¤¹", "security/security.php", "security/security.php", "", "", "security/security.tpl", "0", "", "2007-04-03 00:00:00","0.9.9","500","330"
+"7", "¤Æ¤¹¤È", "", "1.0", "¥Ö¥ì¥¤¥óML¤ÎÀßÄê¤¬¤Ç¤­¤Þ¤¹¡£", "blayn/blayn.php", "blayn/blayn.php", "", "", "blayn/blayn.tpl", "0", "", "2007-06-07 00:00:00","1.3.0","500","330"
Index: /branches/beta/data/downloads/module/blayn/blayn.php.txt
===================================================================
--- /branches/beta/data/downloads/module/blayn/blayn.php.txt	(revision 14676)
+++ /branches/beta/data/downloads/module/blayn/blayn.php.txt	(revision 14676)
@@ -0,0 +1,151 @@
+<?php
+/**
+ * 
+ * @copyright   2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ * @version CVS: $Id: 1.0 2006-06-04 06:38:01Z matsumura $
+ * @link        http://www.lockon.co.jp/
+ *
+ */
+ 
+class LC_Page {
+    
+    function LC_Page() {
+        $this->tpl_mainpage = MODULE_PATH . "blayn/blayn.tpl";
+        $this->tpl_title = "¥Ö¥ì¥¤¥óIPÅÐÏ¿";
+        $this->tpl_subtitle = "¥Ö¥ì¥¤¥óIPÀßÄê¥â¥¸¥å¡¼¥ë";
+    }
+}
+$objPage = new LC_Page();
+$objView = new SC_AdminView();
+$objQuery = new SC_Query();
+$objFormParam = new SC_FormParam;
+
+// ½é´ü²½
+lfIntiParam();
+
+$objFormParam->setParam($_POST);
+$objPage->arrIP = $objFormParam->getHashArray();
+
+$url = SITE_URL . "admin/system/module.php";
+$tpl_onload  = "onload = \"opener_reload('" .$url. "');window.close();\"";
+
+switch ($_POST['mode']) {
+    
+    case 'regist':
+        // ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+        $objPage->arrErr = lfErrorcheck();
+        if(count($objPage->arrErr) <= 0) {
+            // °ìÃ¶¥Æ¡¼¥Ö¥ë¤ÎÃÍ¤ò¤¹¤Ù¤Æ¾Ãµî¡ÊlfGetIP¤Çwhere»ØÄê¤Î¼ê´Ö¤ò¾Ê¤¯¤¿¤á¡Ë
+            lfDelete();
+            // ÅÐÏ¿
+            lfRegist();
+            $objPage->tpl_onload = $tpl_onload;            
+        }
+    break;
+    
+    
+    default:
+        // ½é´üÉ½¼¨
+        $objPage->arrIP = lfGetIP();
+}
+
+// ½é´üÉ½¼¨°Ê³°¤Ï'regist'¤òÄÌ¤é¤»¤ë
+$objPage->mode = 'regist';
+
+$objView->assignobj($objPage);      //ÊÑ¿ô¤ò¥Æ¥ó¥×¥ì¡¼¥È¤Ë¥¢¥µ¥¤¥ó¤¹¤ë
+$objView->display($objPage->tpl_mainpage);      //¥Æ¥ó¥×¥ì¡¼¥È¤Î½ÐÎÏ
+
+// ------------------------------------------------------------------------------------------------------
+
+/**
+ * ÃÍ¤Î½é´ü²½
+ * 
+ * @return void ¤Ê¤·
+ */
+function lfIntiParam() {
+    
+    global $objFormParam;
+    
+        $objFormParam->addParam("IP¥¢¥É¥ì¥¹1", "blayn_ip01", INT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+        $objFormParam->addParam("IP¥¢¥É¥ì¥¹2", "blayn_ip02", INT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+        $objFormParam->addParam("IP¥¢¥É¥ì¥¹3", "blayn_ip03", INT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+        $objFormParam->addParam("IP¥¢¥É¥ì¥¹4", "blayn_ip04", INT_LEN, "KVa", array("EXIST_CHECK", "MAX_LENGTH_CHECK", "NUM_CHECK"));
+}
+
+
+/**
+ * ¥¨¥é¡¼¥Á¥§¥Ã¥¯
+ * 
+ * @return array $arr->arrErr
+ */
+function lfErrorcheck() {
+    
+    global $objFormParam;
+    
+    $arrList = $objFormParam->getHashArray();
+    $objErr = new SC_CheckError($arrList);
+    $arrErr->arrErr = $objFormParam->checkError();
+
+    return $arrErr->arrErr;
+    
+}
+
+
+/**
+ * IP¥¢¥É¥ì¥¹ÅÐÏ¿
+ * 
+ * @return void ¤Ê¤·
+ */
+function lfRegist() {
+    
+    global $objQuery;
+    global $objFormParam;
+    
+    $arrPost = $objFormParam->getHashArray();
+    // IP¥¢¥É¥ì¥¹¤Î·Á¤ËÀ°·Á
+    $blayn_ip .= $arrPost['blayn_ip01'];
+    $blayn_ip .= "." . $arrPost['blayn_ip02'];
+    $blayn_ip .= "." . $arrPost['blayn_ip03'];
+    $blayn_ip .= "." . $arrPost['blayn_ip04'];
+    
+    $sqlVal['blayn_ip'] = $blayn_ip;
+    $objQuery->insert("dtb_blayn", $sqlVal);
+}
+
+
+/**
+ * ¥Æ¡¼¥Ö¥ë¤ÎÃÍÁ´¾Ãµî
+ * 
+ * @return void ¤Ê¤·
+ */
+function lfDelete() {
+    
+    global $objQuery;
+    
+    $objQuery->delete("dtb_blayn");
+}
+
+
+/**
+ * IP¥¢¥É¥ì¥¹¼èÆÀ
+ * 
+ * @return array $arrRet
+ */
+function lfGetIP() {
+    
+    global $objQuery;
+    
+    $arrSql = $objQuery->select("blayn_ip", "dtb_blayn");
+    // ¥Õ¥©¡¼¥à¤ËÆþ¤ì¤ë·Á¤ËÀ°·Á
+    $arrRet = split("\.", $arrSql[0]['blayn_ip']);
+    
+    // Smarty¤ËÉ½¼¨¤µ¤»¤ë¤¿¤á¤ËÀ°·Á
+    $arrRet[blayn_ip01] = $arrRet[0];
+    $arrRet[blayn_ip02] = $arrRet[1];
+    $arrRet[blayn_ip03] = $arrRet[2];
+    $arrRet[blayn_ip04] = $arrRet[3];
+        
+    return $arrRet;
+}
+
+?>
Index: /branches/beta/data/downloads/module/blayn/blayn.tpl.txt
===================================================================
--- /branches/beta/data/downloads/module/blayn/blayn.tpl.txt	(revision 14676)
+++ /branches/beta/data/downloads/module/blayn/blayn.tpl.txt	(revision 14676)
@@ -0,0 +1,136 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="ja" lang="ja">
+
+<head>
+<meta http-equiv="content-type" content="application/xhtml+xml; charset=<!--{$smarty.const.CHAR_CODE}-->" />
+<meta http-equiv="content-script-type" content="text/javascript" />
+<meta http-equiv="content-style-type" content="text/css" />
+<link rel="stylesheet" href="<!--{$smarty.const.URL_DIR}-->admin/css/contents.css" type="text/css" media="all" />
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/css.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/navi.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/win_op.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/site.js"></script>
+<script type="text/javascript" src="<!--{$smarty.const.URL_DIR}-->js/admin.js"></script>
+<!--{include file='css/contents.tpl'}-->
+<title><!--{$tpl_subtitle}--></title>
+<script type="text/javascript">
+<!--
+function win_open(URL){
+	var WIN;
+	WIN = window.open(URL);
+	WIN.focus();
+}
+
+function opener_reload(url){
+	window.opener.location.href = url ;
+	window.close();
+}
+//-->
+</script>
+</head>
+
+<body bgcolor="#ffffff" text="#666666" link="#007bb7" vlink="#007bb7" alink="#cc0000" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0" <!--{$tpl_onload}-->>
+<noscript>
+<link rel="stylesheet" href="<!--{$smarty.const.URL_DIR}-->admin/css/common.css" type="text/css" />
+</noscript>
+
+<div align="center">
+<!--¢§CONTENTS-->
+<form action="<!--{$smarty.server.REQUEST_URI|escape}-->" method="post">
+<input type="hidden" name="mode" value="<!--{$mode}-->">
+<table width="500" border="0" cellspacing="0" cellpadding="0" summary=" ">
+	<tr valign="top">
+		<td class="mainbg">
+			<table width="500" border="0" cellspacing="0" cellpadding="0" summary=" ">
+				<!--¥á¥¤¥ó¥¨¥ê¥¢-->
+				<tr>
+					<td align="center">
+						<table width="470" border="0" cellspacing="0" cellpadding="0" summary=" ">
+							<tr><td height="14"></td></tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_top.jpg" width="470" height="14" alt=""></td>
+							</tr>
+							<tr>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_left.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+								<td bgcolor="#cccccc" >
+									<table width="442" border="0" cellspacing="0" cellpadding="0" summary=" ">
+										<tr>
+											<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_top.gif" width="442" height="7" alt=""></td>
+										</tr>
+										<tr>
+											<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_left.gif" width="22" height="12" alt=""></td>
+											<td bgcolor="#636469" width="402" class="fs14n"><span class="white"><!--¥³¥ó¥Æ¥ó¥Ä¥¿¥¤¥È¥ë--><!--{$tpl_subtitle}--></span></td>
+											<td background="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_right_bg.gif"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="18" height="1" alt=""></td>
+										</tr>
+										<tr>
+											<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/contents_title_bottom.gif" width="442" height="7" alt=""></td>
+										</tr>
+										<tr>
+											<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="442" height="10" alt=""></td>
+										</tr>
+									</table>
+
+									<table width="442" border="0" cellspacing="1" cellpadding="8" summary=" ">
+										<tr class="fs12n">
+											<td bgcolor="#ffffff">
+												¥Ö¥ì¥¤¥ó¥Í¡¼¥ë¥µ¡¼¥Ó¥¹¤ò¤´ÍøÍÑÄº¤¯°Ù¤Ë¤Ï¡¢¥æ¡¼¥¶ÍÍ¤´¼«¿È¤Ç¥Ö¥ì¥¤¥ó³ô¼°²ñ¼Ò¤È¤´·ÀÌó¤ò¹Ô¤Ã¤Æ¤¤¤¿¤À¤¯É¬Í×¤¬¤¢¤ê¤Þ¤¹¡£ <br/>
+												¤ª¿½¤·¹þ¤ß¤Ë¤Ä¤­¤Þ¤·¤Æ¤Ï¡¢²¼µ­¤Î¥Ú¡¼¥¸¤«¤é¡¢¤ª¿½¤·¹þ¤ß¤ò¹Ô¤Ã¤Æ²¼¤µ¤¤¡£<br/><br/>
+												<a href="#" onClick="win_open('http://www.blaynengine.jp/ec-cube/')" > ¡ä¡ä ¥Ö¥ì¥¤¥ó¥á¡¼¥ë¥µ¡¼¥Ó¥¹¤Ë¤Ä¤¤¤Æ</a><br/>
+												<a href="#" onClick="win_open('http://wiki.ec-cube.net/')" > ¡ä¡ä ¥Ö¥ì¥¤¥ó¥á¡¼¥ëÀßÄê¥Þ¥Ë¥å¥¢¥ë</a>
+											</td>
+										</tr>
+									</table>
+									
+									<table width="442" border="0" cellspacing="0" cellpadding="0" summary=" ">
+										<tr><td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bar.jpg" width="442" height="10" alt=""></td></tr>
+									</table>
+									
+									<table width="442" border="0" cellspacing="1" cellpadding="8" summary=" ">
+									<tr class="fs12n">
+										<td bgcolor="#f3f3f3">IP¥¢¥É¥ì¥¹</td>
+										<td bgcolor="#ffffff" <!--{if $arrErr != ""}-->style="background-color:<!--{$smarty.const.ERR_COLOR|escape}-->"<!--{/if}-->><span class="red"><!--{$arrErr.blayn_ip01}--><!--{$arrErr.blayn_ip02}--><!--{$arrErr.blayn_ip03}--><!--{$arrErr.blayn_ip04}--></span>
+										<input type="text" size="4" maxlength="<!--{$smarty.const.ID_MIN_LEN}-->" name="blayn_ip01" value="<!--{$arrIP.blayn_ip01}-->"> . <input type="text" size="4" maxlength="<!--{$smarty.const.ID_MIN_LEN}-->" name="blayn_ip02" value="<!--{$arrIP.blayn_ip02}-->"> . <input type="text" size="4" maxlength="<!--{$smarty.const.ID_MIN_LEN}-->" name="blayn_ip03" value="<!--{$arrIP.blayn_ip03}-->"> . <input type="text" size="4" maxlength="<!--{$smarty.const.ID_MIN_LEN}-->" name="blayn_ip04" value="<!--{$arrIP.blayn_ip04}-->"></td>
+									</tr>
+									</table>
+									<table width="442" border="0" cellspacing="0" cellpadding="0" summary="">
+										<tr>
+											<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+											<td><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_top.gif" width="440" height="7" alt=""></td>
+											<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="5" alt=""></td>
+										</tr>
+										<tr>
+											<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+											<td bgcolor="#e9e7de" align="center">
+											<table border="0" cellspacing="0" cellpadding="0" summary=" ">
+												<tr>
+													<td><input type="image" onMouseover="chgImgImageSubmit('<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist_on.jpg',this)" onMouseout="chgImgImageSubmit('<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist.jpg',this)" src="<!--{$smarty.const.URL_DIR}-->img/contents/btn_regist.jpg" width="123" height="24" alt="¤³¤ÎÆâÍÆ¤ÇÅÐÏ¿¤¹¤ë" border="0" name="subm"></td>
+												</tr>
+											</table>
+											</td>
+											<td bgcolor="#cccccc"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="1" height="10" alt=""></td>
+										</tr>
+										<tr>
+											<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/tbl_bottom.gif" width="442" height="8" alt=""></td>
+										</tr>
+									</table>
+								</td>
+								<td background="<!--{$smarty.const.URL_DIR}-->img/contents/main_right.jpg"><img src="<!--{$smarty.const.URL_DIR}-->img/common/_.gif" width="14" height="1" alt=""></td>
+							</tr>
+							<tr>
+								<td colspan="3"><img src="<!--{$smarty.const.URL_DIR}-->img/contents/main_bottom.jpg" width="470" height="14" alt=""></td>
+							</tr>
+							<tr><td height="30"></td></tr>
+						</table>
+					</td>
+				</tr>
+			</table>
+		</td>
+	</tr>
+</table>
+</form>
+<!--¢¥CONTENTS-->
+</div>
+
+
+</body>
+</html>
Index: /branches/beta/data/install.php
===================================================================
--- /branches/beta/data/install.php	(revision 12186)
+++ /branches/beta/data/install.php	(revision 14676)
