OSDN Git Service

test
authorroot <landhere@users.sourceforge.jp>
Tue, 21 Feb 2012 07:37:22 +0000 (16:37 +0900)
committerroot <landhere@users.sourceforge.jp>
Tue, 21 Feb 2012 07:37:22 +0000 (16:37 +0900)
config/site.inc.php.example
config/version.inc.php
lib/common.inc.php [deleted file]
lib/debug.inc.php [deleted file]
lib/html.inc.php [deleted file]

index 2b4cd79..6009d49 100644 (file)
@@ -1,43 +1,43 @@
-<?php\r
-\r
-mb_internal_encoding('UTF-8');\r
-\r
-//\r
-// カスタマイズ設定項目\r
-// ファイル名を site.inc.php にリネームしてください\r
-//\r
-\r
-// サイト名\r
-define('SITE_NAME' ,'Cosmic Server');\r
-\r
-// システムのルートディレクトリ(絶対パス指定、最後のスラッシュは不要)\r
-define('PATH_ROOT'  ,'/home/landhere/public_html/!_private_!/comic');\r
-\r
-// サイトURLのルート(URL絶対パス指定、最後のスラッシュは不要)\r
-define('URL_ROOT'  ,'/!_private_!/comic');\r
-\r
-// コミックを置いたディレクトリ(絶対パス指定、最後のスラッシュは不要)\r
-// <おすすめ配置方法>\r
-// /path/to/comics/て テストコミック 全2巻/テストコミック 第01巻.zip\r
-// /path/to/comics/て テストコミック 全2巻/テストコミック 第02巻.zip\r
-// ※必ずサブディレクトリの下にzipを置いて下さい\r
-define('PATH_COMIC' ,'/path/to/comics');\r
-\r
-// サイトのデザインテーマ(themesディレクトリのサブディレクトリ名)\r
-// サブディレクトリに見つからないファイルは、defaultのものが使用される\r
-define('SITE_THEME','default');\r
-\r
-// パス構成(通常は変更する必要はありません)\r
-define('PATH_THEMES',PATH_ROOT.'/themes');\r
-define('PATH_LIB'   ,PATH_ROOT.'/lib');\r
-define('PATH_INDEX' ,PATH_ROOT.'/index');\r
-define('PATH_CACHE' ,PATH_ROOT.'/cache'); // 書き込み権限が必要(chmod 777 cache)\r
-\r
-// URL構成(通常は変更する必要はありません)\r
-define('URL_THEMES',URL_ROOT.'/themes');\r
-\r
-// システムを設定します\r
-include_once('version.inc.php');\r
-include_once('init.inc.php');\r
-\r
+<?php
+
+mb_internal_encoding('UTF-8');
+
+//
+// カスタマイズ設定項目
+// ファイル名を site.inc.php にリネームしてください
+//
+
+// サイト名
+define('SITE_NAME' ,'Cosmic Server');
+
+// システムのルートディレクトリ(絶対パス指定、最後のスラッシュは不要)
+define('PATH_ROOT'  ,'/home/landhere/public_html/!_private_!/comic');
+
+// サイトURLのルート(URL絶対パス指定、最後のスラッシュは不要)
+define('URL_ROOT'  ,'/!_private_!/comic');
+
+// コミックを置いたディレクトリ(絶対パス指定、最後のスラッシュは不要)
+// <おすすめ配置方法>
+// /path/to/comics/て テストコミック 全2巻/テストコミック 第01巻.zip
+// /path/to/comics/て テストコミック 全2巻/テストコミック 第02巻.zip
+// ※必ずサブディレクトリの下にzipを置いて下さい
+define('PATH_COMIC' ,'/path/to/comics');
+
+// サイトのデザインテーマ(themesディレクトリのサブディレクトリ名)
+// サブディレクトリに見つからないファイルは、defaultのものが使用される
+define('SITE_THEME','default');
+
+// パス構成(通常は変更する必要はありません)
+define('PATH_THEMES',PATH_ROOT.'/themes');
+define('PATH_LIB'   ,PATH_ROOT.'/lib');
+define('PATH_INDEX' ,PATH_ROOT.'/index');
+define('PATH_CACHE' ,PATH_ROOT.'/cache'); // 書き込み権限が必要(chmod 777 cache)
+
+// URL構成(通常は変更する必要はありません)
+define('URL_THEMES',URL_ROOT.'/themes');
+
+// システムを設定します
+include_once('version.inc.php');
+include_once('init.inc.php');
+
 ?>
\ No newline at end of file
index cf16f45..f63250f 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 
-define('SYSTEM_NAME'   ,'Cosmic Server');
+define('SYSTEM_NAME'   ,'Cosmic : Simple Comic Server');
 define('SYSTEM_VERSION','0.11');
 
 ?>
