Index: /temp/trunk/data/class/SC_View.php
===================================================================
--- /temp/trunk/data/class/SC_View.php	(revision 5934)
+++ /temp/trunk/data/class/SC_View.php	(revision 6709)
@@ -41,6 +41,6 @@
 		$this->_smarty->register_function("sf_date","sf_date");
 		$this->_smarty->register_function("str_replace","str_replace");
+		$this->_smarty->register_function("sfPrintEbisTag","sfPrintEbisTag");
 		
-
 		if(ADMIN_MODE == '1') {		
 			$this->time_start = time();
Index: /temp/trunk/data/lib/slib.php
===================================================================
--- /temp/trunk/data/lib/slib.php	(revision 6679)
+++ /temp/trunk/data/lib/slib.php	(revision 6709)
@@ -2573,4 +2573,77 @@
 }
 
+function sfPrintEbisTag($pid = "") {
+	global $arrEbisPID;
+	
+	// ¡Ö/¡×¤¬½ÅÊ£¤·¤Æ¤¤¤ë¤â¤Î¤Ø¤ÎÂÐ±þ
+	$php_self = ereg_replace("[/]+", "/", $_SERVER['PHP_SELF']);
+	// PHP¥Õ¥¡¥¤¥ë¤Î¸å¤í¤Ë¡Ö/¡×¤¬¤Ä¤¤¤Æ¤·¤Þ¤Ã¤Æ¤¤¤ë¤â¤Î¤Ø¤ÎÂÐ±þ
+	$php_self = ereg_replace(".php[/]+$", ".php", $php_self);
+	
+	$arrEbis['pid'] = $arrEbisPID[$php_self];
+	
+	if(!is_array($pid) && $pid != "") {
+		if(!ereg(".tpl$", $pid)) {
+			// ¥Ú¡¼¥¸ID¤ò¾å½ñ¤­¤¹¤ë
+			$arrEbis['pid'] = $pid;
+		} else {
+			// ¥Æ¥ó¥×¥ì¡¼¥È¤Î¥Ñ¥¹¤¬Í¿¤¨¤é¤ì¤Æ¤¤¤ë¾ì¹ç
+			$temp_id = ereg_replace("^[/]+","",$pid);
+			$temp_id = ereg_replace(".tpl$","",$temp_id);
+			$temp_id = ereg_replace("[\./]","_",$temp_id);
+			$arrEbis['pid'] = $temp_id;
+		}
+	}	
+	
+	// ¾¦ÉÊ°ìÍ÷¥Ú¡¼¥¸¤Ï¡¢ÆÃ¼ìID¤òÈ¯¹Ô
+	if(ereg("^/products/list-c[0-9]+.html", $_SERVER["REQUEST_URI"])) {
+		$filename = basename($_SERVER["REQUEST_URI"]);
+		$arrEbis['pid'] = ereg_replace(".html$", "", $filename);
+	}
+	
+	// ¾¦ÉÊ°ìÍ÷¥Ú¡¼¥¸¤Ï¡¢ÆÃ¼ìID¤òÈ¯¹Ô
+	if(ereg("^/products/list.php\?category_id=[0-9]+", $_SERVER["REQUEST_URI"])) {
+		$filename = basename($_SERVER["REQUEST_URI"]);
+		$arrEbis['pid'] = ereg_replace("list.php\?category_id=", "list-c", $filename);
+	}
+	
+	// ¾¦ÉÊ¾ÜºÙ¥Ú¡¼¥¸¤Ï¡¢ÆÃ¼ìID¤òÈ¯¹Ô
+	if(ereg("^/products/detail-p[0-9]+.html", $_SERVER["REQUEST_URI"])) {
+		$filename = basename($_SERVER["REQUEST_URI"]);
+		$arrEbis['pid'] = ereg_replace(".html$", "", $filename);
+	}
+	
+	// ¾¦ÉÊ¾ÜºÙ¥Ú¡¼¥¸¤Ï¡¢ÆÃ¼ìID¤òÈ¯¹Ô
+	if(ereg("^/products/detail.php\?product_id=[0-9]+", $_SERVER["REQUEST_URI"])) {
+		$filename = basename($_SERVER["REQUEST_URI"]);
+		$arrEbis['pid'] = ereg_replace("detail.php\?product_id=", "detail-p", $filename);
+	}
+	
+	// ID³ä¤êÅö¤Æ¤µ¤ì¤Æ¤¤¤Ê¤¤¥Ú¡¼¥¸¤Ï¡¢¼«Æ°Åª¤ËÀ¸À®¤¹¤ë¡£
+	if($arrEbis['pid'] == "") {				
+		$temp_id = ereg_replace("^[/]+","",$_SERVER['PHP_SELF']);
+		$temp_id = ereg_replace(".php$","",$temp_id);
+		$temp_id = ereg_replace("[\./]","_",$temp_id);
+		$arrEbis['pid'] = $temp_id;
+	}
+		
+	// ÃíÊ¸ID¤¬»ØÄê¤µ¤ì¤Æ¤¤¤ë¾ì¹ç¡ÊÉÕ²Ã¾ðÊó¤òÀ¸À®¤¹¤ë¡Ë
+	if($_SESSION['ebis']['order_id'] != "") {
+		// ¥¨¥Ó¥¹¥¿¥°°úÅÏ¤·ÍÑ¥Ç¡¼¥¿¤òÀ¸À®¤¹¤ë
+		$arrRet = lfGetEbisData($_SESSION['ebis']['order_id']);
+		$arrEbis = array_merge($arrRet, $arrEbis);
+		unset($_SESSION['ebis']);
+	}
+	
+	// ¥Ú¡¼¥¸ID¤¬ÅÐÏ¿¤µ¤ì¤Æ¤¤¤ë¾ì¹ç¤Î¤ß¥¿¥°¤ò½ÐÎÏ¤¹¤ë¡£
+	if($arrEbis['pid'] != "") {
+		$objSubPage = new LC_EbisPage();
+		$objSubPage->arrEbis = $arrEbis;
+		$objSubView = new SC_SiteView();
+		$objSubView->assignobj($objSubPage);
+		$objSubView->display($objSubPage->tpl_mainpage);
+	}
+}
+
 /* ¥Ç¥Ð¥Ã¥°ÍÑ ------------------------------------------------------------------------------------------------*/
 function sfPrintR($obj) {
