Index: /branches/feature-module-update/html/admin/contents/file_view.php
===================================================================
--- /branches/feature-module-update/html/admin/contents/file_view.php	(revision 15532)
+++ /branches/feature-module-update/html/admin/contents/file_view.php	(revision 16264)
@@ -6,28 +6,14 @@
  */
 
+// {{{ requires
 require_once("../require.php");
-require_once(DATA_PATH . "include/file_manager.inc");
+require_once(CLASS_PATH . "page_extends/admin/contents/LC_Page_Admin_Contents_FileView_Ex.php");
 
-// ソースとして表示するファイルを定義(直接実行しないファイル)
-$arrViewFile = array(
-					 'html',
-					 'htm',
-					 'tpl',
-					 'php',
-					 'css',
-					 'js',
-);
+// }}}
+// {{{ generate page
 
-// 拡張子取得
-$arrResult = split('\.', $_GET['file']);
-$ext = $arrResult[count($arrResult)-1];
-
-// ファイル内容表示
-if(in_array($ext, $arrViewFile)) {
-	// ファイルを読み込んで表示
-	header("Content-type: text/plain\n\n");
-	print(sfReadFile(USER_PATH.$_GET['file']));
-} else {
-	header("Location: ".USER_URL.$_GET['file']);
-}
+$objPage = new LC_Page_Admin_Contents_FileView_Ex();
+$objPage->init();
+$objPage->process();
+register_shutdown_function(array($objPage, "destroy"));
 ?>
Index: /branches/feature-module-update/data/class/page_extends/admin/contents/LC_Page_Admin_Contents_FileView_Ex.php
===================================================================
--- /branches/feature-module-update/data/class/page_extends/admin/contents/LC_Page_Admin_Contents_FileView_Ex.php	(revision 16264)
+++ /branches/feature-module-update/data/class/page_extends/admin/contents/LC_Page_Admin_Contents_FileView_Ex.php	(revision 16264)
@@ -0,0 +1,52 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+
+// {{{ requires
+require_once(CLASS_PATH . "pages/admin/contents/LC_Page_Admin_Contents_FileView.php");
+
+/**
+ * ファイル表示 のページクラス(拡張).
+ *
+ * LC_Page_Admin_Contents_FileView をカスタマイズする場合はこのクラスを編集する.
+ *
+ * @package Page
+ * @author LOCKON CO.,LTD.
+ * @version $Id$
+ */
+class LC_Page_Admin_Contents_FileView_Ex extends LC_Page_Admin_Contents_FileView {
+
+    // }}}
+    // {{{ functions
+
+    /**
+     * Page を初期化する.
+     *
+     * @return void
+     */
+    function init() {
+        parent::init();
+    }
+
+    /**
+     * Page のプロセス.
+     *
+     * @return void
+     */
+    function process() {
+        parent::process();
+    }
+
+    /**
+     * デストラクタ.
+     *
+     * @return void
+     */
+    function destroy() {
+        parent::destroy();
+    }
+}
+?>
Index: /branches/feature-module-update/data/class/pages/admin/contents/LC_Page_Admin_Contents_FileView.php
===================================================================
--- /branches/feature-module-update/data/class/pages/admin/contents/LC_Page_Admin_Contents_FileView.php	(revision 16264)
+++ /branches/feature-module-update/data/class/pages/admin/contents/LC_Page_Admin_Contents_FileView.php	(revision 16264)
@@ -0,0 +1,76 @@
+<?php
+/*
+ * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
+ *
+ * http://www.lockon.co.jp/
+ */
+
+// {{{ requires
+require_once(CLASS_PATH . "pages/LC_Page.php");
+require_once(CLASS_PATH . "helper_extends/SC_Helper_FileManager_Ex.php");
+
+/**
+ * ファイル表示 のページクラス.
+ *
+ * @package Page
+ * @author LOCKON CO.,LTD.
+ * @version $Id$
+ */
+class LC_Page_Admin_Contents_FileView extends LC_Page {
+
+    // }}}
+    // {{{ functions
+
+    /**
+     * Page を初期化する.
+     *
+     * @return void
+     */
+    function init() {
+        parent::init();
+    }
+
+    /**
+     * Page のプロセス.
+     *
+     * @return void
+     */
+    function process() {
+        // ユーザー認証
+        SC_Utils_Ex::sfIsSuccess(new SC_Session());
+
+        // ソースとして表示するファイルを定義(直接実行しないファイル)
+        $arrViewFile = array(
+                             'html',
+                             'htm',
+                             'tpl',
+                             'php',
+                             'css',
+                             'js',
+                             );
+
+        // 拡張子取得
+        $arrResult = split('\.', $_GET['file']);
+        $ext = $arrResult[count($arrResult)-1];
+
+        // ファイル内容表示
+        if(in_array($ext, $arrViewFile)) {
+            $objFileManager = new SC_Helper_FileManager_Ex();
+            // ファイルを読み込んで表示
+            header("Content-type: text/plain\n\n");
+            print($objFileManager->sfReadFile(USER_PATH . $_GET['file']));
+        } else {
+            $this->sendRedirect(USER_URL . $_GET['file']);
+        }
+    }
+
+    /**
+     * デストラクタ.
+     *
+     * @return void
+     */
+    function destroy() {
+        parent::destroy();
+    }
+}
+?>