\ No newline at end of file
diff --git a/lib/common.inc.php b/lib/common.inc.php
deleted file mode 100644 (file)
index 9331dd2..0000000
+++ /dev/null
@@ -1,67 +0,0 @@
-<?php
-
-//
-// ウェブ関連
-//
-
-// GET, POST チェック用正規表現
-define('CV_TEXT'  ,'/^.+$/');
-define('CV_ALNUM' ,'/^[[:alnum:]]+$/');  // アルファベットと数値、[:alpha:] + [:digit:]
-define('CV_ALPHA' ,'/^[[:alpha:]]+$/');  // 大小文字アルファベット、 [:lower:] + [:upper:]
-define('CV_LOWER' ,'/^[[:lower:]]+$/');  // 小文字アルファベット
-define('CV_UPPER' ,'/^[[:upper:]]+$/');  // 大文字アルファベット
-define('CV_DIGIT' ,'/^[[:digit:]]+$/');  // 数値
-define('CV_BLANK' ,'/^[[:blank:]]+$/');  // 空白文字、スペースとタブ
-define('CV_CNTRL' ,'/^[[:cntrl:]]+$/');  // 制御文字(000-037, 177('DEL')
-define('CV_GRAPH' ,'/^[[:graph:]]+$/');  // グラフィカル文字 ([:alnum:] と [:punct:])|
-define('CV_PRINT' ,'/^[[:print:]]+$/');  // 印字可能な文字、[:alnum:] + [:punct:] + space
-define('CV_PUNCT' ,'/^[[:punct:]]+$/');  // パンクチュエーション文字 ! " # $ % & ' ( ) * + , - . /
-define('CV_SPACE' ,'/^[[:space:]]+$/');  // 空白文字、タブ、改行、水平タブ、給紙、キャリッジリターン、空白
-define('CV_XDIGIT','/^[[:xdigit:]]+$/'); // 16進数 0 1 2 3 4 5 6 7 8 9 A B C D E F a b c d e f
-define('CV_MD5'   ,'/^[a-z0-9]{32}$/');  // md5ハッシュ値
-define('CV_EMAIL' ,'/^[\w.-]+\@([\w-]+\.)+\w+$/'); // メールアドレス
-
-// GET, POST パラメータチェック
-function check_request($var,$chk='',$def='') {
-
-       $val = isset($_REQUEST[$var]) ? $_REQUEST[$var] : $def;
-       if ($chk!='') {
-               if (preg_match($chk,$val)==0) {
-                       $val = $def;
-               }
-       }
-
-       $_REQUEST[$var] = $val;
-
-       return $val;
-}
-
-// 一般変数の内容チェック
-function check_value(&$val,$pat,$def) {
-
-       if (preg_match($pat,$val)==0) {
-               $val = $def;
-       }
-
-       return $val;
-}
-
-
-//
-// ファイル操作関連
-//
-
-// ファイルパスより拡張子を返す
-function common__get_fileext($path) {
-
-       $p = strrpos($path,'.');
-       if ($p!==false) {
-               $ext = substr($path,$p+1);
-       } else {
-               $ext = '';
-       }
-
-       return $ext;
-}
-
-?>
\ No newline at end of file
diff --git a/lib/debug.inc.php b/lib/debug.inc.php
deleted file mode 100644 (file)
index 6ce02d5..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-<?php
-
-function debug__out($var) {
-       echo '<pre>'.var_export($var,true).'</pre>';
-}
-
-function debug__halt($var) {
-       debug__out($var);
-       exit;
-}
-
-
-?>
\ No newline at end of file
diff --git a/lib/html.inc.php b/lib/html.inc.php
deleted file mode 100644 (file)
index fbe29a1..0000000
+++ /dev/null
@@ -1,101 +0,0 @@
-<?php
-
-
-//-------------------------------------------------------------------
-// テンプレート
-//-------------------------------------------------------------------
-
-$_HTML = array();
-
-class html {
-
-       // テーマファイル格納用
-       public $theme_files = array();
-
-       // テーマファイルの登録
-       public function regist_theme_file($name,$path,$url) {
-               $this->theme_files[$name] = array(
-                       'path' => $path,
-                       'url'  => $url,
-               );
-       }
-
-       // テンプレートファイルパスを戻す
-       public function get_theme_file_path($name) {
-               return $this->theme_files[$name]['path'];
-       }
-
-       // テンプレートファイルURLを戻す
-       public function get_theme_file_url($name) {
-               return $this->theme_files[$name]['url'];
-       }
-
-       // テンプレートの適用
-       public function apply($tmpl) {
-
-               $tmpl = $this->get_theme_file_path($tmpl);
-
-               if (file_exists($tmpl)) {
-                       $html = file_get_contents($tmpl);
-               } else {
-                       $html = '{{doc}}';
-               }
-
-               $html = $this->_apply_include($html);
-               $html = $this->_apply_replace($html);
-
-               return $html;
-       }
-
-       // インクルード処理
-       private function _apply_include($html) {
-
-               $html = preg_replace_callback(
-                       '/{{include:(.+?)}}/',
-                       array($this,'_apply_include_callback'),
-                       $html
-               );
-
-               return $html;
-
-       }
-
-       // インクルード処理(コールバック関数)
-       private function _apply_include_callback($matches) {
-
-               $path = $this->get_theme_file_path($matches[1]);
-               if (file_exists($path)) {
-                       return file_get_contents($path);
-               } else {
-                       return '';
-               }
-
-       }
-
-       // 置き換え処理
-       private function _apply_replace($html) {
-
-               $html = preg_replace_callback(
-                       '/{{(.+?)}}/',
-                       array($this,'_apply_replace_callback'),
-                       $html
-               );
-
-               return $html;
-
-       }
-
-       // 置き換え処理(コールバック関数)
-       private function _apply_replace_callback($matches) {
-
-               if (array_key_exists($matches[1],$GLOBALS['_HTML'])) {
-                       return $GLOBALS['_HTML'][$matches[1]];
-               } else {
-                       return '';
-               }
-
-       }
-
-}
-
-?>
\ No newline at end of file