{"id":104,"date":"2018-04-08T23:19:01","date_gmt":"2018-04-08T14:19:01","guid":{"rendered":"http:\/\/rugoh.co.jp\/blog\/?p=104"},"modified":"2018-04-08T23:19:21","modified_gmt":"2018-04-08T14:19:21","slug":"fuelphp-sub","status":"publish","type":"post","link":"https:\/\/rugoh.co.jp\/blog\/2018\/04\/08\/fuelphp-sub\/","title":{"rendered":"\u30b5\u30d6\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3067FuelPHP\u3092\u4f7f\u3046"},"content":{"rendered":"<p>http:\/\/xxxxx.com\/subdir\/<\/p>\n<p>\u307f\u305f\u3044\u306b\u30b5\u30d6\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3067FuelPHP\u3092\u4f7f\u3044\u305f\u3044\u3068\u304d<br \/>\n\u203bsubdir\u30b3\u30f3\u30c8\u30ed\u30fc\u30e9\u3092\u547c\u3076\u3093\u3067\u306a\u304f<br \/>\n\u3000subdir\u304cFuelPHP\u306e\u30c8\u30c3\u30d7\u306b\u306a\u308b\u30a4\u30e1\u30fc\u30b8<\/p>\n<p>\u6ce8\u610f\u70b9<br \/>\n\u57fa\u672c\u7684\u306b\u3001PHP\u306e\u30d5\u30ec\u30fc\u30e0\u30ef\u30fc\u30af\u306fpublic\u4ee5\u5916\u306e\u3059\u3079\u3066\u306e\u30d5\u30a1\u30a4\u30eb\u306f<br \/>\nHTTP\u3067\u30a2\u30af\u30bb\u30b9\u3067\u304d\u306a\u3044\u5834\u6240\u306b\u7f6e\u304f\u306e\u304c\u30bb\u30aa\u30ea\u30fc\u3067\u3059\u3002<br \/>\n\u306a\u306e\u3067\u3001subdir\u30d5\u30a9\u30eb\u30c0\u306e\u4e0b\u306bFuelPHP\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb\u3057\u308c\u3070\u3044\u3044\u3058\u3083\u3093<br \/>\n\u7684\u306a\u30ce\u30ea\u306f\u3057\u307e\u305b\u3093\u3002\u516c\u958b\u3055\u308c\u3061\u3083\u3046\u304b\u3089\u306d\u3002<\/p>\n<p>\u5143\u3005\u3053\u3093\u306a\u611f\u3058\u306e\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u69cb\u6210<br \/>\n<img loading=\"lazy\" src=\"http:\/\/rugoh.co.jp\/blog\/wp-content\/uploads\/2018\/04\/2018040801.png\" alt=\"\" width=\"400\" height=\"300\" class=\"alignnone size-full wp-image-105\" \/><\/p>\n<h4>public\u30d5\u30a9\u30eb\u30c0\u3092\u30b3\u30d4\u30fc\u3059\u308b<\/h4>\n<p>Fuelphp\u3067\u7528\u610f\u3055\u308c\u305fpublic\u30d5\u30a9\u30eb\u30c0\u3092<strong>subdir<\/strong>\u30d5\u30a9\u30eb\u30c0\u306b\u30b3\u30d4\u30fc\u3057\u307e\u3059\u3002<\/p>\n<p><img loading=\"lazy\" src=\"http:\/\/rugoh.co.jp\/blog\/wp-content\/uploads\/2018\/04\/2018040802.png\" alt=\"\" width=\"400\" height=\"450\" class=\"alignnone size-full wp-image-116\" srcset=\"https:\/\/rugoh.co.jp\/blog\/wp-content\/uploads\/2018\/04\/2018040802.png 400w, https:\/\/rugoh.co.jp\/blog\/wp-content\/uploads\/2018\/04\/2018040802-267x300.png 267w\" sizes=\"(max-width: 400px) 100vw, 400px\" \/><\/p>\n<p>\u3053\u3093\u306a\u611f\u3058\u306e\u30d5\u30a1\u30a4\u30eb\u69cb\u6210\u306b\u306a\u308b<\/p>\n<h4>subdir\/index.php\u3092\u7de8\u96c6<\/h4>\n<pre>define('APPPATH', realpath(__DIR__.'\/<strong style=\"color:red\">app\u307e\u3067\u306e\u76f8\u5bfe\u30d1\u30b9<\/strong>').DIRECTORY_SEPARATOR);\r\ndefine('PKGPATH', realpath(__DIR__.'\/<strong style=\"color:red\">packages\u307e\u3067\u306e\u76f8\u5bfe\u30d1\u30b9<\/strong>').DIRECTORY_SEPARATOR);\r\ndefine('COREPATH', realpath(__DIR__.'\/<strong style=\"color:red\">core\u307e\u3067\u306e\u76f8\u5bfe\u30d1\u30b9<\/strong>').DIRECTORY_SEPARATOR);<\/pre>\n<h4>subdir\/.htaccess\u3092\u7de8\u96c6<\/h4>\n<pre># no php-fcgi, check for sapi and fpm\r\n&lt;IfModule !mod_fcgid.c&gt;\r\n  # for PHP5 sapi installations\r\n  &lt;IfModule mod_php5.c&gt;\r\n    RewriteRule ^(.*)$ \/<strong style=\"color:red\">subdir<\/strong>\/index.php\/$1 [L]\r\n  &lt;\/IfModule&gt;\r\n  &lt;IfModule !mod_php5.c&gt;\r\n    # for PHP7 sapi installations\r\n    &lt;IfModule mod_php7.c&gt;\r\n      RewriteRule ^(.*)$ \/<strong style=\"color:red\">subdir<\/strong>\/index.php\/$1 [L]\r\n    &lt;\/IfModule&gt;\r\n    # for fpm installations\r\n    &lt;IfModule !mod_php7.c&gt;\r\n      RewriteRule ^(.*)$ \/<strong style=\"color:red\">subdir<\/strong>\/index.php?\/$1 [QSA,L]\r\n    &lt;\/IfModule&gt;\r\n  &lt;\/IfModule&gt;\r\n&lt;\/IfModule&gt;<\/pre>\n<p>\u3053\u306e\u6642\u70b9\u3067\u3001http:\/\/xxxxx.com\/subdir\/\u3067FuelPHP\u306b\u30a2\u30af\u30bb\u30b9\u53ef\u80fd\u3068\u306a\u308b\u306f\u305a\u3067\u3059<\/p>\n<h4>\u305d\u306e\u4ed6\u306e\u6ce8\u610f\u70b9\u3068\u3057\u3066<\/h4>\n<p><u>assets\u30d5\u30a9\u30eb\u30c0\u304c \/assets\u3058\u3083\u306a\u3044<\/u><\/p>\n<p>\u3053\u306e\u5834\u5408\u3001\/subdir\/assets\/\u306b\u306a\u308b<\/p>\n<p><u>routes.php\u3067\u30eb\u30fc\u30c6\u30a3\u30f3\u30b0\u3059\u308b\u5834\u5408<\/u><\/p>\n<p>\u30eb\u30fc\u30c6\u30a3\u30f3\u30b0\u30de\u30c3\u30c1\u306f\u3001\u3042\u304f\u307e\u3067subdir\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u4ed8\u3067\u5b9a\u7fa9\u3057\u306a\u3044\u3068\u30c0\u30e1<\/p>\n","protected":false},"excerpt":{"rendered":"<p>http:\/\/xxxxx.com\/subdir\/ \u307f\u305f\u3044\u306b\u30b5\u30d6\u30c7\u30a3\u30ec\u30af\u30c8\u30ea\u3067FuelPHP\u3092\u4f7f\u3044\u305f\u3044\u3068\u304d \u203bsubdir&#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":102,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[3,10],"tags":[],"_links":{"self":[{"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/posts\/104"}],"collection":[{"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/comments?post=104"}],"version-history":[{"count":9,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/posts\/104\/revisions"}],"predecessor-version":[{"id":118,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/posts\/104\/revisions\/118"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/media\/102"}],"wp:attachment":[{"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/media?parent=104"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/categories?post=104"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rugoh.co.jp\/blog\/wp-json\/wp\/v2\/tags?post=104"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}